Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 146059

Summary: app-admin/webapp-config 1.50.15 fails to interpret symbolic permissions which set no permission for a category
Product: Gentoo Linux Reporter: madalexonline
Component: Current packagesAssignee: Gentoo Web Application Packages Maintainers <web-apps>
Status: RESOLVED FIXED    
Severity: minor CC: Werner.Peter
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description madalexonline 2006-09-02 17:42:31 UTC
webapp-config 1.50.15 fails to correctly interpret any symbolic permission string which sets no permissions for one of the categories. For example it claims (after fixing the typo in the error handling, see bug #133530) that "u=rw,g=r,o=" is invalid when it should interpret it as octal mode 0640.

The problem is the regular expression which each part is matched against in WebappConfig/permissions.py which requires between one and three of r, w or x to appear when it should be requiring between zero and three.
Line 54 of that file should change from:
valid = re.compile('^([ugoa]{1,4})([+-=])([rwx]{1,3})$')
to
valid = re.compile('^([ugoa]{1,4})([+-=])([rwx]{0,3})$')
Comment 1 Péter Werner 2006-09-02 22:30:03 UTC
as a workaround you can use o-rwx
Comment 2 Gunnar Wrobel (RETIRED) gentoo-dev 2006-12-31 02:47:15 UTC
Fixed in webapp-config-1.50.16. This version is available from my overlay (http://overlays.gentoo.org/dev/wrobel) and will be moved to portage next week.

Thanks for the report and the fix!
Comment 3 Gunnar Wrobel (RETIRED) gentoo-dev 2006-12-31 02:48:15 UTC
Marked fixed.