Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ VerifyData() [2/4]

virtual bool System.Security.Cryptography.RSA.VerifyData ( byte[] data,
int offset,
int count,
byte[] signature,
HashAlgorithmName hashAlgorithm,
RSASignaturePadding padding )
inlinevirtualinherited

Definition at line 253 of file RSA.cs.

254 {
255 if (data == null)
256 {
257 throw new ArgumentNullException("data");
258 }
259 if (offset < 0 || offset > data.Length)
260 {
261 throw new ArgumentOutOfRangeException("offset");
262 }
263 if (count < 0 || count > data.Length - offset)
264 {
265 throw new ArgumentOutOfRangeException("count");
266 }
267 if (signature == null)
268 {
269 throw new ArgumentNullException("signature");
270 }
271 if (string.IsNullOrEmpty(hashAlgorithm.Name))
272 {
274 }
275 if (padding == null)
276 {
277 throw new ArgumentNullException("padding");
278 }
279 byte[] hash = HashData(data, offset, count, hashAlgorithm);
280 return VerifyHash(hash, signature, hashAlgorithm, padding);
281 }
static Exception HashAlgorithmNameNullOrEmpty()
Definition RSA.cs:672
virtual byte[] HashData(byte[] data, int offset, int count, HashAlgorithmName hashAlgorithm)
Definition RSA.cs:80
virtual bool VerifyHash(byte[] hash, byte[] signature, HashAlgorithmName hashAlgorithm, RSASignaturePadding padding)
Definition RSA.cs:75

References System.count, System.Security.Cryptography.RSA.HashAlgorithmNameNullOrEmpty(), System.Security.Cryptography.RSA.HashData(), System.Security.Cryptography.HashAlgorithmName.Name, System.offset, and System.Security.Cryptography.RSA.VerifyHash().