You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's a possibility to specify "visibility => permission" mapping for the local adapter. While the syntax is fine for specifying 0775 instead of 0755, a catastrophe occurs if you naively set the first octet. 1777 actually sets the permissions to 3361. To set the 1777 permissions one actually has to specify either the octal 01777 or the decimal 1023.
Summary
I propose to allow optional string syntax for permissions. The strings should be translated to permissions as naively expected - '1777' should actually set 1777 permissions.
This syntax should also be used in the codebase so the example in the code would be the one that behaves as would be expected.
How is this breaking?
'sticky' => 01777 works and would keep working. 'sticky' => 1023 works and would keep working. 'sticky' => 1777 is crazy, but would keep working as it does.
The case that breaks is where one would already be using strings. Undocumented but it works. 'sticky' => '1777' currently sets 3361, but according to my proposal this stringed directive should set permissions to 1777.
The text was updated successfully, but these errors were encountered:
I get what you're saying, but I don't want to bump a major for this. We could ship with an added utility function that safely translates the string permissions to their octal counterparts, this way there's no BC break but people can use the tooling. It would even accept either type and convert based on the need.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Uh oh!
There was an error while loading. Please reload this page.
Feature Request
Scenario
There's a possibility to specify "visibility => permission" mapping for the local adapter. While the syntax is fine for specifying
0775
instead of0755
, a catastrophe occurs if you naively set the first octet.1777
actually sets the permissions to3361
. To set the1777
permissions one actually has to specify either the octal01777
or the decimal1023
.Summary
I propose to allow optional string syntax for permissions. The strings should be translated to permissions as naively expected -
'1777'
should actually set1777
permissions.This syntax should also be used in the codebase so the example in the code would be the one that behaves as would be expected.
How is this breaking?
'sticky' => 01777
works and would keep working.'sticky' => 1023
works and would keep working.'sticky' => 1777
is crazy, but would keep working as it does.The case that breaks is where one would already be using strings. Undocumented but it works.
'sticky' => '1777'
currently sets3361
, but according to my proposal this stringed directive should set permissions to1777
.The text was updated successfully, but these errors were encountered: