Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    use strict;
    ...
                     );
    $< = $> = getpwnam 'nobody';
    $milter->main()
    
  2. or download this
    $milter->register('mymilter',
                      {
    ...
                      Sendmail::PMilter::SMFI_CURR_ACTS
                     );
    openlog 'mymilter', 'pid', Unix::Syslog::LOG_MAIL();
    
  3. or download this
    use Unix::Syslog qw(:macros :subs);
    sub is_valid_host
    ...
    
        Sendmail::PMilter::SMFIS_ACCEPT;
    }
    
  4. or download this
    my %cache;
    sub is_valid_host
    ...
        }
        $cache{$host};
    }
    
  5. or download this
            ++$msg_count;
            $0 = "[mymilter:$msg_count@" . scalar(localtime) . "] Checking
    + $fqdn ($rcpt_addr)";
    
  6. or download this
    #!/usr/bin/perl
    use strict;
    ...
    END { closelog }
    
    $milter->main(10,100);