jackyzy823 / fxa-selfhosting

Selfhosting your own Firefox Accounts (FxA)!
Mozilla Public License 2.0
94 stars 13 forks source link

Unsure how to use OAuth #29

Open Handrail9 opened 1 week ago

Handrail9 commented 1 week ago

Hi, I'm trying to set up an OAuth provider for my FXA server. I was trying to figure out how to use it using this documentation from Mozilla. When I run the init script and put the docker containers up it start just fine, but I can't actually log in through my OAuth provider. It only shows me Google and Apple. Am I misunderstanding what the OAuth feature is in the config.yml file, or is there something I'm missing? Thanks

Here is my OAuth config, let me know if you want/need the whole config.

  clients:
  #! [NOTE] DO NOT ENABLE BELOW IF NOT USED
   - id: syncmanager
#!    #! hex secret 0b2b91549678167e4870d76e2b94024b2954cb8605e4a2e8179ab80ecf40b287
     hashedSecret: removed
     name: authelia
     imageUri: 'https://oauth.mydomain.tld/.my./favicon.ico'
#!    #! if generate_redirectUri will automatic generate redircturi : https://{content}.{domain_name}/oauth/success/{id}
     generate_redirectUri: true
     redirectUri: https://oauth.mydomain.tld/.well-known/openid-configuration
     trusted: true
#!    #! some explain https://github.com/mozilla/fxa/blob/96cbbccfaed1de93d556a2259554acfabeb4cbe5/packages/fxa-auth-server/lib/oauth/authorized_clients.js#L55
     canGrant: true
     publicClient: true
#!    #! redirecturi will be add to contetserver.prod.tmp.yml if scope matches
#!    #! allowedScopes is a space-seperated string
     allowedScopes: profile #! https://identity.mozilla.com/apps/oldsync
jackyzy823 commented 5 days ago

Hi, i think you misunderstand . this config is used to make FxA as a OAuth Provider. For example login into a site using fxa account.

The official fxa support Google/Apple as 3rd OAuth Provider . But the custom one do not support Google/Apple and other 3rd OAuth providers.