Thanks Torsten,

Would you mind pasting the code or sharing in on a GitHub gist 
https://gist.github.com/ It will help people use it easier and also maybe 
give a bit more insight on how it works.

Cheers,
Jacobus

On Monday, 20 April 2015 10:37:02 UTC+2, wapgui wrote:
>
> def auth = HttpBasicAuthenticator.provideUserName {
>
>   case p @ UserCredentials.Provided(name) ⇒ p.verifySecret(name + "-password")
>   case _                                  ⇒ false
> }
>
>
> path("secure") {
>   HttpBasicAuthentication("My very secure site")(auth) { user ⇒
>     complete(HttpResponse(
>       entity = HttpEntity(MediaTypes.`text/html`, "<html><body>Hello <b>{ 
> user }</b>. Access has been granted!</body></html>")))
>   }
> }
>
>
> Did you looking for something like that?
>
> Am Sonntag, 19. April 2015 14:52:17 UTC+2 schrieb Jason Bass:
>>
>> Spray provided an authenticate directive that could be used for HTTP 
>> authentication.  That directive appears to have been dropped in Akka HTTP 
>> (I'm using v1.0-M5).  I'm curious whether the directive will find its way 
>> into the final release or whether there is an alternate method to 
>> facilitate authentication.  Thanks,
>>
>> Jason
>>
>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to