ASNMTAP

 view release on metacpan or  search on metacpan

lib/ASNMTAP/Asnmtap/Applications.pm  view on Meta::CPAN

    pagedir_prefix[1] = "-cv";
    pagedir_prefix[2] = "-mcv";

    function getPageDirCookie( name ) {
      var prefix = name + '=';
      var ca = document.cookie.split( ';' );

      for( var i=0; i < ca.length; i++ ) {
        var c = ca[i];
        while ( c.charAt( 0 ) == ' ' ) c = c.substring( 1, c.length );
        if ( c.indexOf( prefix ) == 0 ) return unescape( c.substring( prefix.length, c.length ) );
      }

      return null;
    }

    function deletePageDirCookie( name ) { setPageDirCookie( name, '', '', -1 ); }

    function setPageDirCookie( name, url, value, days ) {
      var expires = '';

      if ( days ) {
        (time = new Date()).setTime( new Date().getTime() + days * 24 * 60 * 60 * 1000);
        expires = "; expires=" + time.toGMTString();
      }

	  document.cookie = name + "=" + escape(value) + expires + "; path=/";
    }

    function loadEnvironmentPageDirCookie ( pageDir, environment ) {
      var name = 'pagedir_id_' + pageDir + '_' + environment;
      var url  = '$HTTPSURL/nav/' + pageDir + '/';
      if (environment != 'P') { url += environment + '/'; }
      reloadPageDirCookie( name, url );
    }

    function reloadPageDirCookie( name, url ) {

lib/ASNMTAP/Asnmtap/Applications.pm  view on Meta::CPAN

    }

    function setSoundCookie( name, value, days ) {
      var expires = '';

      if ( days ) {
        (time = new Date()).setTime( new Date().getTime() + days * 24 * 60 * 60 * 1000);
        expires = "; expires=" + time.toGMTString();
      }

	  document.cookie = name + "=" + escape(value) + expires + "; path=$HTTPSURL/nav/";
    }

    function getSoundCookie( name ) {
      var prefix = name + '=';
      var ca = document.cookie.split( ';' );

      for( var i=0; i < ca.length; i++ ) {
        var c = ca[i];
        while ( c.charAt( 0 ) == ' ' ) c = c.substring( 1, c.length );
        if ( c.indexOf( prefix ) == 0 ) return unescape( c.substring( prefix.length, c.length ) );
      }

      return null;
    }

    function deleteSoundCookie( name ) { setSoundCookie( name, '', -1 ); }

    function dynamicContentNS4NS6FF (elementID, content, booleanBlur) {
      if (document.all)
        document.getElementById(elementID).innerHTML=content

lib/ASNMTAP/Asnmtap/Applications.pm  view on Meta::CPAN

    pagedir_prefix[1] = "-cv";
    pagedir_prefix[2] = "-mcv";

    function getPageDirCookie( name ) {
      var prefix = name + '=';
      var ca = document.cookie.split( ';' );

      for( var i=0; i < ca.length; i++ ) {
        var c = ca[i];
        while ( c.charAt( 0 ) == ' ' ) c = c.substring( 1, c.length );
        if ( c.indexOf( prefix ) == 0 ) return unescape( c.substring( prefix.length, c.length ) );
      }

      return null;
    }

    function deletePageDirCookie( name ) { setPageDirCookie( name, '', '', -1 ); }

    function setPageDirCookie( name, url, value, days ) {
      var expires = '';

      if ( days ) {
        (time = new Date()).setTime( new Date().getTime() + days * 24 * 60 * 60 * 1000);
        expires = "; expires=" + time.toGMTString();
      }

	  document.cookie = name + "=" + escape(value) + expires + "; path=/";
    }

    function loadEnvironmentPageDirCookie ( pageDir, environment ) {
      var name = 'pagedir_id_' + pageDir + '_' + environment;
      var url  = '$HTTPSURL/nav/' + pageDir + '/';
      if (environment != 'P') { url += environment + '/'; }
      reloadPageDirCookie( name, url );
    }

    function reloadPageDirCookie( name, url ) {

lib/ASNMTAP/Asnmtap/Applications.pm  view on Meta::CPAN


  my $rv = 1;
  my $dbh = DBI->connect ("DBI:CSV:", "", "", {f_schema => undef, f_dir => $path, f_ext => $extention} ) or $rv = DBI_error_trap(*EMAILREPORT, "Cannot connect to the database", $logger, $debug);

  if ( $rv ) {
    $dbh->{csv_tables}{$tableName}  = { file => $tableFilename };

    $dbh->{csv_null}                = 1;
    $dbh->{csv_allow_whitespace}    = 0;
    $dbh->{csv_allow_loose_quotes}  = 0;
    $dbh->{csv_allow_loose_escapes} = 0;

    $dbh->{csv_eol}                 = $\;
    $dbh->{csv_sep_char}            = ',';
    $dbh->{csv_quote_char}          = '"';
    $dbh->{csv_escape_char}         = '"';

    if ( -e "$path$tableFilename$extention" ) {
      @{$columnSequence} = ();

      use Text::CSV;
      my $csv = Text::CSV->new( { binary => 1 } );

      if ( open my $rvOpen, "<", "$path$tableFilename$extention" ) {
        if ( my $fields = $csv->getline ($rvOpen) ) {
          @{$columnSequence} = @$fields;

lib/ASNMTAP/Asnmtap/Plugins/Modem.pm  view on Meta::CPAN

    }

    if ( $$modem->is_active () ) {
      print "ASNMTAP::Asnmtap::Plugins::Modem::get_modem_request::_test_modem: Modem is active\n" if ($debug);
    } else {
      $$asnmtapInherited->pluginValues ( { stateValue => $ERRORS{UNKNOWN}, error => 'Modem is turned off, or not functioning ...' }, $TYPE{APPEND} );
      return ( $ERRORS{UNKNOWN} );
    }

	if ( $test_modem ) {
      # Try with AT escape code, send `attention' sequence (+++)
      $$answer = $$modem->attention();
      $$answer = '<no answer>' unless ( defined $$answer );
      print "ASNMTAP::Asnmtap::Plugins::Modem::get_modem_request::_test_modem: Sending attention, modem says '$$answer'\n" if ($debug);

      unless ( $$answer eq '<no answer>' ) {
        $$asnmtapInherited->pluginValues ( { alert => "Sending attention, modem says '$$answer'" }, $TYPE{APPEND} );
        $$not_connected_guess++;
      }

      # Send empty AT command

plugins/templates/snmptt/snmptt.ini  view on Meta::CPAN

# as:            (one (two) three)(five $1 six)
# which outputs: five two six
# or:            (one (two) three)("five ".length($1)." six")e
# which outputs: five 3 six
#
# This is considered unsafe because the contents of the regular expression 
# (right) is executed (eval) by Perl which *could contain unsafe code*.
# BE SURE THAT THE SNMPTT CONFIGURATION FILES ARE SECURE!
allow_unsafe_regex = 0

# Set to 1 to have the backslash (escape) removed from quotes passed from
# snmptrapd.  For example, \" would be changed to just "
# Set to 0 to disable
remove_backslash_from_quotes = 0

# Set to 1 to have NODES files loaded each time a trap is processed.
# Set to 0 to have all NODES files loaded when the snmptt.conf files are loaded.
# If NODES files are used (files that contain lists of NODES), then setting to 1
# will cause the list to be loaded each time an EVENT is processed that uses
# NODES files.  This will allow the NODES file to be modified while SNMPTT is 
# running but can result in many file reads depending on the number of traps

plugins/templates/snmptt/snmptt.ini  view on Meta::CPAN

unknown_trap_exec = 

# FORMAT line that is passed to the unknown_trap_exec command.  If not defined, it
# defaults to what is described in the unknown_trap_exec setting.  The following
# would be *similar* to the default described in the unknown_trap_exec setting
# (all on one line):
# $x !! $X: Unknown trap ($o) received from $A at: Value 0: $A Value 1: $aR 
# Value 2: $T Value 3: $o Value 4: $aA Value 5: $C Value 6: $e Ent Values: $+*
unknown_trap_exec_format = 

# Set to 1 to escape wildards (* and ?) in EXEC, PREEXEC and the unknown_trap_exec
# commands.  Enable this to prevent the shell from expanding the wildcard 
# characters.  The default is 1.
exec_escape = 1

[Debugging]
# 0 - do not output messages
# 1 - output some basic messages
# 2 - out all messages
DEBUGGING = 0

# Debugging file - SNMPTT
# Location of debugging output file.  Leave blank to default to STDOUT (good for
# standalone mode, or daemon mode without forking)



( run in 0.457 second using v1.01-cache-2.11-cpan-c21f80fb71c )