Changeset 1549267
- Timestamp:
- 12/08/2016 12:32:41 PM (9 years ago)
- Location:
- secsign/trunk
- Files:
-
- 4 edited
-
jsApi/SecSignIDApi.js (modified) (4 diffs)
-
jsApi/signin-bridge.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
secsignid_login.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
secsign/trunk/jsApi/SecSignIDApi.js
r1486368 r1549267 68 68 secsignid = options.secsignid.toLowerCase().trim(); 69 69 70 // check again. probably just spaces s which will ne empty after trim()70 // check again. probably just spaces which will be empty after trim() 71 71 if(!options.secsignid){ 72 72 throw new Error("SecSign ID is null."); … … 110 110 if(!options){ 111 111 throw new Error("No options given to get authentication session state."); 112 } 113 114 if(!options.secsignid || !options.authsessionid || !options.requestid){ 115 throw new Error("Missing values in options to get authentication session state."); 112 116 } 113 117 … … 142 146 } 143 147 148 if(!options.secsignid || !options.authsessionid || !options.requestid){ 149 throw new Error("Missing values in options to cancel authentication session."); 150 } 151 144 152 /* 145 153 options = { … … 170 178 if(!options){ 171 179 throw new Error("No options given to release authentication session."); 180 } 181 182 if(!options.secsignid || !options.authsessionid || !options.requestid){ 183 throw new Error("Missing values in options to release authentication session."); 172 184 } 173 185 -
secsign/trunk/jsApi/signin-bridge.php
r1405425 r1549267 22 22 try 23 23 { 24 // request an authentication session. 25 if(isset($_POST['pluginname'])){ 26 $secSignIDApi->setPluginName($_POST['pluginname']); 27 } 28 $secSignIDApi->requestAuthSession($_POST['secsignid'], $_POST['servicename'], $_POST['serviceaddress']); 29 $response = $secSignIDApi->getResponse(); 24 if(empty($_POST['secsignid'])){ 25 $response = urlencode("error=500;errormsg=no secsign id was found in header values. could not create authentication session."); 26 } else { 27 // request an authentication session. 28 if(isset($_POST['pluginname'])){ 29 $secSignIDApi->setPluginName($_POST['pluginname']); 30 } 31 $secSignIDApi->requestAuthSession($_POST['secsignid'], $_POST['servicename'], $_POST['serviceaddress']); 32 $response = $secSignIDApi->getResponse(); 33 } 30 34 } 31 35 catch(Exception $e){ … … 35 39 try 36 40 { 37 $servicename = isset($_POST['servicename']) ? $_POST['servicename'] : ""; 38 $serviceaddress = isset($_POST['serviceaddress']) ? $_POST['serviceaddress'] : ""; 41 // check whether a secsign id is given. if not there is no need to bridge the request 42 43 if(empty($_POST['secsignid'])){ 44 $response = urlencode("error=500;errormsg=no secsign id was found in header values. request is not sent."); 45 } else { 46 47 $servicename = isset($_POST['servicename']) ? $_POST['servicename'] : ""; 48 $serviceaddress = isset($_POST['serviceaddress']) ? $_POST['serviceaddress'] : ""; 39 49 40 // create auth session object 41 $authsession = new AuthSession(); 42 $authsession->createAuthSessionFromArray(array( 43 'requestid' => $_POST['requestid'], 44 'secsignid' => $_POST['secsignid'], 45 'authsessionid' => $_POST['authsessionid'], 46 'servicename' => $servicename, 47 'serviceaddress' => $serviceaddress 48 ), true); 49 50 if(strcmp($_REQUEST['request'], "ReqGetAuthSessionState") == 0){ 51 52 // send request to check authentication session from javascript api to id-server via php api 53 $secSignIDApi->getAuthSessionState($authsession); 54 $response = $secSignIDApi->getResponse(); 55 56 } else if(strcmp($_REQUEST['request'], "ReqReleaseAuthSession") == 0){ 57 58 // send request to release authentication session from javascript api to id-server via php api 59 $secSignIDApi->releaseAuthSession($authsession); 60 $response = $secSignIDApi->getResponse(); 61 62 } else if(strcmp($_REQUEST['request'], "ReqCancelAuthSession") == 0){ 63 64 // send request to cancel authentication session from javascript api to id-server via php api 65 $secSignIDApi->cancelAuthSession($authsession); 66 $response = $secSignIDApi->getResponse(); 67 } 68 else { 69 // unknown request. cannot bridge it to id server via php api 70 $response = urlencode("error=500;errormsg=unknown request;"); 50 // create auth session object 51 $authsession = new AuthSession(); 52 $authsession->createAuthSessionFromArray(array( 53 'requestid' => $_POST['requestid'], 54 'secsignid' => $_POST['secsignid'], 55 'authsessionid' => $_POST['authsessionid'], 56 'servicename' => $servicename, 57 'serviceaddress' => $serviceaddress 58 ), true); 59 60 if(strcmp($_REQUEST['request'], "ReqGetAuthSessionState") == 0){ 61 62 // send request to check authentication session from javascript api to id-server via php api 63 $secSignIDApi->getAuthSessionState($authsession); 64 $response = $secSignIDApi->getResponse(); 65 66 } else if(strcmp($_REQUEST['request'], "ReqReleaseAuthSession") == 0){ 67 68 // send request to release authentication session from javascript api to id-server via php api 69 $secSignIDApi->releaseAuthSession($authsession); 70 $response = $secSignIDApi->getResponse(); 71 72 } else if(strcmp($_REQUEST['request'], "ReqCancelAuthSession") == 0){ 73 74 // send request to cancel authentication session from javascript api to id-server via php api 75 $secSignIDApi->cancelAuthSession($authsession); 76 $response = $secSignIDApi->getResponse(); 77 } 78 else { 79 // unknown request. cannot bridge it to id server via php api 80 $response = urlencode("error=500;errormsg=unknown request;"); 81 } 71 82 } 72 83 } -
secsign/trunk/readme.txt
r1486368 r1549267 3 3 Tags: two-factor authentication, two-factor, authentication, 2 factor authentication, login, sign in, single sign-on, challenge response, rsa, password, mobile, iphone, android, security, authenticator, authenticate, two step authentication, 2fa, tfa 4 4 Requires at least: 3.0.1 5 Tested up to: 4. 65 Tested up to: 4.7 6 6 Stable tag: trunk 7 7 License: GPLv2 or later … … 160 160 == Changelog == 161 161 162 = 1.7.12 = 163 * New version of [SecSignIDApi.js](https://github.com/SecSign/secsign-js-api) 164 * Tested WP compatibility for Wordpress 4.7 165 166 Note: Due to changes at the javascript files, please flush the page cache or any other cache you are using to have the updated files within the browser. 167 162 168 = 1.7.11 = 163 169 * New version of [SecSignIDApi.js](https://github.com/SecSign/secsign-js-api) -
secsign/trunk/secsignid_login.php
r1486368 r1549267 3 3 Plugin Name: SecSign 4 4 Plugin URI: https://www.secsign.com/wordpress-tutorial/ 5 Version: 1.7.1 15 Version: 1.7.12 6 6 Description: Two-factor authentication (2FA) with the SecSign ID. The SecSign plugin allows a user to login using his SecSign ID and his smartphone. 7 7 Author: SecSign Technologies Inc.
Note: See TracChangeset
for help on using the changeset viewer.