realpath_turbo
realpath_turbo copied to clipboard
realpath_turbo.disable_dangerous_functions doesn't work
Try,
diff --git a/tests/012.phpt b/tests/012.phpt
index c0c7ec3..c2fb8f9 100644
--- a/tests/012.phpt
+++ b/tests/012.phpt
@@ -10,6 +10,9 @@ realpath_turbo.disable_dangerous_functions=1
<?php
var_dump(ini_get("realpath_turbo.disable_dangerous_functions"));
var_dump(ini_get("disable_functions"));
+$l = __DIR__ . '/testlink';
+var_dump(symlink(PHP_BINARY, $l));
+var_dump(@unlink($l));
--EXPECTF--
string(1) "1"
string(17) "link,symlink,date"
symlink
is called without any blocker.
Both new var_dump
output "bool(true)", while false (failure) + a disabled warning is expected.
diff --git a/tests/012.phpt b/tests/012.phpt
index c0c7ec3..c2fb8f9 100644
--- a/tests/012.phpt
+++ b/tests/012.phpt
@@ -10,6 +10,9 @@ realpath_turbo.disable_dangerous_functions=1
<?php
var_dump(ini_get("realpath_turbo.disable_dangerous_functions"));
var_dump(ini_get("disable_functions"));
+$l = __DIR__ . '/testlink';
+var_dump(symlink(PHP_BINARY, $l));
+var_dump(@unlink($l));
--EXPECTF--
string(1) "1"
string(17) "link,symlink,date"
@Whissi Has this been incorporated into core or reviewed yet? Seemed like it was stuck in pull request stage but also seems relevant if you want both speed + security.
I am sorry but I had no time for this yet. Hopefully next week.
Hi @Whissi. First, thanks for your work in this project.
We are having problems with PHP slow in NFS due to lstats. Is there any chance of this PR being reviewed and applied?
Yeah, I am using a version with the patches remi provided for some months now without any problems. I'll do my best to merge everything within next two weeks.
Great!!