Skip to content
This repository has been archived by the owner on May 10, 2019. It is now read-only.

Issue 2497 refactor to idp #3982

Merged
merged 26 commits into from Nov 10, 2013
Merged

Issue 2497 refactor to idp #3982

merged 26 commits into from Nov 10, 2013

Conversation

ozten
Copy link
Contributor

@ozten ozten commented Oct 16, 2013

Background for pull request: Issue #2497 (comment)

Creating a pull request to try to get some frontend help.

Thanks to @shane-tomlinson for previously reviewing and getting it this far.

Known Issues:

  • siteName and other options aren't passed in from Desktop code, I'm investigating in gecko

Needs Frontend <3

  • rpinfo changes in dev broke this patch, minimal hardcoded changes were made to get it working again
    • Need help doing this correctly

@seanmonstar
Copy link
Contributor

fabulous! gets reviewing goggles

res.json({ 'public-key': publicKey.toSimpleObject() });
res.json({
'public-key': publicKey.toSimpleObject(),
'provisioning': '/provision',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indent is off

@shane-tomlinson
Copy link

So... The devil hiding in the details, password resets and transition states. Are they going to be handled?

@ozten
Copy link
Contributor Author

ozten commented Oct 17, 2013

The devil hiding in the details, password resets and transition states. Are they going to be handled?

Can we land this and start getting UX feedback, before implementing those features?

@ozten
Copy link
Contributor Author

ozten commented Oct 17, 2013

Trying to get awsbox working, I've merged from dev, but got bitrot for the second time.

I was able to see that logging.js moved and fix that.

The other issue is that the dialog just comes up blank.

To unblock myself, I've copied over scripts/deploy.js and changed the dependency to awsbox@0.6.2... but we'll have to figure out what changed about the dialog code that has broken the initial screen display for the new /auth screen. Any ideas?

@jaredhirsch
Copy link
Member

@ozten I'll do some git twiddling on Monday, see if I can cleanly apply your changes on top of current dev.

@jaredhirsch
Copy link
Member

ok, looking now.

@jaredhirsch
Copy link
Member

@ozten nice work so far!

I was able to cleanly cherry-pick all the changes onto current dev (except for the commits merging dev into this branch). My branch is at https://github.com/6a68/browserid/tree/issue-2497-idp-rebased-not-merged.

One tiny logging path change was needed to get tests running, that's on the HEAD of that branch, a7fd566.

The local RP seems fine to me on my branch, I can log in and out.

@ozten
Copy link
Contributor Author

ozten commented Oct 21, 2013

@6a68 is rocking the merge from dev to update this branch, you rule!

Please try to reproduce the blank dialog I was seeing.

You can download a Persona enabled Desktop build:
http://ftp.mozilla.org/pub/mozilla.org/firefox/try-builds/aking@mozilla.com-62351505bca9/

Set a couple preferences (about:config):

dom.identity.enabled = true
dom.identity.persona_fallback = http://127.0.0.1:10002
toolkit.identity.debug = true

Restart Firefox.

dom.identity.persona_fallback defaults to our new ephemeral server https://desktoppersona.personatest.org/ but you can change this to any environment.

Steps to reproduce:

  1. Launch Firefox with a clean profile
  2. Go to http://127.0.0.1:10001
  3. Click Get an assertion
  4. Enter foo@bar.com

Actual: empty dialog

Expected: prompt to set a password

@jaredhirsch
Copy link
Member

@ozten happy to help :-)

I've got the special FF build, I toggled the settings you mentioned (actually tried using the desktoppersona fallback as well as localhost), but I'm not sure what to do next.

When I try to log into RPs, I click the persona button but nothing happens. Tried 123done, mozillians, nothing. Also not seeing errors in the JS console--maybe there's a desktop-specific console for the native code that I'm unaware of?

I'll poke a bit more at my branch and yours, see if I can at least get an empty dialog using your branch.

@ozten
Copy link
Contributor Author

ozten commented Oct 21, 2013

So in nightly if you go to about:config and search for identity does it look like this

Clicking get Assertion should look like this

@jaredhirsch
Copy link
Member

It looks like the blank dialog error was caused by using hashes, but the recently-landed #3971 I think means we should be using querystring instead.

@ozten said this got him past the blank dialog problem in a local branch, I've updated my issue-2497-idp-rebased-not-merged branch with the fix (commit (9e8ed0f)[https://github.com/6a68/browserid/commit/9e8ed0f]).

@jaredhirsch
Copy link
Member

@ozten i don't have the toolkit.identity.enabled pref at all, but I have the other three matching your screenshot.

The second image is broken for me.

@ozten
Copy link
Contributor Author

ozten commented Oct 21, 2013

Thanks Jared!

Using your patch, I see Error: Relay frame could not be found.

Thanks for continuing to dig for breaking changes from merging.

@jaredhirsch
Copy link
Member

I have my current branch running on https://rebasedidp.personatest.org. Will pick this up again in the morning. 🍻

@jaredhirsch
Copy link
Member

@ozten looks like this line probably shouldn't have that IP hard-coded. I'm not totally clear on where we can get the proper domain info in this context, though. any ideas?

@jaredhirsch
Copy link
Member

heh, I caused the Relay Error: we look for the hash, not the querystring, when we setup the channel. Removing that, or changing that code to look for ?NATIVE as window.location.search, returns us to the mysterious empty dialog situation we had before. Continuing to dig.

@ozten
Copy link
Contributor Author

ozten commented Nov 7, 2013

@fmarier or @shane-tomlinson I've removed temporary hacks, console.log, etc. We should be good to merge as discussed.

General note: The Goldilocks API breaks the Native implementation, so use http://192.168.186.138:10001/watch.html instead of http://192.168.186.138:10001/

@ozten
Copy link
Contributor Author

ozten commented Nov 7, 2013

G R E E N

mediator.subscribe("new_user", newUserComplete(self));

var rpInfo = bid.Models.RpInfo.create({
origin: "http://127.0.0.1:10001",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did you forget to take these out?

@fmarier
Copy link
Contributor

fmarier commented Nov 10, 2013

r+ from me. makes Travis happy. tested by Shane and Austin.

fmarier added a commit that referenced this pull request Nov 10, 2013
@fmarier fmarier merged commit 173be4f into dev Nov 10, 2013
@ozten
Copy link
Contributor Author

ozten commented Nov 10, 2013

All the man needed was a Guiness at the airport!

Thanks!

@jaredhirsch jaredhirsch deleted the issue-2497-refactor-to-idp branch April 20, 2014 03:05
seanmonstar pushed a commit to seanmonstar/browserid-verifier that referenced this pull request May 30, 2014
This allows the verifier to work-around a Persona bug that has
been fixed (mozilla/persona#3982) but not
yet deployed.

Fixes mozilla#19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants