diff --git a/modules/generators/structured_content/account/secgen_local/local.rb b/modules/generators/structured_content/account/secgen_local/local.rb index 37cf4e17c..230716892 100644 --- a/modules/generators/structured_content/account/secgen_local/local.rb +++ b/modules/generators/structured_content/account/secgen_local/local.rb @@ -14,7 +14,7 @@ class AccountGenerator < StringEncoder self.module_name = 'Account Generator / Builder' self.username = '' self.password = '' - self.groups = '' + self.groups = [] self.super_user = '' self.strings_to_leak = [] self.data_to_leak = [] @@ -25,7 +25,7 @@ class AccountGenerator < StringEncoder account_hash = {} account_hash['username'] = self.username account_hash['password'] = self.password - account_hash['groups'] = self.password + account_hash['groups'] = self.groups account_hash['super_user'] = self.super_user account_hash['strings_to_leak'] = self.strings_to_leak account_hash['leaked_filenames'] = self.leaked_filenames diff --git a/modules/utilities/unix/system/groups/manifests/init.pp b/modules/utilities/unix/system/groups/manifests/init.pp index e7e783287..cca75aaf1 100644 --- a/modules/utilities/unix/system/groups/manifests/init.pp +++ b/modules/utilities/unix/system/groups/manifests/init.pp @@ -1,7 +1,7 @@ class groups::init { $secgen_parameters = secgen_functions::get_parameters($::base64_inputs_file) - $groups = $secgen_parameters['accounts'] + $groups = $secgen_parameters['groups'] if $groups { $groups.each |$group| { diff --git a/modules/utilities/unix/system/parameterised_accounts/manifests/init.pp b/modules/utilities/unix/system/parameterised_accounts/manifests/init.pp index e653f5ab1..ddb69a207 100644 --- a/modules/utilities/unix/system/parameterised_accounts/manifests/init.pp +++ b/modules/utilities/unix/system/parameterised_accounts/manifests/init.pp @@ -9,7 +9,7 @@ class parameterised_accounts::init { parameterised_accounts::account { "parameterised_user_$username": username => $username, password => $account['password'], - groups => $account['groups'], + groups => $account['groups'], super_user => str2bool($account['super_user']), strings_to_leak => $account['strings_to_leak'], leaked_filenames => $account['leaked_filenames'], diff --git a/scenarios/examples/services_utilities_examples/users_and_groups.xml b/scenarios/examples/services_utilities_examples/users_and_groups.xml index f8953f897..a1bd25ffc 100644 --- a/scenarios/examples/services_utilities_examples/users_and_groups.xml +++ b/scenarios/examples/services_utilities_examples/users_and_groups.xml @@ -54,8 +54,8 @@ staff - team2 team1 + team2