RichardKnop / go-oauth2-server

A standalone, specification-compliant, OAuth2 server written in Golang.
Mozilla Public License 2.0
2.12k stars 315 forks source link

Validate redirect URL for token response type #33

Closed PumpkinSeed closed 7 years ago

PumpkinSeed commented 7 years ago

Fix for #31 issue

RichardKnop commented 7 years ago

@PumpkinSeed Build failed for some reason :o

PumpkinSeed commented 7 years ago

@RichardKnop I will check it on the weekend. Possible I made a mistake.

RichardKnop commented 7 years ago

Debug log from Travis:

122.71s$ make test
bash -c 'go list ./... | grep -v vendor | xargs -n1 go test -timeout=30s'
# github.com/RichardKnop/go-oauth2-server/oauth
oauth/client.go:72: undefined: Client
oauth/service_interface.go:35: undefined: Client
# github.com/RichardKnop/go-oauth2-server/oauth
oauth/client.go:72: undefined: Client
oauth/service_interface.go:35: undefined: Client
ok      github.com/RichardKnop/go-oauth2-server/config  0.006s
ok      github.com/RichardKnop/go-oauth2-server/database    0.008s
?       github.com/RichardKnop/go-oauth2-server/health  [no test files]
?       github.com/RichardKnop/go-oauth2-server/logger  [no test files]
ok      github.com/RichardKnop/go-oauth2-server/models  0.006s
# github.com/RichardKnop/go-oauth2-server/oauth
oauth/client.go:72: undefined: Client
oauth/service_interface.go:35: undefined: Client
FAIL    github.com/RichardKnop/go-oauth2-server/oauth [build failed]
# github.com/RichardKnop/go-oauth2-server/oauth
oauth/client.go:72: undefined: Client
oauth/service_interface.go:35: undefined: Client
ok      github.com/RichardKnop/go-oauth2-server/oauth/roles 0.004s
?       github.com/RichardKnop/go-oauth2-server/oauth/tokentypes    [no test files]
ok      github.com/RichardKnop/go-oauth2-server/session 0.006s [no tests to run]
ok      github.com/RichardKnop/go-oauth2-server/test-util   0.874s
ok      github.com/RichardKnop/go-oauth2-server/util    0.004s
?       github.com/RichardKnop/go-oauth2-server/util/migrations [no test files]
ok      github.com/RichardKnop/go-oauth2-server/util/password   0.162s
ok      github.com/RichardKnop/go-oauth2-server/util/response   0.004s
ok      github.com/RichardKnop/go-oauth2-server/util/routes 0.004s
# github.com/RichardKnop/go-oauth2-server/oauth
oauth/client.go:72: undefined: Client
oauth/service_interface.go:35: undefined: Client
make: *** [test] Error 123
RichardKnop commented 7 years ago

@PumpkinSeed OK this seems to be related to refactoring of models I did a while ago.

I have moved all models to models package so now you would use models.OauthClient instead of Client in the oauth package.