OID.php 5.31 KB
Newer Older
1
2
<?php
/*
3
4
  This code is part of FusionDirectory\Ldap (http://www.fusiondirectory.org/)

5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
  Copyright (C) 2020  FusionDirectory

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program; if not, write to the Free Software
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/

22
declare(strict_types = 1);
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185

namespace FusionDirectory\Ldap;

class OID
{
  public const CONTROLS = [
    LDAP_CONTROL_MANAGEDSAIT => [
      'desc'  => 'Manage DSA IT',
      'rfc'   => 3296,
    ],
    LDAP_CONTROL_PROXY_AUTHZ => [
      'desc'  => 'Proxied Authorization',
      'rfc'   => 4370,
    ],
    LDAP_CONTROL_SUBENTRIES => [
      'desc'  => 'Subentries',
      'rfc'   => 3672,
    ],
    LDAP_CONTROL_VALUESRETURNFILTER => [
      'desc'  => 'Filter returned values',
      'rfc'   => 3876,
    ],
    LDAP_CONTROL_ASSERT => [
      'desc'  => 'Assertion',
      'rfc'   => 4528,
    ],
    LDAP_CONTROL_PRE_READ => [
      'desc'  => 'Pre read',
      'rfc'   => 4527,
    ],
    LDAP_CONTROL_POST_READ => [
      'desc'  => 'Post read',
      'rfc'   => 4527,
    ],
    LDAP_CONTROL_SORTREQUEST => [
      'desc'  => 'Sort request',
      'rfc'   => 2891,
    ],
    LDAP_CONTROL_SORTRESPONSE => [
      'desc'  => 'Sort response',
      'rfc'   => 2891,
    ],
    LDAP_CONTROL_PAGEDRESULTS => [
      'desc'  => 'Paged results',
      'rfc'   => 2696,
    ],
    '2.16.840.1.113730.3.4.16' => [
      'desc'  => 'Authorization Identity Request',
      'rfc'   => 3829,
    ],
    '2.16.840.1.113730.3.4.15' => [
      'desc'  => 'Authorization Identity Response',
      'rfc'   => 3829,
    ],
    LDAP_CONTROL_SYNC => [
      'desc'  => 'Content Synchronization Operation',
      'rfc'   => 4533,
    ],
    LDAP_CONTROL_SYNC_STATE => [
      'desc'  => 'Content Synchronization Operation State',
      'rfc'   => 4533,
    ],
    LDAP_CONTROL_SYNC_DONE => [
      'desc'  => 'Content Synchronization Operation Done',
      'rfc'   => 4533,
    ],
    LDAP_CONTROL_DONTUSECOPY => [
      'desc'  => 'Don\'t Use Copy',
      'rfc'   => 6171,
    ],
    /* LDAP_CONTROL_PASSWORDPOLICYREQUEST and LDAP_CONTROL_PASSWORDPOLICYRESPONSE are the same */
    LDAP_CONTROL_PASSWORDPOLICYREQUEST => [
      'desc'  => 'Password Policy',
    ],
    LDAP_CONTROL_X_INCREMENTAL_VALUES => [
      'desc'  => 'Active Directory Incremental Values',
    ],
    LDAP_CONTROL_X_DOMAIN_SCOPE => [
      'desc'  => 'Active Directory Domain Scope',
    ],
    LDAP_CONTROL_X_PERMISSIVE_MODIFY => [
      'desc'  => 'Active Directory Permissive Modify',
    ],
    LDAP_CONTROL_X_SEARCH_OPTIONS => [
      'desc'  => 'Active Directory Search Options',
    ],
    LDAP_CONTROL_X_TREE_DELETE => [
      'desc'  => 'Active Directory Tree Delete',
    ],
    LDAP_CONTROL_X_EXTENDED_DN => [
      'desc'  => 'Active Directory Extended DN',
    ],
    LDAP_CONTROL_VLVREQUEST => [
      'desc'  => 'Virtual List View Request',
    ],
    LDAP_CONTROL_VLVRESPONSE => [
      'desc'  => 'Virtual List View Response',
    ],
  ];

  public const LDAP_EXOP_CANCEL = '1.3.6.1.1.8';

  public const EXOPS = [
    LDAP_EXOP_START_TLS => [
      'desc'  => 'Start TLS',
      'rfc'   => 4511,
    ],
    LDAP_EXOP_MODIFY_PASSWD => [
      'desc'  => 'Modify password',
      'rfc'   => 3062,
    ],
    LDAP_EXOP_REFRESH => [
      'desc'  => 'Refresh',
      'rfc'   => 2589,
    ],
    LDAP_EXOP_WHO_AM_I => [
      'desc'  => 'WHOAMI',
      'rfc'   => 4532,
    ],
    LDAP_EXOP_TURN => [
      'desc'  => 'Turn',
      'rfc'   => 4531,
    ],
    OID::LDAP_EXOP_CANCEL => [
      'desc'  => 'Cancel operation',
      'rfc'   => 3909,
    ],
  ];

  public const LDAP_FEATURE_MODIFYINCREMENT           = '1.3.6.1.1.14';
  public const LDAP_FEATURE_ALLOPERATIONALATTRIBUTES  = '1.3.6.1.4.1.4203.1.5.1';
  public const LDAP_FEATURE_RETURNALLATTRIBUTES       = '1.3.6.1.4.1.4203.1.5.2';
  public const LDAP_FEATURE_ABSOLUTEFILTERS           = '1.3.6.1.4.1.4203.1.5.3';
  public const LDAP_FEATURE_LANGUAGETAG               = '1.3.6.1.4.1.4203.1.5.4';
  public const LDAP_FEATURE_RANGEMATCHING             = '1.3.6.1.4.1.4203.1.5.5';

  public const FEATURES = [
    OID::LDAP_FEATURE_MODIFYINCREMENT => [
      'desc'  => 'Modify-Increment Extension',
      'rfc'   => 4525,
    ],
    OID::LDAP_FEATURE_ALLOPERATIONALATTRIBUTES => [
      'desc'  => 'All Operational Attributes',
      'rfc'   => 3673,
    ],
    OID::LDAP_FEATURE_RETURNALLATTRIBUTES => [
      'desc'  => 'Return of All Attributes of an Object Class',
      'rfc'   => 4529,
    ],
    OID::LDAP_FEATURE_ABSOLUTEFILTERS => [
      'desc'  => 'Absolute True and False Filters',
      'rfc'   => 4526,
    ],
    OID::LDAP_FEATURE_LANGUAGETAG => [
      'desc'  => 'Language Tag Options',
      'rfc'   => 3866,
    ],
    OID::LDAP_FEATURE_RANGEMATCHING => [
      'desc'  => 'Language Range Matching of Attributes',
      'rfc'   => 3866,
    ],
  ];
}