Helper class to make dealing with multiple (if 2 qualifies as multiple) authentication protocols in a transparent way. Calling class keeps the authentication protocol selection (as defined on the agent) in an integer variable that can have 3 values: None, MD5, or SHA1. Using GetInstance(AuthenticationDigests), calling method can get authentication protocol implementation class instance cast as IAuthenticationDigest interface and perform authentication operations (either authenticate outgoing packets to verify authentication of incoming packets) without needing to further care about which authentication protocol is used. Example of how to use this class:
CopyC#
IAuthenticationDigest authenticationImplementation = Authentication.GetInstance(AuthenticationDigests.MD5);
authenticationImplementation.authenticateIncomingMsg(...);
authenticationImplementation.authenticateOutgoingMsg(...);

Namespace:  SnmpSharpNet
Assembly:  SnmpSharpNet (in SnmpSharpNet.dll) Version: 0.5.0.0 (0.5.0.0)

Syntax

         
 C#  Visual Basic  Visual C++ 
public sealed class Authentication
Public NotInheritable Class Authentication
public ref class Authentication sealed

Members

      
 All Members  Methods  
 Public

 Protected
 Instance

 Static 
 Declared

 Inherited
 XNA Framework Only 

 .NET Compact Framework Only 

 MemberDescription
Equals(Object)
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
GetHashCode()()()
Serves as a hash function for a particular type.
(Inherited from Object.)
GetInstance(AuthenticationDigests)
Get instance of authentication protocol.
GetType()()()
Gets the Type of the current instance.
(Inherited from Object.)
ToString()()()
Returns a String that represents the current Object.
(Inherited from Object.)

Inheritance Hierarchy

System..::.Object
  SnmpSharpNet..::.Authentication

See Also