aboutsummaryrefslogtreecommitdiffstats
path: root/include/crypto.php
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2016-11-30 16:36:33 -0800
committerzotlabs <mike@macgirvin.com>2016-11-30 16:36:33 -0800
commitc845eed114ec3cea90acd35c419110d9ab76051f (patch)
treed487da2ba21b282274648904395b111b633693c1 /include/crypto.php
parent5b09829959948b85fa6b156abaa091c40d88a9e1 (diff)
downloadvolse-hubzilla-c845eed114ec3cea90acd35c419110d9ab76051f.tar.gz
volse-hubzilla-c845eed114ec3cea90acd35c419110d9ab76051f.tar.bz2
volse-hubzilla-c845eed114ec3cea90acd35c419110d9ab76051f.zip
advanced crypto restricted by server role
Diffstat (limited to 'include/crypto.php')
-rw-r--r--include/crypto.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/crypto.php b/include/crypto.php
index e9fa320d3..4b78bb63d 100644
--- a/include/crypto.php
+++ b/include/crypto.php
@@ -138,6 +138,9 @@ function other_encapsulate($data,$pubkey,$alg) {
function crypto_methods() {
+ if(\Zotlabs\Lib\System::get_server_role() !== 'pro')
+ return [ 'aes256cbc' ];
+
// 'std' is the new project standard which is aes256cbc but transmits/receives 256-byte key and iv.
// aes256cbc is provided for compatibility with earlier zot implementations which assume 32-byte key and 16-byte iv.
// other_encapsulate() now produces these longer keys/ivs by default so that it is difficult to guess a