From 47aabf4fda8e3284e6c9684b3c24e4236786e5c6 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Sat, 18 Jun 2016 00:00:32 +0200 Subject: [PATCH] Let's just put the namespaced phpseclib in extlib instead of plugins/OStatus/extlib --- .../extlib => extlib}/phpseclib/Crypt/AES.php | 0 .../extlib => extlib}/phpseclib/Crypt/Base.php | 0 .../extlib => extlib}/phpseclib/Crypt/Blowfish.php | 0 .../extlib => extlib}/phpseclib/Crypt/DES.php | 0 .../extlib => extlib}/phpseclib/Crypt/Hash.php | 0 .../extlib => extlib}/phpseclib/Crypt/RC2.php | 0 .../extlib => extlib}/phpseclib/Crypt/RC4.php | 0 .../extlib => extlib}/phpseclib/Crypt/RSA.php | 0 .../phpseclib/Crypt/RSA/MSBLOB.php | 0 .../phpseclib/Crypt/RSA/OpenSSH.php | 0 .../extlib => extlib}/phpseclib/Crypt/RSA/PKCS.php | 0 .../phpseclib/Crypt/RSA/PKCS1.php | 0 .../phpseclib/Crypt/RSA/PKCS8.php | 0 .../phpseclib/Crypt/RSA/PuTTY.php | 0 .../extlib => extlib}/phpseclib/Crypt/RSA/Raw.php | 0 .../extlib => extlib}/phpseclib/Crypt/RSA/XML.php | 0 .../extlib => extlib}/phpseclib/Crypt/Random.php | 0 .../extlib => extlib}/phpseclib/Crypt/Rijndael.php | 0 .../phpseclib/Crypt/TripleDES.php | 0 .../extlib => extlib}/phpseclib/Crypt/Twofish.php | 0 .../Exception/BadConfigurationException.php | 0 .../phpseclib/Exception/FileNotFoundException.php | 0 .../Exception/NoSupportedAlgorithmsException.php | 0 .../Exception/UnsupportedAlgorithmException.php | 0 .../extlib => extlib}/phpseclib/File/ANSI.php | 0 .../extlib => extlib}/phpseclib/File/ASN1.php | 0 .../phpseclib/File/ASN1/Element.php | 0 .../extlib => extlib}/phpseclib/File/X509.php | 0 .../phpseclib/Math/BigInteger.php | 0 .../extlib => extlib}/phpseclib/Net/SCP.php | 0 .../extlib => extlib}/phpseclib/Net/SFTP.php | 0 .../phpseclib/Net/SFTP/Stream.php | 0 .../extlib => extlib}/phpseclib/Net/SSH1.php | 0 .../extlib => extlib}/phpseclib/Net/SSH2.php | 0 .../phpseclib/System/SSH/Agent.php | 0 .../phpseclib/System/SSH/Agent/Identity.php | 0 .../extlib => extlib}/phpseclib/bootstrap.php | 0 .../extlib => extlib}/phpseclib/openssl.cnf | 0 plugins/OStatus/OStatusPlugin.php | 14 -------------- 39 files changed, 14 deletions(-) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/AES.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Base.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Blowfish.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/DES.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Hash.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RC2.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RC4.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/MSBLOB.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/OpenSSH.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/PKCS.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/PKCS1.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/PKCS8.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/PuTTY.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/Raw.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/RSA/XML.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Random.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Rijndael.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/TripleDES.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Crypt/Twofish.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Exception/BadConfigurationException.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Exception/FileNotFoundException.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Exception/NoSupportedAlgorithmsException.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Exception/UnsupportedAlgorithmException.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/File/ANSI.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/File/ASN1.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/File/ASN1/Element.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/File/X509.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Math/BigInteger.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Net/SCP.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Net/SFTP.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Net/SFTP/Stream.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Net/SSH1.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/Net/SSH2.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/System/SSH/Agent.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/System/SSH/Agent/Identity.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/bootstrap.php (100%) rename {plugins/OStatus/extlib => extlib}/phpseclib/openssl.cnf (100%) diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/AES.php b/extlib/phpseclib/Crypt/AES.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/AES.php rename to extlib/phpseclib/Crypt/AES.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Base.php b/extlib/phpseclib/Crypt/Base.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Base.php rename to extlib/phpseclib/Crypt/Base.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Blowfish.php b/extlib/phpseclib/Crypt/Blowfish.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Blowfish.php rename to extlib/phpseclib/Crypt/Blowfish.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/DES.php b/extlib/phpseclib/Crypt/DES.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/DES.php rename to extlib/phpseclib/Crypt/DES.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Hash.php b/extlib/phpseclib/Crypt/Hash.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Hash.php rename to extlib/phpseclib/Crypt/Hash.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RC2.php b/extlib/phpseclib/Crypt/RC2.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RC2.php rename to extlib/phpseclib/Crypt/RC2.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RC4.php b/extlib/phpseclib/Crypt/RC4.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RC4.php rename to extlib/phpseclib/Crypt/RC4.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA.php b/extlib/phpseclib/Crypt/RSA.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA.php rename to extlib/phpseclib/Crypt/RSA.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/MSBLOB.php b/extlib/phpseclib/Crypt/RSA/MSBLOB.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/MSBLOB.php rename to extlib/phpseclib/Crypt/RSA/MSBLOB.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/OpenSSH.php b/extlib/phpseclib/Crypt/RSA/OpenSSH.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/OpenSSH.php rename to extlib/phpseclib/Crypt/RSA/OpenSSH.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS.php b/extlib/phpseclib/Crypt/RSA/PKCS.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS.php rename to extlib/phpseclib/Crypt/RSA/PKCS.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS1.php b/extlib/phpseclib/Crypt/RSA/PKCS1.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS1.php rename to extlib/phpseclib/Crypt/RSA/PKCS1.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS8.php b/extlib/phpseclib/Crypt/RSA/PKCS8.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/PKCS8.php rename to extlib/phpseclib/Crypt/RSA/PKCS8.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/PuTTY.php b/extlib/phpseclib/Crypt/RSA/PuTTY.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/PuTTY.php rename to extlib/phpseclib/Crypt/RSA/PuTTY.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/Raw.php b/extlib/phpseclib/Crypt/RSA/Raw.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/Raw.php rename to extlib/phpseclib/Crypt/RSA/Raw.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/RSA/XML.php b/extlib/phpseclib/Crypt/RSA/XML.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/RSA/XML.php rename to extlib/phpseclib/Crypt/RSA/XML.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Random.php b/extlib/phpseclib/Crypt/Random.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Random.php rename to extlib/phpseclib/Crypt/Random.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Rijndael.php b/extlib/phpseclib/Crypt/Rijndael.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Rijndael.php rename to extlib/phpseclib/Crypt/Rijndael.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/TripleDES.php b/extlib/phpseclib/Crypt/TripleDES.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/TripleDES.php rename to extlib/phpseclib/Crypt/TripleDES.php diff --git a/plugins/OStatus/extlib/phpseclib/Crypt/Twofish.php b/extlib/phpseclib/Crypt/Twofish.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Crypt/Twofish.php rename to extlib/phpseclib/Crypt/Twofish.php diff --git a/plugins/OStatus/extlib/phpseclib/Exception/BadConfigurationException.php b/extlib/phpseclib/Exception/BadConfigurationException.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Exception/BadConfigurationException.php rename to extlib/phpseclib/Exception/BadConfigurationException.php diff --git a/plugins/OStatus/extlib/phpseclib/Exception/FileNotFoundException.php b/extlib/phpseclib/Exception/FileNotFoundException.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Exception/FileNotFoundException.php rename to extlib/phpseclib/Exception/FileNotFoundException.php diff --git a/plugins/OStatus/extlib/phpseclib/Exception/NoSupportedAlgorithmsException.php b/extlib/phpseclib/Exception/NoSupportedAlgorithmsException.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Exception/NoSupportedAlgorithmsException.php rename to extlib/phpseclib/Exception/NoSupportedAlgorithmsException.php diff --git a/plugins/OStatus/extlib/phpseclib/Exception/UnsupportedAlgorithmException.php b/extlib/phpseclib/Exception/UnsupportedAlgorithmException.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Exception/UnsupportedAlgorithmException.php rename to extlib/phpseclib/Exception/UnsupportedAlgorithmException.php diff --git a/plugins/OStatus/extlib/phpseclib/File/ANSI.php b/extlib/phpseclib/File/ANSI.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/File/ANSI.php rename to extlib/phpseclib/File/ANSI.php diff --git a/plugins/OStatus/extlib/phpseclib/File/ASN1.php b/extlib/phpseclib/File/ASN1.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/File/ASN1.php rename to extlib/phpseclib/File/ASN1.php diff --git a/plugins/OStatus/extlib/phpseclib/File/ASN1/Element.php b/extlib/phpseclib/File/ASN1/Element.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/File/ASN1/Element.php rename to extlib/phpseclib/File/ASN1/Element.php diff --git a/plugins/OStatus/extlib/phpseclib/File/X509.php b/extlib/phpseclib/File/X509.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/File/X509.php rename to extlib/phpseclib/File/X509.php diff --git a/plugins/OStatus/extlib/phpseclib/Math/BigInteger.php b/extlib/phpseclib/Math/BigInteger.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Math/BigInteger.php rename to extlib/phpseclib/Math/BigInteger.php diff --git a/plugins/OStatus/extlib/phpseclib/Net/SCP.php b/extlib/phpseclib/Net/SCP.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Net/SCP.php rename to extlib/phpseclib/Net/SCP.php diff --git a/plugins/OStatus/extlib/phpseclib/Net/SFTP.php b/extlib/phpseclib/Net/SFTP.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Net/SFTP.php rename to extlib/phpseclib/Net/SFTP.php diff --git a/plugins/OStatus/extlib/phpseclib/Net/SFTP/Stream.php b/extlib/phpseclib/Net/SFTP/Stream.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Net/SFTP/Stream.php rename to extlib/phpseclib/Net/SFTP/Stream.php diff --git a/plugins/OStatus/extlib/phpseclib/Net/SSH1.php b/extlib/phpseclib/Net/SSH1.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Net/SSH1.php rename to extlib/phpseclib/Net/SSH1.php diff --git a/plugins/OStatus/extlib/phpseclib/Net/SSH2.php b/extlib/phpseclib/Net/SSH2.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/Net/SSH2.php rename to extlib/phpseclib/Net/SSH2.php diff --git a/plugins/OStatus/extlib/phpseclib/System/SSH/Agent.php b/extlib/phpseclib/System/SSH/Agent.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/System/SSH/Agent.php rename to extlib/phpseclib/System/SSH/Agent.php diff --git a/plugins/OStatus/extlib/phpseclib/System/SSH/Agent/Identity.php b/extlib/phpseclib/System/SSH/Agent/Identity.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/System/SSH/Agent/Identity.php rename to extlib/phpseclib/System/SSH/Agent/Identity.php diff --git a/plugins/OStatus/extlib/phpseclib/bootstrap.php b/extlib/phpseclib/bootstrap.php similarity index 100% rename from plugins/OStatus/extlib/phpseclib/bootstrap.php rename to extlib/phpseclib/bootstrap.php diff --git a/plugins/OStatus/extlib/phpseclib/openssl.cnf b/extlib/phpseclib/openssl.cnf similarity index 100% rename from plugins/OStatus/extlib/phpseclib/openssl.cnf rename to extlib/phpseclib/openssl.cnf diff --git a/plugins/OStatus/OStatusPlugin.php b/plugins/OStatus/OStatusPlugin.php index d877dd37c6..9751772fdc 100644 --- a/plugins/OStatus/OStatusPlugin.php +++ b/plugins/OStatus/OStatusPlugin.php @@ -28,8 +28,6 @@ if (!defined('GNUSOCIAL')) { exit(1); } -set_include_path(get_include_path() . PATH_SEPARATOR . dirname(__FILE__) . '/extlib/phpseclib'); - class OStatusPlugin extends Plugin { /** @@ -83,18 +81,6 @@ class OStatusPlugin extends Plugin return true; } - public function onAutoload($cls) - { - if (mb_substr($cls, 0, 10) === 'phpseclib\\') { - // These are saved under extlib/phpseclib with \ as /, - // phpseclib has already been added to our include_path - require_once str_replace('\\', '/', str_replace('phpseclib\\', '', $cls) . '.php'); - return false; - } - - return parent::onAutoload($cls); - } - /** * Set up queue handlers for outgoing hub pushes * @param QueueManager $qm -- 2.39.5