auth
auth/authd/server.go
Make client use our auth(n/z) scheme. Our auth(n/z) scheme can be loosely defined as "encrypted tokens that nginx transforms into headers" and "scopes for bypassing ACL". Our Go client, which is what we'll be using to have services communicate with each other, follows this paradigm now by auto-injecting the headers we'll need to identify ourselves. This will work behind our firewall, but will be useless for the rest of the world, which will need to go through the nginx bastion that can strip the headers and replace them with the headers appropriate to the token attached to the request. This did involve setting a static client ID as the client for our email_verification listener. Ideally, this would cause Client registration (using that ID) when the listener starts up, ignoring ErrClientAlreadyExists. I don't want to have to write the code that will allow us to bypass the Client ACL properly right now, though, so we're just going to have to remember to manually create that Client. Or not. I don't think it will do any harm (outside the OAuth flow) to be using a Client ID that doesn't actually point to a Client. I just think it'd be good for record-keeping purposes.
1.1 --- a/authd/server.go Sun May 17 02:27:36 2015 -0400 1.2 +++ b/authd/server.go Sun May 17 03:21:17 2015 -0400 1.3 @@ -55,7 +55,7 @@ 1.4 panic(err) 1.5 } 1.6 err = context.CreateScopes([]auth.Scope{ 1.7 - {ID: "testscope", Name: "Test Scope"}, 1.8 + auth.ScopeLoginAdmin, 1.9 }) 1.10 if err != nil && err != auth.ErrScopeAlreadyExists { 1.11 log.Fatal(err)