Giter Club home page Giter Club logo

fxa-oauth-console's Introduction

Firefox Accounts OAuth Credential Management Dashboard

Build Status

Development

git clone https://github.com/mozilla/fxa-oauth-console
cd fxa-oauth-console
npm install

Run development server locally:

npm start

Docker Dev

You can run the docker container by:

  • docker-compose build
  • docker-compose up

Changing environment configuration.

You can customize the servers that the app communicates with by passing them in the docker-compose file.

environment:
  PROFILE_URI: https://127.0.0.1:9010/v1
  OAUTH_INTERNAL_URI: https://127.0.0.1:9010/v1
  OAUTH_URI: https://127.0.0.1:1111/profile/v1

You will need a local Firefox Accounts stack to login to the console. Use fxa-local-dev to get started.

Run tests: npm test

License

MPL v2.0

fxa-oauth-console's People

Contributors

clouserw avatar dependabot[bot] avatar seanmonstar avatar udaraweerasinghege avatar vladikoff avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fxa-oauth-console's Issues

[node8] test warning on ember under node@8

Running npm install && npm test, the tests pass but a key warning:

WARNING: WARNING: Node v8.9.0 has currently not been tested against Ember CLI and may result in unexpected behaviour. version: 2.4.0

cannot create a new client (oauth hapi validation rejecting payload with null secret)

I updated stable with the fix from mozilla/fxa-oauth-server#223 and was trying to use the console at https://oauth-stable.dev.lcip.org/console.

On either stable or https://oauth-latest.dev.lcip.org/console, when I try to create a client (POST /v1/client), I get a response of '400 Bad Request' for 'Invalid request parameter' naming 'secret' as the problem key.

The request body is '

{
  "name":"jrgm test",
  "redirect_uri":"http://127.0.0.1/",
  "image_uri":"http://127.0.0.1/",
  "secret":null,
  "can_grant":false,
  "whitelisted":true
}

transient failures building fxa-oauth-console on fxa-dev box

I've been doing work to update queues for fxa-dev, and in the course of that, have noticed these sort of failures building fxa-oauth-console. A second try usually works.

NOTIFIED: [oauth-console | install fxa-oauth-console dependencies] ************ 
ok: [ec2-52-88-228-159.us-west-2.compute.amazonaws.com]

NOTIFIED: [oauth-console | build fxa-oauth-console assets] ******************** 
failed: [ec2-52-88-228-159.us-west-2.compute.amazonaws.com] => {"changed": true, "cmd": ["node_modules/.bin/ember", "build", "--environment\
=production"], "delta": "0:00:02.793024", "end": "2015-10-20 22:33:30.429085", "rc": 1, "start": "2015-10-20 22:33:27.636061", "warnings": \
[]}
stdout: 
Missing npm packages:
Package: ember-cli-qunit
  * Specified: 1.0.0
  * Installed: (not installed)

Package: ember-cli-release
  * Specified: 0.2.3
  * Installed: (not installed)

Package: ember-cli-sri
  * Specified: 1.0.3
  * Installed: (not installed)

Package: ember-cli-uglify
  * Specified: 1.2.0
  * Installed: (not installed)

Package: grunt
  * Specified: ^0.4.5
  * Installed: (not installed)
..f
...

Add icons to buttons

Actions such as "Create new client" / "Delete" should have icons next to them.

Create client without image_uri responds with error but no UI

Steps to reproduce:

  1. Go to create a new client (https://oauth-stable.dev.lcip.org/console/client/register)
  2. Omit the Image URI

Expected Results:

  • Create the client without an image
    or
  • Show an error message that image is required

Actual Results:
Nothing, and this is in the log:

{"code":400,"errno":109,"error":"Bad Request","message":"Invalid request parameter","info":"https://github.com/mozilla/fxa-oauth-server/blob/master/docs/api.md#errors","validation":{"source":"payload","keys":["image_uri"]}}

MVP UX

  • show list of registered clients
  • add client
  • edit client
  • delete client
  • get OAuth token for client requested scopes for the console "client"

Ship OAuth management console to production

Meta bug for shipping this management tool to production.

  • Get CLI in Ops hands
  • Implement Client Owners
  • Deploy Client Owners to production
  • Add owners to current clients (@ckarlof, @ckolos, @jrgm?)
  • Remove prod guard from OAuth Server
  • behind a mozilla-only security wall of some kind (e.g. VPN only access)

redirect_uri should be trimmed for whitespace

I copy/pasted a redirect_uri into the OAuth console last week and was later informed by the developer the redirect_uri had an unexpected space at the end when redirecting back to their site. Sure enough, I went back into the console and a space was at the end of the redirect_uri. redirect_uri should be trimed to remove leading and trailing whitespace.

A few outdated modules

Steps to reproduce

$ npm run outdated

> [email protected] outdated /Users/pdehaan/dev/github/fxa-oauth-console
> npm outdated --depth 0
Package Current Wanted Latest Location
bluebird 2.3.11 2.3.11 2.6.4 bluebird
body-parser 1.10.0 1.10.0 1.10.1 body-parser
broccoli-asset-rev 2.0.0 2.0.0 2.0.1 broccoli-asset-rev
convict 0.6.1 0.4.2 0.6.1 convict
ember-cli 0.1.7 0.1.4 0.1.7 ember-cli
ember-cli-qunit 0.1.1 0.1.1 0.1.2 ember-cli-qunit
ember-data 1.0.0-beta.12 1.0.0-beta.12 1.0.0-beta.14.1 ember-data
express 4.10.6 4.10.6 4.10.8 express
glob 4.3.1 4.3.1 4.3.4 glob
load-grunt-tasks 1.0.0 1.0.0 2.0.0 load-grunt-tasks
nodemon 1.2.1 1.3.0-7 1.2.1 nodemon
selenium-standalone 2.44.0 2.44.0 3.0.3 selenium-standalone
xmlhttprequest 1.5.1 git git xmlhttprequest

A few of these look a bit "stale", notably these:

$ npm shrinkwrap --dev
wrote npm-shrinkwrap.json

$ nsp audit-shrinkwrap
Name          Installed   Patched  Vulnerable Dependency
qs              0.6.6     >= 1.x   fxa-oauth-console > bower > bower-registry-client > request
qs              0.6.6     >= 1.x   fxa-oauth-console > bower > bower-registry-client > request
validator       1.5.1    >=3.22.1  fxa-oauth-console > convict
validator       1.5.1     >=2.0.0  fxa-oauth-console > convict
qs              0.6.6     >= 1.x   fxa-oauth-console > ember-cli > bower > bower-registry-client > request
qs              0.6.6     >= 1.x   fxa-oauth-console > ember-cli > bower > bower-registry-client > request
serve-static    1.7.1     >=1.7.2  fxa-oauth-console > ember-cli > express
connect         2.7.2     >=2.8.1  fxa-oauth-console > ember-cli > testem > express
qs              0.5.1     >= 1.x   fxa-oauth-console > ember-cli > testem > express > connect
qs              0.5.1     >= 1.x   fxa-oauth-console > ember-cli > testem > express > connect
send            0.1.0    >= 0.8.4  fxa-oauth-console > ember-cli > testem > express

If I bump convict and ember-cli to their latest versions, and re-shrinkwrap and re-run nsp, then that only leaves these results:

Name          Installed   Patched  Vulnerable Dependency
qs              0.6.6     >= 1.x   fxa-oauth-console > bower > bower-registry-client > request
qs              0.6.6     >= 1.x   fxa-oauth-console > bower > bower-registry-client > request
qs              0.6.6     >= 1.x   fxa-oauth-console > ember-cli > bower > bower-registry-client > request
qs              0.6.6     >= 1.x   fxa-oauth-console > ember-cli > bower > bower-registry-client > request

I'd file a Bower bug to update that pesky (and vulnerable) module, but... bower/bower#1452

Also (just to make this the worst bug report of all times), I noticed that we have ember-cli listed as a dependency AND a devDependency. Both use "ember-cli": "0.1.4", so it isn't a huge deal, but it did blow up my attempt at rerunning shrinkwrap after running npm i ember-cli@latest -S since I was then trying to install 0.1.4 and 0.1.7 and shrinkwrap really didn't like that. Manually removing it as a devDependency and then rerunning npm shrinkwrap --dev worked like a champ though.

Admin accounts?

Not sure what the admin interface would be, but it could be to manage scopes.

New client ID isn't working with django-allauth

@jwhitlock apparently got this working for his instance of web-platform-compat, but here's what I tried ...

Steps to reproduce:

  1. Create a brand new client at https://oauth-stable.dev.lcip.org/console/clients (mine is https://oauth-stable.dev.lcip.org/console/client/fa35c5aaaa8aebc7)
  2. Copy the FxA credentials into django-allauth db
  3. Try to sign in with Firefox Account

Expected results:
Sign in works

Actual results:
Generic "Bad request" page: https://accounts.firefox.com/400.html?message=Unknown%20client&errno=101&namespace=oauth

When I look at my client in the console, I notice "Whitelisted Client: (Currently required for all clients)" is un-checked. When I check it and click "Update", it doesn't seem to save?

Login infinite redirect

I tried to access the console at https://oauth-latest.dev.lcip.org/console/
I tried a few different passwords
I got "Client has sent too many requests" error
I clicked "Forgot password"
I reset my password
I went back to https://oauth-latest.dev.lcip.org/console/login
I entered my new password

Expected results:
https://oauth-latest.dev.lcip.org/console/

Actual results:
I bounce thru /auth/v1/account/login, /console/, /console/oauth/logout, and I land back on /console/login

Support "sharing" created clients with team members

AMO makes changes to their OAuth clients (changes redirect uri, etc) and asked for client sharing

[10:11:53] vladikoff: is there a way generally to get access to clients other people have created? It would be better if multiple people could change it rather than having to create a new one each time someone leaves / is on PTO

Can't register new client: js error

Steps to reproduce:
0. (Maybe) Stay out of the dev console for a really long time - trigger a session timeout?
0. (Maybe) Sign in to the dev console with a [email protected] email address?

  1. Go to https://oauth-stable.dev.lcip.org/console/client/register
  2. Enter values

Expected results:
Show the client secret and sample configuration

Actual results:
Big js stacktrace in console error log.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.