Skip to content

Broken Authentication Methods & Questions #259

@mooyoul

Description

@mooyoul

Hello there,
I've been playing around DeviceHub - Great so far! Thanks for efforts to maintain this.

Anyway, I had some issues around Authentication methods:

  1. SAML: Completely Broken
  • Importing passport and passport-saml package is invalid. Needed to switch to default import (e.g. import passport form "passport")
  • After successful authentication, I noticed authentication check is moved to client-side. some authentication methods such as mock-auth or ldap set authentication credential to local storage by rendering react app. but some authentication methods such as SAML, OAuth2 were not.
  • I have fixed those issues and will submit a PR.
  • Question: Do you want to keep/maintain SAML Auth?
  1. OpenID: Partially Broken
  • I had a issue with Okta IdP.
  • Okta does not have user_info scope, they use profile scope for getting user profile instead. There's a scopes option, but there are no usages to modify requested scope. So modified code to respect scopes option to resolve this.
  • Okta requires state parameter, and validation must be performed. So modified code to generate state parameter, store this to cookie (although this is bad security practice), then perform validation to continue auth flow.
  • Currently OpenID Auth implementation does not use session. To be honest, Storing nonce/state value to cookie is not good idea due to security reasons. We need to utilize session for storing those values.
  • I think that OAuth2 Auth implementation and OpenID Auth implementation overlap in some areas. However, OAuth2 implementation does not appear to be maintained.
  • Question 1: Which OpenID implementation (or IdP) are you using?
  • Question 2: How should we organize OAuth2 authentication and OpenID authentication?
  • Question 3: How can we improve OpenID authentication?

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions