File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1313
1414session_start ();
1515
16+ if (!file_exists ('settings.php ' )) {
17+ echo 'The settings.php file is missing. See settings.php.dist for an example. ' ;
18+ die ();
19+ }
20+
1621$ settings = require 'settings.php ' ;
1722$ apiUri = $ settings ['apiUri ' ];
1823
6065$ module ->setCertificate ($ certificate );
6166$ module ->setExtraCertificates ($ certificates );
6267
63- if (!isset ($ _GET ['otp ' ]) && !isset ($ _GET ['pin ' ])) {
64- echo 'No OTP nor PIN given. ' ;
68+ if ($ credentialInfo ['authMode ' ] === 'explicit ' && !isset ($ _GET ['otp ' ]) && !isset ($ _GET ['pin ' ])) {
69+ // you should check the OTP and/or PIN entry in $credentialInfo for how to setup authentication exactly
70+ echo 'Please enter OTP or PIN: ' ;
6571 echo '<form><input type="text" name="otp" placeholder="OTP"> or <input type="text" name="pin" placeholder="PIN"> ' ;
66- echo ' or leave blank for implicit authorization. ' ;
6772 echo '<input type="submit"/></form> ' ;
6873 die ();
6974}
Original file line number Diff line number Diff line change 1313
1414session_start ();
1515
16+ if (!file_exists ('settings.php ' )) {
17+ echo 'The settings.php file is missing. See settings.php.dist for an example. ' ;
18+ die ();
19+ }
20+
1621$ settings = require 'settings.php ' ;
1722$ apiUri = $ settings ['apiUri ' ];
1823
8287 $ module ->addCrl ($ crl );
8388}
8489
85- if (!isset ($ _GET ['otp ' ]) && !isset ($ _GET ['pin ' ])) {
86- echo 'No OTP nor PIN given. ' ;
90+ if ($ credentialInfo ['authMode ' ] === 'explicit ' && !isset ($ _GET ['otp ' ]) && !isset ($ _GET ['pin ' ])) {
91+ // you should check the OTP and/or PIN entry in $credentialInfo for how to setup authentication exactly
92+ echo 'Please enter OTP or PIN: ' ;
8793 echo '<form><input type="text" name="otp" placeholder="OTP"> or <input type="text" name="pin" placeholder="PIN"> ' ;
88- echo ' or leave blank for implicit authorization. ' ;
8994 echo '<input type="submit"/></form> ' ;
9095 die ();
9196}
You can’t perform that action at this time.
0 commit comments