ASNMTAP
view release on metacpan or search on metacpan
- NEW create_weblogic_configuration_database_with_SNMP.pl
- NEW create_weblogic_configuration_database_with_SNMP.SQL
ASNMTAP::Asnmtap::Plugins::Mail.pm
- FIX regarding MIME-Encoding '7bit' and code optimalisation
- NEW MIME-Encoding: '8bit', 'binhex', 'binary', 'x-gzip64', 'x-uu' & 'x-uuencode'
- overview MIME-Encoding: '7bit', '8bit', 'quoted-printable', 'base64', 'binhex', 'binary', 'x-gzip64', 'x-uu' & 'x-uuencode'
ASNMTAP::Asnmtap::Plugins::Nagios
- NEW check_network_interface_status.pl
- NEW snmptt_traps_remove_pending_and_duplicated.pl
ASNMTAP::Asnmtap::SOAP.pm
- NEW added basic authentication and credentials
- NEW added soapaction and readable
ASNMTAP::Asnmtap::Plugins::WebTransact.pm
- NEW Inherited LWP user agent object: $objectWebTransact->ua = LWP::UserAgent->new;
check_template-WebTransact-XML-Monitoring.pl & check_template-WebTransact-XML-Monitoring.t
- NEW WebTransact plugin template for XML Monitoring
check_template-WebTransact-with-client-authorization.pl & check_template-WebTransact-with-client-authorization.t
- NEW WebTransact plugin template with client authorization
detailedStatisticsReportGenerationAndCompareResponsetimeTrends.pl
- add corresponding comments to the report
generateReports.pl & getArchivedReport.pl
lib/ASNMTAP/Asnmtap/Plugins/SOAP.pm view on Meta::CPAN
$ASNMTAP::Asnmtap::Plugins::SOAP::VERSION = do { my @r = (q$Revision: 3.002.003$ =~ /\d+/g); sprintf "%d."."%03d" x $#r, @r };
}
# Utility methods - - - - - - - - - - - - - - - - - - - - - - - - - - - -
sub get_soap_request {
my %defaults = ( asnmtapInherited => undef,
custom => undef,
customArguments => undef,
proxy => undef,
credentials => undef,
namespace => undef,
registerNamespace => undef,
method => undef,
soapaction => undef,
xmlContent => undef,
params => undef,
envprefix => 'soapenv',
encprefix => 'soapenc',
encodingStyle => undef,
readable => 1,
lib/ASNMTAP/Asnmtap/Plugins/SOAP.pm view on Meta::CPAN
}
if ( defined $proxySettings ) {
$service->proxy ( $parms{proxy}, timeout => $timeout, proxy => ['http' => "http://$proxySettings"] );
} else {
$service->proxy ( $parms{proxy}, timeout => $timeout );
}
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
$service->transport->credentials( @{$parms{credentials}} ) if ( defined $parms{credentials} );
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# $service->proxy ( 'https://USERNAME:PASSWORD@secure.citap.be/authorization/hibye.cgi' );
# or
# $service->proxy ( 'https://secure.citap.be/authorization/hibye.cgi', credentials => [ 'secure.citap.be:443', "ASNMTAP's Authorization Access", 'USERNAME' => 'PASSWORD' ], timeout => $timeout );
# or
# $service->transport->credentials( 'secure.citap.be:443', "ASNMTAP's Authorization Access", 'USERNAME' => 'PASSWORD' );
# or
# use MIME::Base64;
# $service->transport->http_request->header( 'Authorization' => 'Basic '. MIME::Base64::encode ( 'USERNAME' .':'. 'PASSWORD', '' ) );
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
$service->transport->agent( $browseragent );
$service->transport->timeout( $timeout );
use HTTP::Cookies;
$service->transport->cookie_jar( HTTP::Cookies->new ) if ( $cookies );
lib/ASNMTAP/Asnmtap/Plugins/SOAP.pod view on Meta::CPAN
registerNamespace => \%soapService_Register_NS,
xmlContent => $xmlContent,
params => $params,
cookies => 1,
perfdataLabel => 'SOAP with Basic Authentication'
);
($returnCode, $xml) = get_soap_request (
asnmtapInherited => \$objectPlugins,
proxy => 'https://secure.citap.be/authorization/hibye.cgi',
credentials => [ 'secure.citap.be:443', "ASNMTAP's Authorization Access", 'USERNAME' => 'PASSWORD' ],
namespace => $namespace,
method => $method,
registerNamespace => \%soapService_Register_NS,
xmlContent => $xmlContent,
params => $params,
cookies => 1,
perfdataLabel => 'SOAP with Credentials'
);
unless ( $returnCode ) {
lib/ASNMTAP/Asnmtap/Plugins/SOAP.pod view on Meta::CPAN
This lets you specify an endpoint (service address) and also loads the required module at the same time.
proxy: 'http://services.soaplite.com/hibye.cgi'
When using SOAP with basic authentication you can add username and password to your URL as follows:
proxy: 'http://USERNAME:PASSWORD@services.soaplite.com/hibye.cgi'
a required scalar.
=item credentials
Set the user name and password to be used for a realm.
credentials: [ $hostname_port, $realm, $username, $password ]
[ 'secure.citap.be:443', "ASNMTAP's Authorization Access", 'USERNAME' => 'PASSWORD' ]
a optional array.
=item namespace
Sets the URI that will be used as the namespace for the resulting XML entity.
namespace: 'http://www.soaplite.com/Demo'
lib/ASNMTAP/Asnmtap/Plugins/WebTransact.pod view on Meta::CPAN
);
$returnCode = $objectWebTransact->check ( { } );
equals to:
@URLS = (
{ Method => 'GET', Url => 'https://secure.citap.com/authorization/', Qs_var => [], Qs_fixed => [], Exp => "Testing Client Authorization", Exp_Fault => ">>>NIHIL<<<", Msg => "Testing Client Authorization", Msg_Fault => "Testing Client Authorizatio...
);
$objectWebTransact->ua->credentials ( 'secure.citap.com:443', "ASNMTAP's Authorization Access", 'USERNAME', 'PASSWORD' );
$returnCode = $objectWebTransact->check ( { } );
=back
=head1 TOOLS
=over 4
=item GrinderCaptureConverter.pl
plugins/nagios/templates/check_template-ldap.pl view on Meta::CPAN
print "\nDN: $dn\n" if ($debug);
if ($debug >= 2) {
my $entry = $messageLDAP->entry(0);
foreach my $attribute ($entry->attributes) { print $attribute, ": ", $entry->get_value($attribute), "\n"; }
}
$ldap->unbind();
if ($dn ne '' && defined $PASS && $PASS ne '') {
# Now let's verify the authentication credentials, by rebinding with the users DN and password.
my $ldap = Net::LDAP->new ($ldapserver, port => $ldapport, version => 2) or $returnValue = 0;
if ($returnValue) {
$messageLDAP = $ldap->bind($dn, password => $PASS);
if (ldapStatusOk ('Wrong username or password', $messageLDAP, $debug)) {
$ldap->unbind();
$objectNagios->pluginValues ( { stateValue => $ERRORS{OK}, alert => "Search and Authentication is good" }, $TYPE{APPEND} );
}
} else {
plugins/templates/check_template-WebTransact-with-client-authorization.pl view on Meta::CPAN
{ Method => 'GET', Url => 'https://USERNAME:PASSWORD@secure.citap.be/authorization/', Qs_var => [], Qs_fixed => [], Exp => "Testing Client Authorization", Exp_Fault => ">>>NIHIL<<<", Msg => "Testing Client Authorization", Msg_Fault => "Testing Cli...
);
$returnCode = $objectWebTransact->check ( { } );
# methode 2
@URLS = (
{ Method => 'GET', Url => 'https://secure.citap.com/authorization/', Qs_var => [], Qs_fixed => [], Exp => "Testing Client Authorization", Exp_Fault => ">>>NIHIL<<<", Msg => "Testing Client Authorization", Msg_Fault => "Testing Client Authorization...
);
$objectWebTransact->ua->credentials ( 'secure.citap.com:443', "ASNMTAP's Authorization Access", 'USERNAME', 'PASSWORD' );
$returnCode = $objectWebTransact->check ( { } );
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# End plugin - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
undef $objectWebTransact;
$objectPlugins->exit (7);
( run in 0.333 second using v1.01-cache-2.11-cpan-a5abf4f5562 )