Commit | Line | Data |
b94c4996 |
1 | package RemoteTestApp2; |
d055ce0c |
2 | use strict; |
3 | use warnings; |
b94c4996 |
4 | |
5 | use Catalyst qw/ |
6 | Authentication |
7 | /; |
8 | |
9 | use base qw/Catalyst/; |
afa31b01 |
10 | unless ($Catalyst::VERSION >= 5.89000) { |
11 | __PACKAGE__->engine_class('RemoteTestEngine'); |
12 | } |
b94c4996 |
13 | __PACKAGE__->config( |
14 | 'Plugin::Authentication' => { |
15 | default_realm => 'remote', |
16 | realms => { |
17 | remote => { |
18 | credential => { |
19 | class => 'Remote', |
20 | allow_regexp => '^(bob|john|CN=.*)$', |
21 | deny_regexp=> 'denied', |
22 | cutname_regexp=> 'CN=(.*)/OU=Test', |
23 | source => 'SSL_CLIENT_S_DN', |
7289cea0 |
24 | username_field => 'my_user_name', |
b94c4996 |
25 | }, |
26 | store => { |
27 | class => 'Null', |
28 | }, |
29 | }, |
30 | }, |
31 | }, |
32 | ); |
b94c4996 |
33 | __PACKAGE__->setup; |
afa31b01 |
34 | if ($Catalyst::VERSION >= 5.89000) { |
35 | require RemoteTestEngineRole; |
36 | RemoteTestEngineRole->meta->apply(__PACKAGE__->engine); |
37 | } |
b94c4996 |
38 | |
d055ce0c |
39 | 1; |
40 | |