Rick Emmines
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # OAuth R&D Initial Findings & Considerations ## Our Approach to this R&D The purpose of this R&D exercise was to explore OAuth implementation options, ascertain the technical scope, complexity and dependancies at a high level ahead of undergoing a more detailed scoping and design process. R&D was carried out through the lens of the OAuth requirements provided by Poplar HARCA (see below). This document outlines our findings and considerations. The implementation of an OAuth service within the existing myHARCA application imposes some nessecary changes, the scope of which are yet to be fully determined. For example, the re-engineering of the Staff Access module. This exercise aims to highlight key dependancies to enable Poplar HARCA to make more informed decisions on how to prioritise OAuth developments. **R&D carried out by:** Carl Barker - Lead Developer Element3 Technology ## Poplar HARCA's Initial Requirements for OAuth | Requirement | Status | Comments | | ----------- | ------ | -------- | |Single Sign On (SSO) - The ability for end users to authenticate to myHARCA and related Poplar HARCA online services via thier existing Google, Facebook or similar popular personal accounts| Completed | Most OAuth service paid tiers offer unlimited social connectors. Service accounts on the provider are required and supplying Auth0 with the connection details | |Two-factor Authentication (2FA) Although not essential from the outset of OAuth implementation, this is a desirebale option as an adiitional layer of security for internal staff and potentially residents| Completed | Two-Factor Authentication is available via both providers but only on higher payment tiers (see below). Multiple methods are available including SMS, email, and Authenicator app | |OIDC/ OAuth Authentication| Completed | | |The chosen OAuth service should allows Poplar HARCA to integrate with websites/microsites that they may either be purchased, developed in house or outsourced in the future. Key is that end users of these services can login with the same credentials and access the widest range of available services possible| Completed | Within the same domain this is possible with all providers on all tiers. To integrate other domains, the professional tiers must be used | |The ability to secure Poplar HARCA's existing and future APIs using an accepted standard authentication method| Completed | This is classed as M2M authentication and is available on all tiers. Limits are imposed, so a re-write would be required the Authentication in the Gateway to store access tokens in state and to refresh when it expires in order to keep usage down | |The potential link of myHARCA portal credentials with Poplar HARCA's VOIP telephony phone system ([8X8](https://www.8x8.com/)) using APIs. The aim being to allow residents to authenticate themselves before being passed to an operator. This is feature is not essential from the outset but a long term consideration in selecting an OAuth service| Incomplete | This requires the inclusion of a third party provider to integrate. Further R&D is required on this component | |Justification and demonstrable diligence for utilising an up to date, industrial standard service for OAuth| Completed | With an industry standard OAuth provider, information on security and compliance https://auth0.com/docs/compliance | # Impacts of OAuth Implementation on myHARCA Portal **IMPORTANT - In order to implement SSO via a service such as Auth0, the current Staff Access authentication method would need a complete rewrite and over haul, due to the way in which staff members authenticate 'as a resident' to view their account.** **The current myHARCA authentication process is as follows:** - When a staff member logs into staff access, the staff member receives an initial access token - Next, when accessing the myHARCA account of a tenant, the system authenticates that tenant to create an additional access token to store in the cookie This is done so the system can utilise all of the same API endpoints for this user and give a near exact representation of the tenant's account to the staff member - These endpoints have overrides where necessary to enable certain 'staff-only' functionality - When a staff member closes the resident account or logs out of staff access, the account holder's cookie is destroyed This is a large consideration for the implementation of an OAuth service to replace the current authentication method in myHARCA, as there is a dependancy on nessecary refactoring of the staff access module. # OAuth Providers Comparison ## Auth0 ### About Auth0 [Auth0](https://auth0.com/) are a global provider of OAuth, User Access Management and Security services. Built for enterprise, Auth0 is a widely accepted standard for OAuth used across a range of sectors including commercial and public sector. ### Available Plans The prices below are based on a 7000 active user count per month, the pricing can be scaled up and down per user case. Items that meet the requirement specifications above are <u>underlined</u>. **Use Cases:** - Free Plan - 7,000 active users - <u>1,000 M2M authentications</u> - Unlimited logins - <u>Access to 2 social media connectors</u> - <u>Compliance certificates</u> - 1 day log retention - Community support only - 3 admins - B2C - User authentication using username and password, social connectors - Essential - **$160 /mo (£116 GBP)** - 7,000 active users - <u>1000 M2M authentications</u> - Unlimited social connectors - Custom domains and email branding - Role management - 2 day log retention - Standard level support - ticket system - Professional - **$1,200 /mo (£873 GBP)** - 7,000 active users - <u>5,000 M2M authentications</u> - Unlimited social connectors - Custom domains and email branding - Role management - External databases - <u>Cross app SSO</u> - <u>Pro MFA</u> - 10 days log retention - Standard level support - ticket system - **Requirements not met** - **AD Integration** - B2B** - Business authentication including SAML, LDAP, AD - Essential - **$1,420 /mo (£1,033 GBP)** - 7,000 active users - <u>5,000 M2M authentications</u> - Unlimited social connectors - <u>3 Enterprise connections (AD)</u> - 50 Organisations - Custom domains and email branding - Role management - <u>Pro MFA</u> - 10 days log retention - Standard level support - ticket system - Professional - **$1,800 /mo (£1,309 GBP)** - 7,000 active users - <u>5,000 M2M authentications</u> - Unlimited social connectors - <u>3 Enterprise connections (AD)</u> - 100 Organisations - Custom domains and email branding - Role management - External databases - <u>Cross app SSO</u> - <u>Pro MFA</u> - 10 days log retention - Standard level support - ticket system - B2E - Enterprise authentication - This use case has a maximum of 500 users beyond which a sales representative must be invoiced. This is beyond the scope of this research phase ****Due to Poplar HARCA's requirement for Active Directory integration and the number of expected users, the B2B plan should be considered as a minimum. This would enable the staff to login to the myHARCA portal and other connected systems using thier existing Poplar HARCA Active Directory user accounts.** ### Implementation Considerations - API authentication - The development documentation available is to an enterprise standard and is descriptive and in depth - There are a number of 'quick start' guides available to get development teams up and running with Auth0. It is straight forward and is available for all major coding languages and frameworks - Auth0 documentation provides sample projects on Github which offers further support for developers who are new to the platform - For the myHARCA portal, Auth0 can be added as a provider in the startup class of the application to give endpoints access to to Authorize attributes using the Auth0 JWT token - The token will be checked against the provided domain to validate - Auth0 provide further SDK libraries that can be imported into application projects for deeper integration - Portal backend implementation - **Within the myHARCA portal this implementation would replace the current basic API authentication used between the Gateway API hosted on MW-01 (middleware server) and the portal** - **The authentication on the Gateway would need to be re-engineered. There is a dependency on re-writing the Gateway application that serves as the middleware between the portal and Poplar HARCA APIs to utilise Auth0 Authentication tokens more effectively. This can be done by storing the access token in local state and be reusable, as the M2M authentication requests are limited** - Front-End implementation - Auth0 provide a number of ways for development teams to implement authentication into the front end of the application. The OAuth login page can be customized from within the Auth0 portal - HMTL, CSS and JS can be updated to present the required look and feel of the page - When creating the custom login page, using the custom login form template it will be possible to add an extra step to the register section to enable the account validation - The personID can be saved in the user_metadata JSON object, this can then be added as custom claims and used within the portal for selecting data - Custom domains can be put in please to keep the used with the web application domain - The documentation has 'quick start' guides and sample code for all front end frameworks, whether they are rendered client side or server side - Auth0 provide and maintain libraries which can be imported into the major back end frameworks. This is a real benefit as it will result in improved development times, better readability of code and ensures that connections are less prone to error as Auth0 development team provide regular updates which can be easily implemented. For example, the myHARCA portal could utilise the .NET version of this library for security related functionality. ## Okta ### Available Plans Okta has 2 pricing strands, other than the free developer account that offers only basic functionality. All other use cases must go through an Okta sales representitive for pricing. Below is only a snap shot of these levels, which can scale based on number of users - Workforce Identity Products - for organisation and staff logins - Single Sign-on - **$2 /mo per user (£1.45 GBP)** - <u>AD Integration</u> - 3rd party MFA integration - Desktop and mobile SSO (cloud & on-premises apps) - Multi-factor Authentication - **$3 /mo per user(£2.18 GBP)** - <u>2-Factor Authentication</u> - API Access Management - **$2 /mo per user (£1.45 GBP)** - Application and directory integrations - OAuth 2.0 and OIDC compliant - Customizable scopes and claims - Customizable authorization servers - Customer Identity Products - for customers, tenants and general user logins - Developer - **$0 /mo (£0 GBP)** - 15,000 users - Community support only - Extra option for higher level support $4,000 (£2,909 GBP) per month - 5 OIDC Clients - 3 SAML clients - Customizable sign-in and registration widget - Customizable email templates and domains **(only for paid accounts)** - One App - **Starting at $14,000 /y (£10,180 GBP)** - Tier based users, contact sales - 5 OIDC Clients - Full support - Customizable sign-in and registration widget - Customizable email templates and domains - Enterprise - **Starting at $36,000 /y (£26,177 GBP)** - Tier based users, contact sales - Unlimited OIDC Clients - Unlimited SAML Clients - Full support - Customizable sign-in and registration widget - Customizable email templates and domains - Addons - Directory Integration - **Starting at $21,000 /y (£15,270)** - <u>AD Integration</u> - API Access Management - Starting at $4,000 /y (£2,909 GBP), price scales up with number of tokens - <u>M2M authentication</u> - Multi-factor Authentication - **Starting at $7,000 /y (£5,090 GBP)** - SSO Integrations - **Starting at $1,500 /y (£10,907 GBP)** - Access to pre-built app integrations in the OIN To ascertain realistic estimates for Okta pricing, it is highly recommended to speak with a sales representative providing a detailed break down of requirements and projected user count for both staff access and tenant access. - API authentication - The development documentation is descriptive and in depth - There are a number of 'quick start' guides to get the developer up and running with Okta. It is straight forward and is available for all major coding languages and frameworks - For the myHARCA portal Okta SDK can be imported into the project and added as a provider in the startup class of the application to give endpoints access to to Authorize attributes using the JWT token. - The token will be checked against the provided domain to validate - In order to generate the access_token an assertion token must be generated first and passed to the /token endpoint. This must container information about the access_token and be signed with the client secret https://developer.okta.com/docs/guides/implement-oauth-for-okta-serviceapp/create-sign-jwt/ - Portal backend implementation - **Within the portal this implementation would replace the current basic API authentication used between the Gateway API hosted on MW-01 (middleware server) and the portal** - **In all cases, as described above the authentication on the Gateway would need to be re-engineered in order to store the access token in local state and be reusable this would prevent the Okta API management scaling too high** - Front End implementation - The OAuth login page can be customized from within the Okta portal - HTML, CSS and JS can be updated to present the required look and feel of the page - When creating the custom login page, using the custom login form template it will be possible to add an extra step to the register section to enable the account validation - The personID can be saved in the user_metadata json object, this can then be added as custom claims and used within the portal for selecting data - Custom domains can be put in place to keep the user within the web application domain - The documentation has quick starts and sample code for all 3 of the major front-end frameworks as well as a standard JS implementation, the standard JS implementation would be required for the portal - Okta provide and maintain libraries to be imported into the major frameworks. This would improve development time, code readability and make the connections less error prone ## Final Considerations At a minimum, Poplar HARCA should be looking to migrate their authentication to Auth0 to replace the current authentication setup. Although the current setup is secure, Auth0 offers a much higher range of compliance certificates for all thier plans including the free tier. *"Auth0 carries a variety of compliance options including SOC 2, ISO27001, ISO27018, Gold CSA STAR, Data Residency needs and more."* **Okta** Although Okta has customer identities, it appears Okta is more focused around workforce authentication, which is aimed at staff / employee users, rather than customers/public users During developer R&D we were unable to customise the 'register' form on the OAuth page using the developer tier. We are unsure if this is locked behind a payment wall, or if this feature is not provided. For the myHARCA portal use case, this would be a requirement as the 'validate tenant' step must happen before the user is registered and the personID from this validation is stored in the account. During R&D, we were also unable to add meta data to the users on Okta. **Auth0** Based on the R&D carried out to date by both Poplar HARCA and Element3 with the Auth0 service, our recommendation would be to continue with Auth0 as the OAuth provider for the myHARCA portal and future micro sites. Please note that R&D to date has only been a high level exercise and a 'Proof of Concept' approach and methodology would be recommended to ascertain more detailed, solid recommendations. **Rationale:** - At first glace the pricing seems more complicated - M2M API authentication is simpler, with fewer steps - The potential ability to customise the 'login' and 'register' forms to cater for the tenant validation, however we suggest further R&D on this to validate **Considerations if chosen:** - B2B Professional only if AD Integration is 100% required and cannot be cut - B2C Professional has all other required functionality - In either case we recommend speaking with a sales rep **Phone System Integration** R&D to date has shown that connecting OAuth to Poplar Harca's 8x8 VOIP telephony systems would require the inclusion of a third party provider to facilitate integration. This component would require it's own R&D phase if considered essential for OAuth implementation.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully