2015-04-27から1日間の記事一覧

GoRest は、少し思いだそうかな編

このかっこ悪いエラーは・・・・ ./app.go:55: cannot use SimpleAuthorizer (type func(string, string, *http.Request) (bool, bool, gorest.SessionData)) as type gorest.Authorizer in argument to gorest.RegisterRealmAuthorizer code.google.com/p/g…

GoRevel でBasic認証 追記

Basic認証だけだったら、問題なくいけるけど、Resutfulなアドレスを作りたいとなると、PUTとDELETEにあたるルーティングが見つからない。なので、Resutfulに拘るなら、ちょっとスルーしかないみたい。 逆に拘らないのであれば、設定周りとか結構やってくれて…

GoRevel でBasic認証

備忘録形式で。 参考HP https://gist.github.com/steffenmllr/6356331 但し、上記だけでは、駄目で https://gist.github.com/landaire/5963948 getCredentials関数は、下の方から拝借。app/controllers/init.go func init() { revel.InterceptFunc(CheckAuth…

GoRest GoWeb も、両方忘れようかな編

だって、うまく動きませぬ。 https://godoc.org/github.com/fromkeith/gorest の、Security 項目を組み込んで試行錯誤してるんですが、 ./app.go:55: cannot use SimpleAuthorizer (type func(string, string, *http.Request) (bool, bool, gorest.SessionDa…