From 7832438b7abedf567ce6376f99949f419abcdff1 Mon Sep 17 00:00:00 2001 From: kkadosh Date: Tue, 29 May 2018 19:34:16 +0000 Subject: Support session encryption Implement session encryption.--- src/sp_cookie_encryption.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'src/sp_cookie_encryption.c') diff --git a/src/sp_cookie_encryption.c b/src/sp_cookie_encryption.c index 9030112..72223ad 100644 --- a/src/sp_cookie_encryption.c +++ b/src/sp_cookie_encryption.c @@ -21,7 +21,6 @@ static inline const sp_cookie *sp_lookup_cookie_config(const char *key) { int decrypt_cookie(zval *pDest, int num_args, va_list args, zend_hash_key *hash_key) { const sp_cookie *cookie = sp_lookup_cookie_config(ZSTR_VAL(hash_key->key)); - int ret = 0; /* If the cookie isn't in the conf, it shouldn't be encrypted. */ if (!cookie || !cookie->encrypt) { @@ -36,11 +35,6 @@ int decrypt_cookie(zval *pDest, int num_args, va_list args, return decrypt_zval(pDest, cookie->simulation, hash_key); } -/* -** This function will return the `data` of length `data_len` encrypted in the -** form `base64(nonce | encrypted_data)` (with `|` being the concatenation -** operation). -*/ static zend_string *encrypt_data(char *data, unsigned long long data_len) { zend_string *z = encrypt_zval(data, data_len); sp_log_debug("cookie_encryption", "Cookie value:%s:", z->val); -- cgit v1.3