Unit snmpsend
Descrição
SNMP client
Supports SNMPv1 include traps, SNMPv2c and SNMPv3 include authorization and privacy encryption.
Used RFC: RFC-1157, RFC-1901, RFC-3412, RFC-3414, RFC-3416, RFC-3826
Supported Authorization hashes: MD5, SHA1 Supported Privacy encryptions: DES, 3DES, AES
Uses
Visão Geral
Classes, Interfaces, Objetos e Registros
Classe TSNMPMib |
Data object with one record of MIB OID and corresponding values. |
Registro TV3Sync |
It holding all information for SNMPv3 agent synchronization |
Classe TSNMPRec |
Data object abstracts SNMP data packet |
Classe TSNMPSend |
Implementation of SNMP protocol. |
Funções e Procedimentos
function SNMPGet(const OID, Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
function SNMPSet(const OID, Community, SNMPHost, Value: AnsiString; ValueType: Integer): Boolean; |
function SNMPGetNext(var OID: AnsiString; const Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
function SNMPGetTable(const BaseOID, Community, SNMPHost: AnsiString; const Value: TStrings): Boolean; |
function SNMPGetTableElement(const BaseOID, RowID, ColID, Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
function SendTrap(const Dest, Source, Enterprise, Community: AnsiString; Generic, Specific, Seconds: Integer; const MIBName, MIBValue: AnsiString; MIBtype: Integer): Integer; |
function RecvTrap(var Dest, Source, Enterprise, Community: AnsiString; var Generic, Specific, Seconds: Integer; const MIBName, MIBValue: TStringList): Integer; |
Tipos
Constantes
Descrição
Funções e Procedimentos
function SNMPGet(const OID, Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
A very useful function and example of its use would be found in the TSNMPSend object. It implements basic GET method of the SNMP protocol. The MIB value is located in the "OID" variable, and is sent to the requested "SNMPHost" with the proper "Community" access identifier. Upon a successful retrieval, "Value" will contain the information requested. If the SNMP operation is successful, the result returns True .
|
function SNMPSet(const OID, Community, SNMPHost, Value: AnsiString; ValueType: Integer): Boolean; |
This is useful function and example of use TSNMPSend object. It implements the basic SET method of the SNMP protocol. If the SNMP operation is successful, the result is True . "Value" is value of MIB Oid for "SNMPHost" with "Community" access identifier. You must specify "ValueType" too.
|
function SNMPGetNext(var OID: AnsiString; const Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
A very useful function and example of its use would be found in the TSNMPSend object. It implements basic GETNEXT method of the SNMP protocol. The MIB value is located in the "OID" variable, and is sent to the requested "SNMPHost" with the proper "Community" access identifier. Upon a successful retrieval, "Value" will contain the information requested. If the SNMP operation is successful, the result returns True .
|
function SNMPGetTable(const BaseOID, Community, SNMPHost: AnsiString; const Value: TStrings): Boolean; |
A very useful function and example of its use would be found in the TSNMPSend object. It implements basic read of SNMP MIB tables. As BaseOID you must specify basic MIB OID of requested table (base IOD is OID without row and column specificator!) Table is readed into stringlist, where each string is comma delimited string.
Warning: this function is not have best performance. For better performance you must write your own function. best performace you can get by knowledge of structuture of table and by more then one MIB on one query.
|
function SNMPGetTableElement(const BaseOID, RowID, ColID, Community, SNMPHost: AnsiString; var Value: AnsiString): Boolean; |
A very useful function and example of its use would be found in the TSNMPSend object. It implements basic read of SNMP MIB table element. As BaseOID you must specify basic MIB OID of requested table (base IOD is OID without row and column specificator!) As next you must specify identificator of row and column for specify of needed field of table.
|
function SendTrap(const Dest, Source, Enterprise, Community: AnsiString; Generic, Specific, Seconds: Integer; const MIBName, MIBValue: AnsiString; MIBtype: Integer): Integer; |
A very useful function and example of its use would be found in the TSNMPSend object. It implements a TRAPv1 to send with all data in the parameters.
|
function RecvTrap(var Dest, Source, Enterprise, Community: AnsiString; var Generic, Specific, Seconds: Integer; const MIBName, MIBValue: TStringList): Integer; |
A very useful function and example of its use would be found in the TSNMPSend object. It receives a TRAPv1 and returns all the data that comes with it.
|
Tipos
TV3Flags = (...); |
Possible values for SNMPv3 flags.
This flags specify level of authorization and encryption.
Valores
-
NoAuthNoPriv
-
AuthNoPriv
-
AuthPriv
|
TV3Auth = (...); |
Type of SNMPv3 authorization
Valores
|
TV3Priv = (...); |
Type of SNMPv3 privacy
Valores
|
Constantes
cSnmpTrapProtocol = '162'; |
|
EResourceUnavailable = 13; |
|
EAuthorizationError = 16; |
|
Gerado por PasDoc 0.16.0.