public delegate bool VerifyPeerCallback(VerifyPeerContext context);
Callback invoked with the expected targetHost and the peer's certificate.
If false is returned by this callback then it is treated as a
verification failure and the attempted connection will fail.
Invocation of the callback is blocking, so any
implementation should be light-weight.
Note that the callback can potentially be invoked multiple times,
concurrently from different threads (e.g. when multiple connections
are being created for the same credentials).
[[["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-09-04 UTC."],[[["\u003cp\u003e\u003ccode\u003eVerifyPeerCallback\u003c/code\u003e is a delegate that's invoked with the expected target host and the peer's certificate for verification.\u003c/p\u003e\n"],["\u003cp\u003eReturning \u003ccode\u003efalse\u003c/code\u003e from this callback results in a verification failure and the attempted connection being terminated.\u003c/p\u003e\n"],["\u003cp\u003eThe callback's implementation should be lightweight, as its invocation is blocking and potentially occurs concurrently from multiple threads.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003econtext\u003c/code\u003e parameter, of type \u003ccode\u003eVerifyPeerContext\u003c/code\u003e, is passed to the callback for verification.\u003c/p\u003e\n"],["\u003cp\u003eThe callback returns a boolean value indicating whether the verification was successful (\u003ccode\u003etrue\u003c/code\u003e) or not (\u003ccode\u003efalse\u003c/code\u003e).\u003c/p\u003e\n"]]],[],null,[]]