blob: 1b39352688a20ed76ac46117fef233da97554e39 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
package Net::Hawk::Server { use v6; our sub authenticate( %request!, &credentialsFunc:($,&)!, %whatever!, &callback:($,%,%)!, ) { my %creds; &credentialsFunc.('some id', sub ($err,%credentials) { %creds = %credentials }); %request<url> ~~ m{'bewit=' $<ext>=(.*?) ['&'|$]}; my %attributes = ( ext => $/<ext>; ); &callback.(Nil,%creds,%attributes); }; };
|