Zuviel in b24afac71c944 entfernt. Historie und Wiedervorlage wieder anzeigen
[kivitendo-erp.git] / SL / Auth / Constants.pm
1 package SL::Auth::Constants;
2
3 use strict;
4
5 use Exporter qw(import);
6
7 our %EXPORT_TAGS   = (
8   OK => [ qw(
9     OK
10   ) ],
11   ERR => [ qw(
12     ERR_PASSWORD
13     ERR_BACKEND
14     ERR_USER
15   ) ],
16   SESSION => [ qw(
17     SESSION_OK
18     SESSION_NONE
19     SESSION_EXPIRED
20   ) ],
21 );
22
23 # add all the other ":class" tags to the ":all" class,
24 # deleting duplicates
25 {
26  my %seen;
27  push @{$EXPORT_TAGS{all}}, grep {!$seen{$_}++} @$_ for values %EXPORT_TAGS;
28 }
29
30 Exporter::export_ok_tags('all');
31
32 use constant OK              =>   0;
33 use constant ERR_PASSWORD    =>   1;
34 use constant ERR_USER        =>   2;
35 use constant ERR_BACKEND     => 100;
36
37 use constant SESSION_OK      =>   0;
38 use constant SESSION_NONE    =>   1;
39 use constant SESSION_EXPIRED =>   2;
40
41 1;
42
43 __END__
44
45 =encoding utf8
46
47 =head1 NAME
48
49 SL::Auth::Constants - COnstants for Auth module
50
51 =head1 SYNOPSIS
52
53   use SL::Auth::Constants qw(:all);
54
55   OK == $auth->authenticate($user, $pass) or die;
56
57 =head1 DESCRIPTION
58
59 This module provides status constants for authentication handling
60
61 =head1 BUGS
62
63 none yet.
64
65 =head1 AUTHOR
66
67 Sven Schöling E<lt>s.schoeling@linet-services.deE<gt>
68
69 =cut