mirror of
https://github.com/inspec/inspec
synced 2024-12-21 18:43:13 +00:00
69434fec48
* When running integration tests with Rakefile use terraform environment based on environment variable INSPEC_TERRAFORM_ENV ** If INSPEC_TERRAFORM_ENV is not provided, a random string will be used * Use terraform environment as a namespace for AWS artifacts * Use attribute file for inspec to be aware of the terraform environment used Signed-off-by: Miles Tjandrawidjaja <miles@tjandrawidjaja.com>
18 lines
No EOL
614 B
Ruby
18 lines
No EOL
614 B
Ruby
mfa_not_enabled_user = attribute(
|
|
'mfa_not_enabled_user',
|
|
default: 'default.mfa_not_enabled_user',
|
|
description: 'Name of IAM user mfa_not_enabled_user')
|
|
|
|
console_password_enabled_user = attribute(
|
|
'console_password_enabled_user',
|
|
default: 'default.console_password_enabled_user',
|
|
description: 'Name of IAM user console_password_enabled_user')
|
|
|
|
describe aws_iam_user(mfa_not_enabled_user) do
|
|
its('has_mfa_enabled?') { should be false }
|
|
its('has_console_password?') { should be false }
|
|
end
|
|
|
|
describe aws_iam_user(console_password_enabled_user) do
|
|
its('has_console_password?') { should be true }
|
|
end |