finagle / finagle-oauth2 Goto Github PK
View Code? Open in Web Editor NEWOAuth2 Server-Side Provider for Finagle
License: Apache License 2.0
OAuth2 Server-Side Provider for Finagle
License: Apache License 2.0
Instead of using custom server.
Updating to Finagle 6.42.0 leads to errors such as this:
java.lang.NoSuchMethodError: com.twitter.finagle.http.HeaderMap.getAll
Would it be possible to get a new compatible release?
There is only one way to implement token service. But the protected service might be implemented in two usage ways of finagle-oauth2: w/o filter and w/ type-safe filter.
oAuthErrorToHttpResponse
method in OAuth2
WWW-Authenticate: Bearer List(error="invalid_request", e, r, r, o, r, _, d, e, s, c, r, i, p, t, i, o, n, =, ", r, e, q, u, i, r, e, d, , p, a, r, a, m, e, t, e, r, :, , u, s, e, r, n, a, m, e, ")
I'm thinking of trait mixing idea:
trait OAuthErrorHandler {
def handleError(e: OAuthError): Response = ???
}
val auth = new OAuth2Filter(dataHandler) with OAuthErrorInJson
ditto
Like this:
trait OAuthTokenConverter {
def convertToken(t: Token): Response
}
val tokenizer = new OAuth2Endpoint(dataHandler) with OAuthTokenInJson with OAuthErrorInJson
case class AuthorizedRequest[U](authInfo: AuthInfo[U]) extends RequestProxy
val f = new AuthentificateFilter[User] with OAuth2 {
def apply(req: Request, service: Service[AuthorizedRequest[User], Response]): Future[Response] =
// try authorize
service(AuthorizedRequest(authInfo))
// else bad request
}
Not sure where to ask this question, I'm about to implement OAuth2 for my application and the suitable grant type for my application is implicit. I've noticed that this library is not supporting it (or am I missing it), but the scala-oauth library does have it.
Is there a particular reason why it's not present and can I give it a shot to add it to this project?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.