(::Array<::Google::Cloud::Kms::V1::AccessReason>) — The list of allowed reasons for access to a
CryptoKey. Zero allowed access reasons
means all encrypt, decrypt, and sign operations for the
CryptoKey associated with this policy will
fail.
value (::Array<::Google::Cloud::Kms::V1::AccessReason>) — The list of allowed reasons for access to a
CryptoKey. Zero allowed access reasons
means all encrypt, decrypt, and sign operations for the
CryptoKey associated with this policy will
fail.
Returns
(::Array<::Google::Cloud::Kms::V1::AccessReason>) — The list of allowed reasons for access to a
CryptoKey. Zero allowed access reasons
means all encrypt, decrypt, and sign operations for the
CryptoKey associated with this policy will
fail.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["# KMS Inventory V1 API - Class Google::Cloud::Kms::V1::KeyAccessJustificationsPolicy (v0.15.1)\n\nVersion latestkeyboard_arrow_down\n\n- [0.15.1 (latest)](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.15.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.15.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.14.1](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.14.1/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.13.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.13.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.12.2](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.12.2/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.11.3](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.11.3/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.10.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.10.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.9.1](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.9.1/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.8.3](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.8.3/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.7.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.7.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.6.1](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.6.1/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.5.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.5.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.4.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.4.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.3.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.3.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.2.1](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.2.1/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy)\n- [0.1.0](/ruby/docs/reference/google-cloud-kms-inventory-v1/0.1.0/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy) \nReference documentation and code samples for the KMS Inventory V1 API class Google::Cloud::Kms::V1::KeyAccessJustificationsPolicy.\n\nA\n[KeyAccessJustificationsPolicy](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-KeyAccessJustificationsPolicy \"Google::Cloud::Kms::V1::KeyAccessJustificationsPolicy (class)\")\nspecifies zero or more allowed\n[AccessReason](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-AccessReason \"Google::Cloud::Kms::V1::AccessReason (module)\") values for encrypt, decrypt,\nand sign operations on a [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\"). \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #allowed_access_reasons\n\n def allowed_access_reasons() -\u003e ::Array\u003c::Google::Cloud::Kms::V1::AccessReason\u003e\n\n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Kms::V1::AccessReason](./Google-Cloud-Kms-V1-AccessReason)\\\u003e) --- The list of allowed reasons for access to a [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\"). Zero allowed access reasons means all encrypt, decrypt, and sign operations for the [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\") associated with this policy will fail.\n\n### #allowed_access_reasons=\n\n def allowed_access_reasons=(value) -\u003e ::Array\u003c::Google::Cloud::Kms::V1::AccessReason\u003e\n\n**Parameter**\n\n- **value** (::Array\\\u003c[::Google::Cloud::Kms::V1::AccessReason](./Google-Cloud-Kms-V1-AccessReason)\\\u003e) --- The list of allowed reasons for access to a [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\"). Zero allowed access reasons means all encrypt, decrypt, and sign operations for the [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\") associated with this policy will fail. \n**Returns**\n\n- (::Array\\\u003c[::Google::Cloud::Kms::V1::AccessReason](./Google-Cloud-Kms-V1-AccessReason)\\\u003e) --- The list of allowed reasons for access to a [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\"). Zero allowed access reasons means all encrypt, decrypt, and sign operations for the [CryptoKey](/ruby/docs/reference/google-cloud-kms-inventory-v1/latest/Google-Cloud-Kms-V1-CryptoKey \"Google::Cloud::Kms::V1::CryptoKey (class)\") associated with this policy will fail."]]