How can I pass oauth token or oauthaccesstokeid to javascript from Mule cloud connector -



How can I pass oauth token or oauthaccesstokeid to javascript from Mule cloud connector -

i using cloud connectors in mule utilize oauth , authorize connector using authorizre message processor. afte rlogging in service provider can access token future invocations using oauthaccesstokenid.

i interacting via javascript. have login button runs authorize flow in mule. , have seperate flow invoking api methods. how can pass oauthaccesstokenid javascript app in auth flow can pass mule invoke api?

after authorize processor doing 302 redirect javascript app , storing oauthaccesstokenid in cookie. best way? thoughts on security also?

note: assuming you're talking oauth2.

what you're describing typical scenario oauth2 implicit grant useful: grant type, access token provided web browser (thus javascript code hosts) via request fragment.

i'm not sure cloud connectors back upwards natively though. if not, going cookie work too.

as far security concerned, problem can see cookie opposed passing token in fragment, persisted on client. said these tokens short lived (worth checking what's ttl of token receive) attack surface not wide.

oauth mule

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -