17.07.2015 Views

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

Download eBook (PDF) - Red Gate Software

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Appendix A – Views and Functions Reference),Value_DigSig =SignByCert (Cert_ID('MySelfSignedCert'),Identification_Value,N'MyStr0ngP@ssw0rd2009')WHEREBorrower_ID = 1;GOListing A-25: Syntax of SignByCert.VerifySignedByAsymKeyThis function determines if the encrypted data has changed since it wasdigitally signed. The returned value is either a 1, which indicates that the datahas not changed, or 0 which indicates that the data has changed. This functionis often used in conjunction with the DecryptByAsymKey function.Successful digital signature verification requires the user to have VIEWDEFINITION permissions on the asymmetric key that was used to generate thedigital signature.USE HomeLending;GOSELECTVerifySignedByAsymKey(AsymKey_ID('MyASymKey'),Convert(nvarchar(max),DecryptByAsymKey(AsymKey_ID('MyASymKey'),Identification_Value,N'MyStr0ngP@ssword2009')),N'MyStr0ngP@ssword2009')FROMdbo.Borrower_IdentificationWHEREBorrower_ID = 1;GOListing A-26: Syntax of VerifySignedByAsymKey.220

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!