|
From: <wis...@us...> - 2014-12-08 20:53:53
|
Revision: 12892
http://sourceforge.net/p/xoops/svn/12892
Author: wishcraft
Date: 2014-12-08 20:53:40 +0000 (Mon, 08 Dec 2014)
Log Message:
-----------
Fixing Trunk
Added Paths:
-----------
XoopsModules/signed/trunk/modules/signed/api/
XoopsModules/signed/trunk/modules/signed/api/banned/
XoopsModules/signed/trunk/modules/signed/api/banned/.htaccess
XoopsModules/signed/trunk/modules/signed/api/banned/index.php
XoopsModules/signed/trunk/modules/signed/api/classes/
XoopsModules/signed/trunk/modules/signed/api/classes/.htaccess
XoopsModules/signed/trunk/modules/signed/api/classes/index.php
XoopsModules/signed/trunk/modules/signed/api/descriptions/
XoopsModules/signed/trunk/modules/signed/api/descriptions/.htaccess
XoopsModules/signed/trunk/modules/signed/api/descriptions/index.php
XoopsModules/signed/trunk/modules/signed/api/enumerators/
XoopsModules/signed/trunk/modules/signed/api/enumerators/.htaccess
XoopsModules/signed/trunk/modules/signed/api/enumerators/index.php
XoopsModules/signed/trunk/modules/signed/api/fields/
XoopsModules/signed/trunk/modules/signed/api/fields/.htaccess
XoopsModules/signed/trunk/modules/signed/api/fields/index.php
XoopsModules/signed/trunk/modules/signed/api/fieldtypes/
XoopsModules/signed/trunk/modules/signed/api/fieldtypes/.htaccess
XoopsModules/signed/trunk/modules/signed/api/fieldtypes/index.php
XoopsModules/signed/trunk/modules/signed/api/identifications/
XoopsModules/signed/trunk/modules/signed/api/identifications/.htaccess
XoopsModules/signed/trunk/modules/signed/api/identifications/index.php
XoopsModules/signed/trunk/modules/signed/api/index.php
XoopsModules/signed/trunk/modules/signed/api/language/
XoopsModules/signed/trunk/modules/signed/api/language/.htaccess
XoopsModules/signed/trunk/modules/signed/api/language/index.php
XoopsModules/signed/trunk/modules/signed/api/languages/
XoopsModules/signed/trunk/modules/signed/api/languages/.htaccess
XoopsModules/signed/trunk/modules/signed/api/languages/index.php
XoopsModules/signed/trunk/modules/signed/api/processes/
XoopsModules/signed/trunk/modules/signed/api/processes/.htaccess
XoopsModules/signed/trunk/modules/signed/api/processes/index.php
XoopsModules/signed/trunk/modules/signed/api/prompts/
XoopsModules/signed/trunk/modules/signed/api/prompts/.htaccess
XoopsModules/signed/trunk/modules/signed/api/prompts/index.php
XoopsModules/signed/trunk/modules/signed/api/providers/
XoopsModules/signed/trunk/modules/signed/api/providers/.htaccess
XoopsModules/signed/trunk/modules/signed/api/providers/index.php
XoopsModules/signed/trunk/modules/signed/api/request/
XoopsModules/signed/trunk/modules/signed/api/request/.htaccess
XoopsModules/signed/trunk/modules/signed/api/request/index.php
XoopsModules/signed/trunk/modules/signed/api/sign/
XoopsModules/signed/trunk/modules/signed/api/sign/.htaccess
XoopsModules/signed/trunk/modules/signed/api/sign/index.php
XoopsModules/signed/trunk/modules/signed/api/signatures/
XoopsModules/signed/trunk/modules/signed/api/signatures/.htaccess
XoopsModules/signed/trunk/modules/signed/api/signatures/index.php
XoopsModules/signed/trunk/modules/signed/api/sites/
XoopsModules/signed/trunk/modules/signed/api/sites/.htaccess
XoopsModules/signed/trunk/modules/signed/api/sites/index.php
XoopsModules/signed/trunk/modules/signed/api/states/
XoopsModules/signed/trunk/modules/signed/api/states/.htaccess
XoopsModules/signed/trunk/modules/signed/api/states/index.php
XoopsModules/signed/trunk/modules/signed/api/validate.php
XoopsModules/signed/trunk/modules/signed/api/validations/
XoopsModules/signed/trunk/modules/signed/api/validations/.htaccess
XoopsModules/signed/trunk/modules/signed/api/validations/index.php
XoopsModules/signed/trunk/modules/signed/api/verification/
XoopsModules/signed/trunk/modules/signed/api/verification/.htaccess
XoopsModules/signed/trunk/modules/signed/api/verification/index.php
XoopsModules/signed/trunk/modules/signed/api/verify/
XoopsModules/signed/trunk/modules/signed/api/verify/.htaccess
XoopsModules/signed/trunk/modules/signed/api/verify/index.php
Added: XoopsModules/signed/trunk/modules/signed/api/banned/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/banned/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/banned/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/banned/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/banned/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/banned/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/banned/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,44 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'banned' => array('hostname' => signedSecurity::getInstance()->getBannedHostnames(), 'ip' => signedSecurity::getInstance()->getBannedIP()), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/banned/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/classes/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/classes/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/classes/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/classes/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/classes/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/classes/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/classes/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,50 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'classes' => signedProcesses::getInstance()->getClassArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/classes/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/descriptions/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/descriptions/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/descriptions/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/descriptions/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/descriptions/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/descriptions/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/descriptions/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,50 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'descriptions' => signedProcesses::getInstance()->getFieldDescriptions(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/descriptions/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/enumerators/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/enumerators/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/enumerators/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/enumerators/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/enumerators/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/enumerators/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/enumerators/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'enumerators' => signedProcesses::getInstance()->getEnumeratorsArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/enumerators/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/fields/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/fields/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/fields/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/fields/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/fields/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/fields/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/fields/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'fields' => signedProcesses::getInstance()->getFieldsArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/fields/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/fieldtypes/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/fieldtypes/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/fieldtypes/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/fieldtypes/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/fieldtypes/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/fieldtypes/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/fieldtypes/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'fieldtypes' => signedProcesses::getInstance()->getFieldnamesArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/fieldtypes/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/identifications/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/identifications/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/identifications/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/identifications/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/identifications/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/identifications/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/identifications/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'identifications' => signedProcesses::getInstance()->getIdentificationsArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/identifications/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,29 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+define('_SIGNED_EVENT_SYSTEM', 'api');
+define('_SIGNED_EVENT_TYPE', 'help');
+require dirname(dirname(__FILE__)) . DIRECTORY_SEPARATOR . 'header.php';
+require dirname(__FILE__) . _DS_ . 'validate.php';
+require _PATH_TEMPLATES . _DS_ . 'common' . _DS_ . 'api.php';
+require dirname(dirname(__FILE__)) . DIRECTORY_SEPARATOR . 'footer.php';
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/language/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/language/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/language/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/language/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/language/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/language/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/language/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,41 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'constants' => signedProcesses::getInstance()->getLanguageArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/language/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/languages/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/languages/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/languages/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/languages/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/languages/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/languages/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/languages/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,41 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'languages' => signedProcesses::getInstance()->getLanguages(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/languages/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/processes/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/processes/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/processes/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/processes/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/processes/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/processes/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/processes/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'processes' => signedProcesses::getInstance()->getProcessesArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/processes/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/prompts/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/prompts/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/prompts/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/prompts/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/prompts/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/prompts/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/prompts/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'prompts' => signedProcesses::getInstance()->getPromptsArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/prompts/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/providers/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/providers/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/providers/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/providers/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/providers/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/providers/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/providers/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,49 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ if (isset($_GET['language'])&&!empty($_GET['language'])) {
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'providers' => signedProcesses::getInstance()->getProvidedArray(), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('language')) . ' ~ was not specified!', 'error-code' => '135'));
+ exit(0);
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/trunk/modules/signed/api/providers/index.php
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/request/.htaccess
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/request/.htaccess (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/request/.htaccess 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,6 @@
+<IfModule mod_rewrite.c>
+
+ RewriteEngine On
+ RewriteRule ^$ index.php
+
+</IfModule>
Property changes on: XoopsModules/signed/trunk/modules/signed/api/request/.htaccess
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Added: XoopsModules/signed/trunk/modules/signed/api/request/index.php
===================================================================
--- XoopsModules/signed/trunk/modules/signed/api/request/index.php (rev 0)
+++ XoopsModules/signed/trunk/modules/signed/api/request/index.php 2014-12-08 20:53:40 UTC (rev 12892)
@@ -0,0 +1,181 @@
+<?php
+/**
+ * Chronolabs Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ *
+ * You may not change or alter any portion of this comment or credits
+ * of supporting developers from this source code or any supporting source code
+ * which is considered copyrighted (c) material of the original comment or credit authors.
+ * 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.
+ *
+ * @copyright Chronolabs Cooperative http://labs.coop
+ * @license General Software Licence (https://web.labs.coop/public/legal/general-software-license/10,3.html)
+ * @package signed
+ * @since 1.13
+ * @author Simon Roberts <wis...@us...>
+ * @author Antony Cipher <ci...@la...>
+ * @subpackage api
+ * @description Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ * @link https://signed.labs.coop Digital Signature Generation & API Services (Psuedo-legal correct binding measure)
+ */
+
+ // Enables API Runtime Constant
+ define('_SIGNED_API_FUNCTION', basename(dirname(__FILE__)));
+ define('_SIGNED_EVENT_SYSTEM', 'api');
+ define('_SIGNED_EVENT_TYPE', basename(dirname(__FILE__)));
+
+ require_once dirname(dirname(dirname(__FILE__))) . DIRECTORY_SEPARATOR . 'include' . DIRECTORY_SEPARATOR . 'common.php';
+ require dirname(dirname(__FILE__)) . _DS_ . 'validate.php';
+
+ // Checks if API Function is Enabled
+ if (!in_array(basename(dirname(__FILE__)), $GLOBALS['api']->callKeys())) {
+ header("Location: " . _URL_ROOT);
+ exit(0);
+ }
+
+ foreach($_REQUEST as $field => $value) {
+ if (!empty($value)||strlen(trim($value))!=0)
+ $data[$field] = $value;
+ }
+
+ $GLOBALS['io'] = signedStorage::getInstance(_SIGNED_RESOURCES_STORAGE);
+
+ $states = signedProcesses::getInstance()->getRequestStatesArray();
+ $fields = signedProcesses::getInstance()->getFieldsArray();
+ $identifications = signedProcesses::getInstance()->getIdentificationsArray();
+ $signatures = signedProcesses::getInstance()->getSignatures();
+
+ if (signedAPI::getInstance()->verifyAPIFields(basename(dirname(__FILE__)), $data)==true) {
+ $servicekey = signedSecurity::getInstance()->extractServiceKey($data['code'], $data['certificate'], $data['verification-key']);
+ if (signedSecurity::getInstance()->getHostCode()==$servicekey) {
+ if ($signature = signedCiphers::getInstance()->getSignature($data['serial-number'], $data['code'], $data['certificate'], $data['any-name'], $data['any-email'], $data['any-date'], true)) {
+ $request = $GLOBALS['io']->load(_PATH_PATHWAYS_REQUEST, $signature['serial-number']);
+ $type = $signature['signature']['type'];
+ if ($request['sent']!=0 || $request['sent']<time()) {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding request has been sent to the client, this means until it is resolved you will be not be able to request anymore changes to their signature!', 'error-code' => '302'));
+ exit(0);
+ }
+ if (!in_array($data['type-key'], $types = array_merge(array_key($identifications[$type]), array_key($signatures)))) {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding \'type-key\' is not found ~ the only available options for this signature are: '.implode(', ', $types) . '!', 'error-code' => '303'));
+ exit(0);
+ }
+ if (!in_array($data['request-code'], array_key($states))) {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding \'request-code\' is not found ~ the only available options for this signature are: '.implode(', ', array_key($states)) . '!', 'error-code' => '304'));
+ exit(0);
+ }
+ if (in_array($data['type-key'], array_key($identifications[$type])))
+ {
+ $clause = 'identification';
+ } else {
+ $clause = $data['type-key'];
+ }
+ foreach($data['fields'] as $key => $field) {
+ if (!in_array($field, array_key($fields[$clause]))) {
+ unset($data['fields'][$key]);
+ }
+ }
+ foreach($data['fields'] as $key => $field) {
+ if (in_array($data['type-key'], array_key($identifications[$type])))
+ {
+ $request['request'][$type][$clause][$data['type-key']][$field] = $data['request-code'];
+ } else {
+ $request['request'][$type][$clause][$field] = $data['request-code'];
+ }
+ }
+ if (in_array($data['type-key'], array_key($identifications[$type])))
+ {
+ $request['fields'][$data['type-key']] = array_keys($request['request'][$type][$clause][$data['type-key']][$field]);
+ } else {
+ $request['fields'][$clause] = array_keys($request['request'][$type][$clause][$field]);
+ }
+ if (isset($data['callback-url'])) {
+ $request['callback']['action'] = true;
+ $request['callback'][md5($data['callback-url'])]['url'] = $data['callback-url'];
+ $request['callback'][md5($data['callback-url'])]['fields']['signature-package'] = $data['signature-package-field'];
+ $request['callback'][md5($data['callback-url'])]['fields']['request-rejected'] = $data['request-rejected-field'];
+ $request['callback'][md5($data['callback-url'])]['fields']['signature-updated'] = $data['signature-updated-field'];
+ } else {
+ if (!isset($request['callback']['action']))
+ $request['callback']['action'] = false;
+ }
+
+ $uniqueid = (isset($data['polling-unique-id'])&&!empty($data['polling-unique-id'])?$data['polling-unique-id']:'TM-'.time()) . "--" . (count(array_keys($request['client'])) + 1);
+ if (in_array($uniqueid, array_keys($request['client'])))
+ $uniqueid .= ':--' . str_replace('.', '-', microtime(true));
+ if (isset($data['client-name']))
+ $request['calling'][$uniqueid]['client']['name'] = $data['client-name'];
+ if (isset($data['client-uname']))
+ $request['calling'][$uniqueid]['client']['uname'] = $data['client-uname'];
+ if (isset($data['client-email']))
+ $request['calling'][$uniqueid]['client']['email'] = $data['client-email'];
+
+ if (isset($data['client-site-name']))
+ $request['calling'][$uniqueid]['client']['sitename'] = $data['site-name'];
+ if (isset($data['client-site-uri']))
+ $request['calling'][$uniqueid]['client']['uri'] = $data['site-uri'];
+ $request['calling'][$uniqueid]['client']['netbios'] = gethostbyaddr(signedSecurity::getInstance()->getIP(true));
+ $request['calling'][$uniqueid]['client']['ip'] = json_decode(file_get_contents("http://lookups.labs.coop/v1/country/".signedSecurity::getInstance()->getIP(true)."/json.api"), true);
+ $request['calling'][$uniqueid]['instance'] = $_SESSION["signed"]['instance']['number'];
+ $request['calling-ids'] = array_keys($request['calling']);
+
+ $GLOBALS['io']->save($request, _PATH_PATHWAYS_REQUEST, $signature['serial-number']);
+
+ if (function_exists('http_response_code'))
+ http_response_code(200);
+ echo $GLOBALS['api']->format(array('success'=> true, 'queued-requests' => $request['request'], 'sending-request' => date('Y-m-d H:i:s', $request['reminder']), 'when' => time()));
+ @$GLOBALS['logger']->logPolling('default', basename(dirname(__FILE__)), array('server' => $_SERVER, 'request' => $_REQUEST));
+ exit(0);
+
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'The corresponding field(s): '.implode(', ', array('serial-number', 'code', 'certificate')) . ' ~ did not correspond with the same signature or was wrong!', 'error-code' => '104'));
+ exit(0);
+ }
+ } else {
+ foreach(signedProcesses::getInstance()->getSites() as $key => $srv) {
+ if ($srv['code'] == $servicekey) {
+ $service = $srv;
+ continue;
+ }
+ }
+
+ if (isset($service)) {
+ if (!$ch = curl_init($url = $service['protocol'] . '://' . $service['api-uri'] . '/' . basename(dirname(__FILE__)) . '/')) {
+ trigger_error('Could not intialise CURL file: '.$url);
+ return false;
+ }
+ $cookies = _PATH_CACHE.'/api-'.md5($url).'.cookie';
+
+ curl_setopt($ch, CURLOPT_HEADER, 0);
+ curl_setopt($ch, CURLOPT_POST, 1);
+ curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($data));
+ curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 190);
+ curl_setopt($ch, CURLOPT_TIMEOUT, 190);
+ curl_setopt($ch, CURLOPT_COOKIEJAR, $cookies);
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
+ curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);
+ curl_setopt($ch, CURLOPT_USERAGENT, $_SERVER['HTTP_USER_AGENT']);
+ $data = curl_exec($ch);
+ $info = curl_getinfo($ch);
+ curl_close($ch);
+ if (function_exists('http_response_code'))
+ http_response_code($info['http_code']);
+ echo $data;
+ exit(0);
+ } else {
+ if (function_exists('http_response_code'))
+ http_response_code(400);
+ echo $GLOBALS['api']->format(array('success'=> false, 'error'=> 'Service Key:~ '.$servicekey.' is unknown and not a trusted ensignator!', 'error-code' => '115'));
+ exit(0);
+ }
+ }
+ }
+?>
\ No newline at end of file
Property changes on: XoopsModules/signed/tr...
[truncated message content] |