Step 3: Creating an ACL with a Firm Code rule set (without Container assignment)

Starting from the empty ACL created in step 1, this step adds a rule to a Firm Code, e.g. 6000010 with Firm Item Text "Test FC"). The state after step 1 can be established by importing the created (empty) ACL.

1.Importing the empty ACL.

> cmu32 --import-acl -f01_ACL_Empty.json

 

SUCCESS: License Access Permissions (Access Control List) were imported from: 01_ACL_Empty.json

The result can be checked on the CodeMeter WebAdmin interface. It may be necessary to reload the page in the browser.

2.Adding a new Firm Code in the specific rule set, e.g. 6000010 with Firm Item Text "Test FC"), and clicking the "Apply" button.

step3_01

Exporting the ACL using cmu:

> cmu32 --export-acl -f03_ACL_FC_Only.json

 

SUCCESS: License Access Permissions (Access Control List) were exported to: 03_ACL_FC_Only.json

List output result using cmu:

> type 03_ACL_Container.json

{

 "AccessControlList": {

 "ContainerRulesets": [

 {

 "FcRulesets": [

 {

 "PcRulesets": [

],

 "Rules": [

 {

 "Action": "Allow",

 "Allocated": 0,

 "Limit": 0,

 "Reserved": 0,

 "RuleId": 0,

 "Type": "Default",

 "Value": "",

 "__type": "Rule"

}

],

 "Text": "Test FC",

 "Value": 6000010,

 "__type": "FcRuleset"

}

],

 "Rules": [

 {

 "Action": "Allow",

 "Allocated": 0,

 "Limit": 0,

 "Reserved": 0,

 "RuleId": 0,

 "Type": "Default",

 "Value": "",

 "__type": "Rule"

}

],

 "Text": "All Containers",

 "Value": "All",

 "__type": "ContainerRuleset"

}

],

 "Rules": [

 {

 "Action": "Allow",

 "Allocated": 0,

 "Limit": 0,

 "Reserved": 0,

 "RuleId": 0,

 "Type": "Default",

 "Value": "",

 "__type": "Rule"

}

],

 "__type": "AccessControlList"

},

 "Enabled": true,

 "GroupsMaximumNumber": 10000,

 "UsersMaximumNumber": 10000

}

No rules have been defined yet, only a set of rules at "Firm Code" level.

Default rule

In this case, however, an ACL object is assigned a (Default) rule. This always has the following content:

{

 "Action": "Allow",

 "Allocated": 0,

 "Limit": 0,

 "Reserved": 0,

 "RuleId": 0,

 "Type": "Default",

 "Value": "",

 "__type": "Rule"

}

In the following, this rule is replaced by the entry. After an insertion of line numbers and some reformatting, the result looks as follows:

1   {

2     "AccessControlList": {

3       "ContainerRulesets": [

4       {

5         "FcRulesets": [

6         {

7           "PcRulesets": [],

8           "Rules": [<Default-Rule>],

9           "Text": "Test FC",

10           "Value": 6000010,

11           "__type": "FcRuleset"

12         }],

13         "Rules": [<Default-Rule>],

14         "Text": "All Containers",

15         "Value": "All",

16         "__type": "ContainerRuleset"

17       }],

18       "Rules": [<Default-Rule>],

19       "__type": "AccessControlList"

20     },

21     "Enabled": true,

22     "GroupsMaximumNumber": 10000,

23     "UsersMaximumNumber": 10000

24   }

The object AccessControlList covers the lines 2-20 and holds a list with a ContainerRuleset (i.e. AllContainer-Ruleset):

3       "ContainerRulesets": [

4       {

5         "FcRulesets": [

6         {

7           "PcRulesets": [],

8           "Rules": [<Default-Rule>],

9           "Text": "Test FC",

10           "Value": 6000010,

11           "__type": "FcRuleset"

12         }],

13         "Rules": [<Default-Rule>],

14         "Text": "All Containers",

15         "Value": "All",

16         "__type": "ContainerRuleset"

17       }]

The AllContainer ruleset is selected if no matching rule set is found for a container. The rule set defined for Firm Code 6000010 of the example can be found in lines 5-12:

5         "FcRulesets": [

6         {

7           "PcRulesets": [],

8           "Rules": [<Default-Rule>],

9           "Text": "Test FC",

10           "Value": 6000010,

11           "__type": "FcRuleset"

12         }],

No rule has been defined at Product Code level for this Firm Code. For this reason, the PcRulesets list (line 7) is empty. Lines 9-10 contain the Firm Code and the Firm Item Text. The type of the object is in line 11.