(PHP 5 >= 5.4.0)
SNMP::setSecurity — Configures security-related SNMPv3 session parameters
setSecurity configures security-related session parameters used in SNMP protocol version 3
the security level (noAuthNoPriv|authNoPriv|authPriv)
the authentication protocol (MD5 or SHA)
the authentication pass phrase
the privacy protocol (DES or AES)
the privacy pass phrase
the context name
the context EngineID
Returns TRUE on success or FALSE on failure.
Example #1 SNMP::setSecurity() example
<?php
$session = new SNMP(SNMP::VERSION_3, $hostname, $rwuser, $timeout, $retries);
$session->setSecurity('authPriv', 'MD5', $auth_pass, 'AES', $priv_pass, '', 'aeeeff');
?>