Hooks can be used to modify the processing sequence of SET requests. Hooks must be implemented by the agent designer, then compiled and linked into the agent.
Five hooks may be defined. They must be passed as the last five arguments to the initialization routine snmpdInitFinish( ):
- to validate a SET request PDU (the PDU-validation hook)
- before the SET request is processed (the pre-set-request hook)
- after the SET request (and, hence, the relevant method routine) has been processed (the post-set-request hook)
- upon failure of a SET request (the set-failure hook)
- to release memory that was privately allocated in snmpIoCommunityValidate( ) for packet processing (the private-memory-deallocation hook)
For more information on implementing these hooks, see the manual page for snmpdInitFinish( ) in F. SNMP Reference.