1 | <?php |
||
20 | class AuthnRequest extends AbstractRequest |
||
21 | { |
||
22 | //region Attributes |
||
23 | |||
24 | /** @var bool|null */ |
||
25 | protected $forceAuthn; |
||
26 | |||
27 | /** @var bool|null */ |
||
28 | protected $isPassive; |
||
29 | |||
30 | /** @var int|null */ |
||
31 | protected $assertionConsumerServiceIndex; |
||
32 | |||
33 | /** @var string|null */ |
||
34 | protected $assertionConsumerServiceURL; |
||
35 | |||
36 | /** @var int|null */ |
||
37 | protected $attributeConsumingServiceIndex; |
||
38 | |||
39 | /** @var string|null */ |
||
40 | protected $protocolBinding; |
||
41 | |||
42 | /** @var string|null */ |
||
43 | protected $providerName; |
||
44 | |||
45 | //endregion |
||
46 | |||
47 | //region Elements |
||
48 | |||
49 | /** @var Conditions|null */ |
||
50 | protected $conditions; |
||
51 | |||
52 | /** @var NameIDPolicy|null */ |
||
53 | protected $nameIDPolicy; |
||
54 | |||
55 | /** @var Subject|null */ |
||
56 | protected $subject; |
||
57 | |||
58 | /** |
||
59 | * @param Subject|null $subject |
||
60 | * |
||
61 | * @return AuthnRequest |
||
62 | */ |
||
63 | 1 | public function setSubject(Subject $subject) |
|
69 | |||
70 | /** |
||
71 | * @return Subject|null |
||
72 | */ |
||
73 | 10 | public function getSubject() |
|
77 | |||
78 | /** |
||
79 | * @param null|string $providerName |
||
80 | * |
||
81 | * @return AuthnRequest |
||
82 | */ |
||
83 | 1 | public function setProviderName($providerName) |
|
89 | |||
90 | /** |
||
91 | * @return null|string |
||
92 | */ |
||
93 | 10 | public function getProviderName() |
|
97 | |||
98 | /** |
||
99 | * @param null|string $protocolBinding |
||
100 | * |
||
101 | * @return AuthnRequest |
||
102 | */ |
||
103 | 3 | public function setProtocolBinding($protocolBinding) |
|
109 | |||
110 | /** |
||
111 | * @return null|string |
||
112 | */ |
||
113 | 10 | public function getProtocolBinding() |
|
117 | |||
118 | /** |
||
119 | * @param NameIDPolicy|null $nameIDPolicy |
||
120 | * |
||
121 | * @return AuthnRequest |
||
122 | */ |
||
123 | 4 | public function setNameIDPolicy(NameIDPolicy $nameIDPolicy) |
|
129 | |||
130 | /** |
||
131 | * @return NameIDPolicy|null |
||
132 | */ |
||
133 | 10 | public function getNameIDPolicy() |
|
137 | |||
138 | /** |
||
139 | * @param bool|null $isPassive |
||
140 | * |
||
141 | * @return AuthnRequest |
||
142 | */ |
||
143 | 1 | public function setIsPassive($isPassive) |
|
149 | |||
150 | /** |
||
151 | * @return bool|null |
||
152 | */ |
||
153 | 1 | public function getIsPassive() |
|
157 | |||
158 | /** |
||
159 | * @return string|null |
||
160 | */ |
||
161 | 10 | public function getIsPassiveString() |
|
169 | |||
170 | /** |
||
171 | * @param bool|null $forceAuthn |
||
172 | * |
||
173 | * @return AuthnRequest |
||
174 | */ |
||
175 | 1 | public function setForceAuthn($forceAuthn) |
|
181 | |||
182 | /** |
||
183 | * @return bool|null |
||
184 | */ |
||
185 | 1 | public function getForceAuthn() |
|
189 | |||
190 | /** |
||
191 | * @return string|null |
||
192 | */ |
||
193 | 10 | public function getForceAuthnString() |
|
201 | |||
202 | /** |
||
203 | * @param Conditions|null $conditions |
||
204 | * |
||
205 | * @return AuthnRequest |
||
206 | */ |
||
207 | 1 | public function setConditions($conditions) |
|
213 | |||
214 | /** |
||
215 | * @return \LightSaml\Model\Assertion\Conditions|null |
||
216 | */ |
||
217 | 10 | public function getConditions() |
|
221 | |||
222 | /** |
||
223 | * @param null|int $attributeConsumingServiceIndex |
||
224 | * |
||
225 | * @return AuthnRequest |
||
226 | */ |
||
227 | 1 | public function setAttributeConsumingServiceIndex($attributeConsumingServiceIndex) |
|
235 | |||
236 | /** |
||
237 | * @return null|int |
||
238 | */ |
||
239 | 10 | public function getAttributeConsumingServiceIndex() |
|
243 | |||
244 | /** |
||
245 | * @param null|string $assertionConsumerServiceURL |
||
246 | * |
||
247 | * @return AuthnRequest |
||
248 | */ |
||
249 | 6 | public function setAssertionConsumerServiceURL($assertionConsumerServiceURL) |
|
255 | |||
256 | /** |
||
257 | * @return null|string |
||
258 | */ |
||
259 | 18 | public function getAssertionConsumerServiceURL() |
|
263 | |||
264 | /** |
||
265 | * @param null|int $assertionConsumerServiceIndex |
||
266 | * |
||
267 | * @return AuthnRequest |
||
268 | */ |
||
269 | 2 | public function setAssertionConsumerServiceIndex($assertionConsumerServiceIndex) |
|
277 | |||
278 | /** |
||
279 | * @return null|int |
||
280 | */ |
||
281 | 17 | public function getAssertionConsumerServiceIndex() |
|
285 | |||
286 | //endregion |
||
287 | |||
288 | /** |
||
289 | * @param \DOMNode $parent |
||
290 | * @param SerializationContext $context |
||
291 | * |
||
292 | * @return void |
||
293 | */ |
||
294 | 9 | public function serialize(\DOMNode $parent, SerializationContext $context) |
|
310 | |||
311 | /** |
||
312 | * @param \DOMNode $node |
||
313 | * @param DeserializationContext $context |
||
314 | */ |
||
315 | 8 | public function deserialize(\DOMNode $node, DeserializationContext $context) |
|
332 | } |
||
333 |
This check looks for parameters that are defined as one type in their type hint or doc comment but seem to be used as a narrower type, i.e an implementation of an interface or a subclass.
Consider changing the type of the parameter or doing an instanceof check before assuming your parameter is of the expected type.