Please ensure Javascript is enabled for purposes of website accessibility
Powered by Zoomin Software. For more details please contactZoomin

AF SDK Reference

AFSecurity.VerifySignature Method

  • Last UpdatedNov 18, 2025
  • 2 minute read
AFSecurity.VerifySignature Method
Verify the signature of an assembly.

Namespace:  OSIsoft.AF
Assembly:  OSIsoft.AFSDK (in OSIsoft.AFSDK.dll) Version: 3.1.1.1182

Syntax

public static bool VerifySignature(
	string assemblyPath,
	AFVerifySignatureLevel level,
	IEnumerable<string> trustedProviders = null
)
Public Shared Function VerifySignature ( 
	assemblyPath As String,
	level As AFVerifySignatureLevel,
	Optional trustedProviders As IEnumerable(Of String) = Nothing
) As Boolean

Dim assemblyPath As String
Dim level As AFVerifySignatureLevel
Dim trustedProviders As IEnumerable(Of String)
Dim returnValue As Boolean

returnValue = AFSecurity.VerifySignature(assemblyPath, 
	level, trustedProviders)
public:
static bool VerifySignature(
	String^ assemblyPath, 
	AFVerifySignatureLevel level, 
	IEnumerable<String^>^ trustedProviders = nullptr
)
static member VerifySignature : 
        assemblyPath : string * 
        level : AFVerifySignatureLevel * 
        ?trustedProviders : IEnumerable<string> 
(* Defaults:
        let _trustedProviders = defaultArg trustedProviders null
*)
-> bool 

Parameters

assemblyPath
Type: SystemString
The full path to the assembly to be verified.
level
Type: OSIsoft.AFAFVerifySignatureLevel
The level used when verifying the signature of an assembly.
trustedProviders (Optional)
Type: System.Collections.GenericIEnumerableString
A list of trusted providers used when the level is RequireSignedTrustedProvider. This parameter is ignored for all other verification levels.

Return Value

Type: Boolean
Returns if the signature of the assembly is valid for the specified level of verification.

Remarks

The assembly specified by the assemblyPath parameter is checked for a valid signature according to the specified level of verification. When the level is RequireSignedTrustedProvider, then a list of trusted providers must also be specified. The certificate's subject distinguished SubjectName must contain one of the strings specified in the list of trusted providers.

Version Information

AFSDK


See Also

In This Topic
Related Links
TitleResults for “How to create a CRG?”Also Available in