Security level must be one of “noAuthNoPriv”, “authNoPriv”, or “authPriv”¶
Description¶
The third argument of snmp3_get() must be one of the following values, “noAuthNoPriv”, “authNoPriv”, or “authPriv”. Case is important. There are not constants to for these values.
Example¶
<?php
try {
var_dump(snmp3_get($hostname, $community, '', '', '', '', '', '.1.3.6.1.2.1.1.1.0'));
} catch (\ValueError $e) {
echo $e->getMessage() . \PHP_EOL;
}
?>
Solutions¶
Use one of the three possible values.