Univention Bugzilla – Attachment 5947 Details for
Bug 25196
Absturz des UMC-Servers bei speziellem Operationset
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
updated 2 lines
patch_v03_25196.diff (text/plain), 2.08 KB, created by
Alexander Kramer
on 2014-06-10 16:00:20 CEST
(
hide
)
Description:
updated 2 lines
Filename:
MIME Type:
Creator:
Alexander Kramer
Created:
2014-06-10 16:00:20 CEST
Size:
2.08 KB
patch
obsolete
>Index: management/univention-management-console/src/univention/management/console/acl.py >=================================================================== >--- management/univention-management-console/src/univention/management/console/acl.py (Revision 50941) >+++ management/univention-management-console/src/univention/management/console/acl.py (Arbeitskopie) >@@ -152,23 +152,18 @@ > > return hosts > >- def __parse_command( self, command ): >- if command.find( ':' ) != -1: >- data = command.split( ':' )[ 1 ] >- command = command.split( ':' )[ 0 ] >- else: >- data = [ ] >- >+ def __parse_command(self, command): >+ data, sep, command = command.partition(':') > options = {} > if data: >- elements = data.split( ',' ) >+ elements = data.split(',') > for elem in elements: >- if elem.find( '=' ) != -1: >- key, value = elem.split( '=' ) >- options[ key.strip() ] = value.strip() >- elif elem[ 0 ] == '!': # key without value allowed if starting with ! -> key may not exist >- options[ elem.strip() ] = None >- return ( command, options ) >+ if '=' in elem: >+ key, value = elem.split('=', 1) >+ options[key.strip()] = value.strip() >+ elif elem.startswith('!'): # key without value allowed if starting with ! -> key may not exist >+ options[elem.strip()] = None >+ return command, options > > def _append( self, fromUser, ldap_object ): > for host in self._expand_hostlist( ldap_object.get( 'umcOperationSetHost', [ '*' ] ) ): >@@ -200,7 +195,7 @@ > match = ACLs.MATCH_FULL > for key, value in opt_pattern.items(): > # a key starting with ! means it may not be available >- if key[ 0 ] == '!' and key in opts: >+ if key.startswith('!') and key in opts: > return ACLs.MATCH_NONE > # else if key not not in opts no rule available -> OK > if not key in opts: >@@ -244,7 +239,7 @@ > if flavor1 == flavor2 or flavor1 is None or flavor1 == '*': > return ACLs.MATCH_FULL > >- if flavor1[ -1 ] == '*' and flavor2.startswith( flavor1[ : -1 ] ): >+ if flavor1.endswith('*') and flavor2 and flavor2.startswith(flavor1[:-1]): > return ACLs.MATCH_PART > > return ACLs.MATCH_NONE
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 25196
:
5936
|
5946
| 5947 |
5960