Advertisement
Guest User

Untitled

a guest
Dec 8th, 2016
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.78 KB | None | 0 0
  1. {
  2. "Version": "2012-10-17",
  3. "Statement":[
  4. {
  5. "Sid": "AllowAllUsersToListAccounts",
  6. "Effect": "Allow",
  7. "Action":[
  8. "iam:ListAccountAliases",
  9. "iam:ListUsers",
  10. "iam:GetAccountSummary"
  11. ],
  12. "Resource": "*"
  13. },
  14. {
  15. "Sid": "AllowIndividualUserToSeeAndManageTheirOwnAccountInformation",
  16. "Effect": "Allow",
  17. "Action":[
  18. "iam:ChangePassword",
  19. "iam:CreateAccessKey",
  20. "iam:CreateLoginProfile",
  21. "iam:DeleteAccessKey",
  22. "iam:DeleteLoginProfile",
  23. "iam:GetAccountPasswordPolicy",
  24. "iam:GetLoginProfile",
  25. "iam:ListAccessKeys",
  26. "iam:UpdateAccessKey",
  27. "iam:UpdateLoginProfile",
  28. "iam:ListSigningCertificates",
  29. "iam:DeleteSigningCertificate",
  30. "iam:UpdateSigningCertificate",
  31. "iam:UploadSigningCertificate",
  32. "iam:ListSSHPublicKeys",
  33. "iam:GetSSHPublicKey",
  34. "iam:DeleteSSHPublicKey",
  35. "iam:UpdateSSHPublicKey",
  36. "iam:UploadSSHPublicKey"
  37. ],
  38. "Resource": "arn:aws:iam::accountid:user/${aws:username}"
  39. },
  40. {
  41. "Sid": "AllowIndividualUserToListTheirOwnMFA",
  42. "Effect": "Allow",
  43. "Action":[
  44. "iam:ListVirtualMFADevices",
  45. "iam:ListMFADevices"
  46. ],
  47. "Resource":[
  48. "arn:aws:iam::accountid:mfa/*",
  49. "arn:aws:iam::accountid:user/${aws:username}"
  50. ]
  51. },
  52. {
  53. "Sid": "AllowIndividualUserToManageTheirOwnMFA",
  54. "Effect": "Allow",
  55. "Action":[
  56. "iam:CreateVirtualMFADevice",
  57. "iam:DeactivateMFADevice",
  58. "iam:DeleteVirtualMFADevice",
  59. "iam:RequestSmsMfaRegistration",
  60. "iam:FinalizeSmsMfaRegistration",
  61. "iam:EnableMFADevice",
  62. "iam:ResyncMFADevice"
  63. ],
  64. "Resource":[
  65. "arn:aws:iam::accountid:mfa/${aws:username}",
  66. "arn:aws:iam::accountid:user/${aws:username}"
  67. ]
  68. },
  69. {
  70. "Sid": "BlockAnyAccessOtherThanAboveUnlessSignedInWithMFA",
  71. "Effect": "Deny",
  72. "NotAction": "iam:*",
  73. "Resource": "*",
  74. "Condition":{
  75. "BoolIfExists":{ "aws:MultiFactorAuthPresent": "false"}
  76. }
  77. }
  78. ]
  79. }
  80.  
  81. {
  82. "Sid": "BlockAnyAccessOtherThanAboveUnlessSignedInWithMFA",
  83. "Effect": "Deny",
  84. "NotAction": "iam:*",
  85. "Resource": "*",
  86. "Condition":{
  87. "Bool":{ "aws:MultiFactorAuthPresent": "false"}
  88. }
  89. }
  90.  
  91. {
  92. "Version": "2012-10-17",
  93. "Statement": [
  94. {
  95. "Sid": "AllowAllUsersToListAccounts",
  96. "Effect": "Allow",
  97. "Action": [
  98. "iam:ListAccountAliases",
  99. "iam:ListUsers"
  100. ],
  101. "Resource": [
  102. "arn:aws:iam::accountid:user/*"
  103. ]
  104. },
  105. {
  106. "Sid": "AllowIndividualUserToSeeTheirAccountInformation",
  107. "Effect": "Allow",
  108. "Action": [
  109. "iam:GetAccountPasswordPolicy",
  110. "iam:GetAccountSummary",
  111. "iam:GetLoginProfile"
  112. ],
  113. "Resource": [
  114. "arn:aws:iam::accountid:user/${aws:username}"
  115. ]
  116. },
  117. {
  118. "Sid": "AllowIndividualUserToListTheirMFA",
  119. "Effect": "Allow",
  120. "Action": [
  121. "iam:ListVirtualMFADevices",
  122. "iam:ListMFADevices"
  123. ],
  124. "Resource": [
  125. "arn:aws:iam::accountid:mfa/*",
  126. "arn:aws:iam::accountid:user/${aws:username}"
  127. ]
  128. },
  129. {
  130. "Sid": "AllowIndividualUserToManageThierMFA",
  131. "Effect": "Allow",
  132. "Action": [
  133. "iam:CreateVirtualMFADevice",
  134. "iam:DeactivateMFADevice",
  135. "iam:DeleteVirtualMFADevice",
  136. "iam:EnableMFADevice",
  137. "iam:ResyncMFADevice"
  138. ],
  139. "Resource": [
  140. "arn:aws:iam::accountid:mfa/${aws:username}",
  141. "arn:aws:iam::accountid:user/${aws:username}"
  142. ]
  143. },
  144. {
  145. "Sid": "DoNotAllowAnythingOtherThanAboveUnlessMFAd",
  146. "Effect": "Deny",
  147. "NotAction": "iam:*",
  148. "Resource": "*",
  149. "Condition": {
  150. "Bool": {
  151. "aws:MultiFactorAuthPresent": "false"
  152. }
  153. }
  154. }
  155. ]
  156. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement