public sealed class GenerateRandomBytesResponse : IMessage<GenerateRandomBytesResponse>, IEquatable<GenerateRandomBytesResponse>, IDeepCloneable<GenerateRandomBytesResponse>, IBufferMessage, IMessage
Reference documentation and code samples for the Google Cloud Key Management Service v1 API class GenerateRandomBytesResponse.
Response message for
[KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes].
Integrity verification field. A CRC32C checksum of the returned
[GenerateRandomBytesResponse.data][google.cloud.kms.v1.GenerateRandomBytesResponse.data].
An integrity check of
[GenerateRandomBytesResponse.data][google.cloud.kms.v1.GenerateRandomBytesResponse.data]
can be performed by computing the CRC32C checksum of
[GenerateRandomBytesResponse.data][google.cloud.kms.v1.GenerateRandomBytesResponse.data]
and comparing your results to this field. Discard the response in case of
non-matching checksum values, and perform a limited number of retries. A
persistent mismatch may indicate an issue in your computation of the CRC32C
checksum. Note: This field is defined as int64 for reasons of compatibility
across different languages. However, it is a non-negative integer, which
will never exceed 2^32-1, and can be safely downconverted to uint32 in
languages that support this type.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThe latest version available for the \u003ccode\u003eGenerateRandomBytesResponse\u003c/code\u003e class is 3.16.0.\u003c/p\u003e\n"],["\u003cp\u003eThis class, \u003ccode\u003eGenerateRandomBytesResponse\u003c/code\u003e, is part of the Google Cloud Key Management Service v1 API, specifically within the \u003ccode\u003eGoogle.Cloud.Kms.V1\u003c/code\u003e namespace.\u003c/p\u003e\n"],["\u003cp\u003eIt serves as the response message for the \u003ccode\u003eKeyManagementService.GenerateRandomBytes\u003c/code\u003e function, offering data verification through the \u003ccode\u003eDataCrc32C\u003c/code\u003e property.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eGenerateRandomBytesResponse\u003c/code\u003e class implements multiple interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, alongside inheriting from \u003ccode\u003eobject\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eGenerateRandomBytesResponse\u003c/code\u003e class offers two constructors, one with no parameters and the other taking another \u003ccode\u003eGenerateRandomBytesResponse\u003c/code\u003e object as a parameter.\u003c/p\u003e\n"]]],[],null,["# Google Cloud Key Management Service v1 API - Class GenerateRandomBytesResponse (3.18.0)\n\nVersion latestkeyboard_arrow_down\n\n- [3.18.0 (latest)](/dotnet/docs/reference/Google.Cloud.Kms.V1/latest/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.17.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.17.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.16.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.16.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.15.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.15.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.14.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.14.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.13.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.13.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.12.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.12.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.11.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.11.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.10.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.10.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.9.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.9.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.8.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.8.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.7.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.7.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.6.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.6.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.5.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.5.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.4.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.4.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.3.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.3.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.2.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.2.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.1.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.1.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [3.0.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/3.0.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.9.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.9.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.8.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.8.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.7.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.7.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.6.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.6.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.5.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.5.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.4.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.4.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.3.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.3.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse)\n- [2.2.0](/dotnet/docs/reference/Google.Cloud.Kms.V1/2.2.0/Google.Cloud.Kms.V1.GenerateRandomBytesResponse) \n\n public sealed class GenerateRandomBytesResponse : IMessage\u003cGenerateRandomBytesResponse\u003e, IEquatable\u003cGenerateRandomBytesResponse\u003e, IDeepCloneable\u003cGenerateRandomBytesResponse\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Google Cloud Key Management Service v1 API class GenerateRandomBytesResponse.\n\nResponse message for\n\\[KeyManagementService.GenerateRandomBytes\\]\\[google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes\\]. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e GenerateRandomBytesResponse \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[GenerateRandomBytesResponse](/dotnet/docs/reference/Google.Cloud.Kms.V1/latest/Google.Cloud.Kms.V1.GenerateRandomBytesResponse), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[GenerateRandomBytesResponse](/dotnet/docs/reference/Google.Cloud.Kms.V1/latest/Google.Cloud.Kms.V1.GenerateRandomBytesResponse), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[GenerateRandomBytesResponse](/dotnet/docs/reference/Google.Cloud.Kms.V1/latest/Google.Cloud.Kms.V1.GenerateRandomBytesResponse), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Kms.V1](/dotnet/docs/reference/Google.Cloud.Kms.V1/latest/Google.Cloud.Kms.V1)\n\nAssembly\n--------\n\nGoogle.Cloud.Kms.V1.dll\n\nConstructors\n------------\n\n### GenerateRandomBytesResponse()\n\n public GenerateRandomBytesResponse()\n\n### GenerateRandomBytesResponse(GenerateRandomBytesResponse)\n\n public GenerateRandomBytesResponse(GenerateRandomBytesResponse other)\n\nProperties\n----------\n\n### Data\n\n public ByteString Data { get; set; }\n\nThe generated data.\n\n### DataCrc32C\n\n public long? DataCrc32C { get; set; }\n\nIntegrity verification field. A CRC32C checksum of the returned\n\\[GenerateRandomBytesResponse.data\\]\\[google.cloud.kms.v1.GenerateRandomBytesResponse.data\\].\nAn integrity check of\n\\[GenerateRandomBytesResponse.data\\]\\[google.cloud.kms.v1.GenerateRandomBytesResponse.data\\]\ncan be performed by computing the CRC32C checksum of\n\\[GenerateRandomBytesResponse.data\\]\\[google.cloud.kms.v1.GenerateRandomBytesResponse.data\\]\nand comparing your results to this field. Discard the response in case of\nnon-matching checksum values, and perform a limited number of retries. A\npersistent mismatch may indicate an issue in your computation of the CRC32C\nchecksum. Note: This field is defined as int64 for reasons of compatibility\nacross different languages. However, it is a non-negative integer, which\nwill never exceed 2\\^32-1, and can be safely downconverted to uint32 in\nlanguages that support this type."]]