diff options
| -rw-r--r-- | .travis.yml | 1 | ||||
| -rw-r--r-- | ex_imp.c | 2 | ||||
| -rw-r--r-- | log.c | 4 | ||||
| -rw-r--r-- | php_suhosin7.h | 4 | ||||
| -rw-r--r-- | session.c | 2 |
5 files changed, 9 insertions, 4 deletions
diff --git a/.travis.yml b/.travis.yml index bfad839..213b493 100644 --- a/.travis.yml +++ b/.travis.yml | |||
| @@ -6,6 +6,7 @@ group: edge | |||
| 6 | 6 | ||
| 7 | php: | 7 | php: |
| 8 | - 7.0 | 8 | - 7.0 |
| 9 | - 7.1 | ||
| 9 | 10 | ||
| 10 | env: | 11 | env: |
| 11 | - CC=gcc-4.8 CFLAGS="" | 12 | - CC=gcc-4.8 CFLAGS="" |
| @@ -201,7 +201,7 @@ PHP_FUNCTION(suhosin_extract) | |||
| 201 | if (var_exists && ZSTR_LEN(var_name) == sizeof("GLOBALS")-1 && !strcmp(ZSTR_VAL(var_name), "GLOBALS")) { | 201 | if (var_exists && ZSTR_LEN(var_name) == sizeof("GLOBALS")-1 && !strcmp(ZSTR_VAL(var_name), "GLOBALS")) { |
| 202 | break; | 202 | break; |
| 203 | } | 203 | } |
| 204 | if (var_exists && ZSTR_LEN(var_name) == sizeof("this")-1 && !strcmp(ZSTR_VAL(var_name), "this") && EG(scope) && ZSTR_LEN(EG(scope)->name) != 0) { | 204 | if (var_exists && ZSTR_LEN(var_name) == sizeof("this")-1 && !strcmp(ZSTR_VAL(var_name), "this") /* && EG(scope) && ZSTR_LEN(EG(scope)->name) != 0 */) { |
| 205 | break; | 205 | break; |
| 206 | } | 206 | } |
| 207 | ZVAL_STR_COPY(&final_name, var_name); | 207 | ZVAL_STR_COPY(&final_name, var_name); |
| @@ -284,7 +284,11 @@ log_sapi: | |||
| 284 | /* SAPI Logging activated? */ | 284 | /* SAPI Logging activated? */ |
| 285 | // SDEBUG("(suhosin_log) log_syslog: %ld - log_sapi: %ld - log_script: %ld - log_phpscript: %ld", SUHOSIN7_G(log_syslog), SUHOSIN7_G(log_sapi), SUHOSIN7_G(log_script), SUHOSIN7_G(log_phpscript)); | 285 | // SDEBUG("(suhosin_log) log_syslog: %ld - log_sapi: %ld - log_script: %ld - log_phpscript: %ld", SUHOSIN7_G(log_syslog), SUHOSIN7_G(log_sapi), SUHOSIN7_G(log_script), SUHOSIN7_G(log_phpscript)); |
| 286 | if (sapi_module.log_message && ((SUHOSIN7_G(log_sapi)|S_INTERNAL) & loglevel)!=0) { | 286 | if (sapi_module.log_message && ((SUHOSIN7_G(log_sapi)|S_INTERNAL) & loglevel)!=0) { |
| 287 | #if PHP_VERSION_ID < 70100 | ||
| 287 | sapi_module.log_message(buf); | 288 | sapi_module.log_message(buf); |
| 289 | #else /* PHP >= 7.1 */ | ||
| 290 | sapi_module.log_message(buf, -1); | ||
| 291 | #endif | ||
| 288 | } | 292 | } |
| 289 | if ((SUHOSIN7_G(log_stdout) & loglevel)!=0) { | 293 | if ((SUHOSIN7_G(log_stdout) & loglevel)!=0) { |
| 290 | fprintf(stdout, "%s\n", buf); | 294 | fprintf(stdout, "%s\n", buf); |
diff --git a/php_suhosin7.h b/php_suhosin7.h index 1398a36..fb9cf90 100644 --- a/php_suhosin7.h +++ b/php_suhosin7.h | |||
| @@ -23,8 +23,8 @@ extern zend_module_entry suhosin7_module_entry; | |||
| 23 | 23 | ||
| 24 | #define SUHOSIN7_EXT_VERSION "0.10.0dev" | 24 | #define SUHOSIN7_EXT_VERSION "0.10.0dev" |
| 25 | 25 | ||
| 26 | #if PHP_VERSION_ID < 70000 | PHP_VERSION_ID >= 70100 | 26 | #if PHP_VERSION_ID < 70000 | PHP_VERSION_ID >= 70200 |
| 27 | #error Suhosin7 works with PHP 7.0 only! Looking for Suhosin for PHP 5.x? Take a look at https://www.suhosin.org/ | 27 | #error Suhosin7 works with PHP 7.0 and 7.1 only! Looking for Suhosin for PHP 5.x? Take a look at https://www.suhosin.org/ |
| 28 | #endif | 28 | #endif |
| 29 | 29 | ||
| 30 | #ifdef PHP_WIN32 | 30 | #ifdef PHP_WIN32 |
| @@ -265,7 +265,7 @@ void suhosin_hook_session() | |||
| 265 | 265 | ||
| 266 | suhosin_hook_session_module(); | 266 | suhosin_hook_session_module(); |
| 267 | 267 | ||
| 268 | #if HAVE_DEV_URANDOM | 268 | #if HAVE_DEV_URANDOM && PHP_VERSION_ID < 70100 |
| 269 | /* increase session identifier entropy */ | 269 | /* increase session identifier entropy */ |
| 270 | if (SESSION_G(entropy_length) == 0 || SESSION_G(entropy_file) == NULL) { | 270 | if (SESSION_G(entropy_length) == 0 || SESSION_G(entropy_file) == NULL) { |
| 271 | SESSION_G(entropy_length) = 16; | 271 | SESSION_G(entropy_length) = 16; |
