Module Import alias Import alias Import alias Import alias ImportFrom alias alias alias ImportFrom alias Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad While CompareNotEq NameLoad Str body If Call AttributeLoad Call AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad attr attr Str body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If CompareEq Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str body Break Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad ImportFrom alias ImportFrom alias alias alias alias ClassDef bases NameLoad body FunctionDef arguments args NameParam defaults body Assign NameStore ListLoad TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str Assign NameStore ListLoad TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str TupleLoad Str Str For TupleStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad NameLoad For TupleStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore ListLoad TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str Assign NameStore ListLoad TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str TupleLoad Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str keyword Str For TupleStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad For TupleStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad NameLoad NameLoad BinOpMod Str TupleLoad NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list decorator_list ClassDef bases NameLoad body Assign NameStore NameLoad FunctionDef arguments args NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Str Assign NameStore Str FunctionDef arguments args defaults body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list Assign AttributeStore NameLoad attr ListLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign NameStore Call NameLoad keyword Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad keyword Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad Assign AttributeStore NameLoad attr Call NameLoad Call AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body FunctionDef arguments args NameParam NameParam defaults body Return CompareEq AttributeLoad NameLoad attr NameLoad decorator_list Return NameLoad decorator_list Assign AttributeStore NameLoad attr NameLoad Expr Call NameLoad Assign AttributeStore NameLoad attr Call NameLoad Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Assign AttributeStore NameLoad attr Call NameLoad Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Assign AttributeStore NameLoad attr Call NameLoad Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad SubscriptLoad NameLoad Index Str Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Assign AttributeStore NameLoad attr Lambda arguments args NameParam NameParam defaults NameLoad Assign AttributeStore NameLoad attr Lambda arguments args NameParam NameParam defaults CompareEq NameLoad NameLoad Assign NameStore Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr BoolOpOr CompareIn Call NameLoad Str NameLoad AttributeLoad NameLoad attr CompareIn Call NameLoad NameLoad Str AttributeLoad NameLoad attr Expr Call NameLoad Assign AttributeStore NameLoad attr Lambda arguments args NameParam NameParam defaults NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str NameLoad decorator_list Call NameLoad Str Call NameLoad Str decorator_list ClassDef bases NameLoad body Assign NameStore NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad Assign NameStore Call NameLoad Assign AttributeStore NameLoad attr Lambda arguments args NameParam NameParam defaults CompareEq NameLoad NameLoad FunctionDef arguments args defaults body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr decorator_list Assign AttributeStore NameLoad attr ListLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str Expr Call NameLoad Assign AttributeStore NameLoad attr ListLoad Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str Call AttributeLoad AttributeLoad NameLoad attr attr Str keyword Str Assign AttributeStore AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad Str Str AttributeLoad NameLoad attr Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Call NameLoad Str Str AttributeLoad NameLoad attr Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call NameLoad Assign AttributeStore NameLoad attr Str Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list Call NameLoad Str decorator_list ClassDef bases NameLoad NameLoad body Assign NameStore NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr TupleLoad Str Str Str AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str Str decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad Assign NameStore Call NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Str AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad Str decorator_list decorator_list
N/A N/A os N/A sys N/A lxml.etree N/A Bcfg2.Server.Plugin mock Mock MagicMock patch Bcfg2.Server.Plugins.ACL * N/A path N/A N/A N/A os path dirname __file__ N/A N/A path / N/A N/A N/A N/A N/A N/A N/A N/A N/A os path basename path lower startswith test N/A N/A N/A N/A N/A sys path append path N/A N/A N/A N/A N/A os path basename path testsuite N/A N/A N/A path N/A N/A N/A os path dirname path common * TestPlugin TestXMLFileBacked TestStructFile TestPlugin TestClientACLs TestFunctions N/A Bcfg2TestCase N/A test_rmi_names_equal N/A N/A self N/A N/A N/A good_cases N/A N/A * foo N/A foo foo N/A foo.* foo.bar N/A *.* foo.bar N/A foo.bar foo.bar N/A *.bar foo.bar N/A foo.*.bar foo.baz.bar N/A bad_cases N/A N/A foo bar N/A * foo.bar N/A *.* foo N/A *.* foo.bar.baz N/A foo.* bar.foo N/A *.bar bar.foo N/A foo.* foobar N/A N/A first second good_cases N/A N/A N/A N/A self assertTrue N/A rmi_names_equal first second N/A rmi_names_equal(%s, %s) unexpectedly False N/A first second N/A N/A N/A self assertTrue N/A rmi_names_equal second first N/A rmi_names_equal(%s, %s) unexpectedly False N/A second first N/A N/A first second bad_cases N/A N/A N/A N/A self assertFalse N/A rmi_names_equal first second N/A rmi_names_equal(%s, %s) unexpectedly True N/A first second N/A N/A N/A self assertFalse N/A rmi_names_equal second first N/A rmi_names_equal(%s, %s) unexpectedly True N/A second first N/A test_ip_matches N/A N/A self N/A N/A N/A good_cases N/A N/A 192.168.1.1 N/A N/A N/A lxml etree Element test address 192.168.1.1 N/A 192.168.1.17 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 24 N/A 192.168.1.17 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 255.255.255.0 N/A 192.168.1.31 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 255.255.255.224 N/A 192.168.1.31 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 27 N/A 10.55.67.191 N/A N/A N/A lxml etree Element test address 10.55.0.0 netmask 16 N/A bad_cases N/A N/A 192.168.1.1 N/A N/A N/A lxml etree Element test address 192.168.1.2 N/A 192.168.2.17 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 24 N/A 192.168.2.17 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 255.255.255.0 N/A 192.168.1.35 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 255.255.255.224 N/A 192.168.1.35 N/A N/A N/A lxml etree Element test address 192.168.1.0 netmask 27 N/A 10.56.67.191 N/A N/A N/A lxml etree Element test address 10.55.0.0 netmask 16 N/A N/A ip entry good_cases N/A N/A N/A N/A self assertTrue N/A ip_matches ip entry N/A ip_matches(%s, %s) unexpectedly False N/A ip N/A N/A N/A lxml etree tostring entry N/A N/A ip entry bad_cases N/A N/A N/A N/A self assertFalse N/A ip_matches ip entry N/A ip_matches(%s, %s) unexpectedly True N/A ip N/A N/A N/A lxml etree tostring entry N/A N/A TestIPACLFile N/A TestXMLFileBacked N/A N/A test_obj IPACLFile test_check_acl N/A N/A self mock_rmi_names_equal mock_ip_matches N/A N/A N/A af N/A N/A self get_obj N/A ip 10.0.0.8 N/A rmi ACL.test reset N/A N/A N/A N/A N/A N/A N/A mock_rmi_names_equal reset_mock N/A N/A N/A mock_ip_matches reset_mock N/A N/A N/A af entries N/A N/A N/A N/A self assertIsNone N/A N/A af check_acl ip rmi N/A entries N/A dict Allow N/A N/A N/A lxml etree Element Allow method rmi Deny N/A N/A N/A lxml etree Element Deny method rmi Defer N/A N/A N/A lxml etree Element Defer method rmi N/A N/A af entries N/A list N/A N/A entries values get_ip_matches N/A N/A tag N/A N/A ip_matches N/A N/A ip entry N/A N/A N/A N/A N/A entry tag tag N/A N/A ip_matches N/A N/A N/A mock_rmi_names_equal return_value True N/A N/A reset N/A N/A mock_ip_matches side_effect N/A get_ip_matches Allow N/A N/A N/A self assertTrue N/A N/A af check_acl ip rmi N/A N/A N/A mock_ip_matches assert_called_with ip N/A entries N/A Allow N/A N/A N/A mock_rmi_names_equal assert_called_with rmi rmi N/A N/A reset N/A N/A mock_ip_matches side_effect N/A get_ip_matches Deny N/A N/A N/A self assertFalse N/A N/A af check_acl ip rmi N/A N/A N/A mock_ip_matches assert_called_with ip N/A entries N/A Deny N/A N/A N/A mock_rmi_names_equal assert_called_with rmi rmi N/A N/A reset N/A N/A mock_ip_matches side_effect N/A get_ip_matches Defer N/A N/A N/A self assertIsNone N/A N/A af check_acl ip rmi N/A N/A N/A mock_ip_matches assert_called_with ip N/A entries N/A Defer N/A N/A N/A mock_rmi_names_equal assert_called_with rmi rmi N/A N/A reset N/A N/A mock_ip_matches side_effect N/A N/A N/A i e N/A True N/A N/A mock_rmi_names_equal side_effect N/A N/A N/A a b N/A N/A a b N/A rmi ACL.test2 N/A matching N/A N/A N/A lxml etree Element Allow method rmi N/A N/A N/A N/A af entries append matching N/A N/A N/A self assertTrue N/A N/A af check_acl ip rmi N/A N/A N/A mock_ip_matches assert_called_with ip matching N/A N/A N/A self assertTrue N/A N/A N/A call ACL.test rmi N/A mock_rmi_names_equal call_args_list N/A N/A call rmi ACL.test N/A mock_rmi_names_equal call_args_list N/A N/A reset N/A N/A mock_ip_matches side_effect N/A N/A N/A i e N/A False N/A N/A N/A self assertIsNone N/A N/A af check_acl ip rmi N/A N/A reset N/A N/A N/A self assertTrue N/A N/A af check_acl 127.0.0.1 rmi N/A N/A patch Bcfg2.Server.Plugins.ACL.ip_matches N/A patch Bcfg2.Server.Plugins.ACL.rmi_names_equal N/A TestMetadataACLFile N/A TestStructFile N/A N/A test_obj MetadataACLFile test_check_acl N/A N/A self mock_rmi_names_equal N/A N/A N/A af N/A N/A self get_obj N/A N/A af Match N/A Mock N/A metadata N/A Mock N/A N/A mock_rmi_names_equal side_effect N/A N/A N/A a b N/A N/A a b reset N/A N/A N/A N/A N/A N/A N/A N/A af Match reset_mock N/A N/A N/A mock_rmi_names_equal reset_mock N/A N/A N/A af entries N/A N/A N/A N/A self assertTrue N/A N/A af check_acl metadata ACL.test N/A N/A reset N/A N/A af entries N/A N/A N/A N/A lxml etree Element Allow method ACL.test N/A N/A N/A lxml etree Element Deny method ACL.test2 N/A N/A N/A af Match return_value N/A af entries N/A N/A N/A self assertTrue N/A N/A af check_acl metadata ACL.test N/A N/A N/A N/A af Match assert_called_with metadata N/A N/A N/A self assertIn N/A call ACL.test ACL.test N/A mock_rmi_names_equal call_args_list N/A N/A reset N/A N/A N/A self assertFalse N/A N/A af check_acl metadata ACL.test2 N/A N/A N/A N/A af Match assert_called_with metadata N/A N/A N/A self assertIn N/A call ACL.test2 ACL.test2 N/A mock_rmi_names_equal call_args_list N/A N/A reset N/A N/A N/A self assertFalse N/A N/A af check_acl metadata ACL.test3 N/A N/A N/A N/A af Match assert_called_with metadata N/A N/A reset N/A N/A metadata hostname localhost N/A N/A N/A self assertTrue N/A N/A af check_acl metadata ACL.test3 N/A N/A N/A N/A af Match assert_called_with metadata N/A N/A patch Bcfg2.Server.Plugins.ACL.rmi_names_equal N/A TestACL N/A TestPlugin TestClientACLs N/A N/A test_obj ACL test_check_acl_ip N/A N/A self N/A N/A N/A acl N/A N/A self get_obj N/A N/A acl ip_acls N/A Mock N/A N/A N/A self assertEqual N/A N/A acl check_acl_ip N/A 192.168.1.10 12345 ACL.test N/A N/A N/A acl ip_acls check_acl return_value N/A N/A N/A N/A N/A acl ip_acls check_acl assert_called_with 192.168.1.10 ACL.test N/A test_check_acl_metadata N/A N/A self N/A N/A N/A acl N/A N/A self get_obj N/A N/A acl metadata_acls N/A Mock N/A metadata N/A Mock N/A N/A N/A self assertEqual N/A N/A acl check_acl_metadata metadata ACL.test N/A N/A N/A acl metadata_acls check_acl return_value N/A N/A N/A N/A N/A acl metadata_acls check_acl assert_called_with metadata ACL.test N/A N/A