Sponsored Content
Top Forums Shell Programming and Scripting How to Find List of MQ and Websphere certificates that are installed on Linux and UNIX servers? Post 302948776 by CarloM on Thursday 2nd of July 2015 12:15:24 PM
Old 07-02-2015
You could try using file and checking if each file found appears to be a cert store of some kind, then using openssl to actually read it.
This User Gave Thanks to CarloM For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to find how many CPU installed in the servers

We are using HP unix how to find out how many number of CPU's in the system. (7 Replies)
Discussion started by: salaathi
7 Replies

2. Shell Programming and Scripting

How to Find JRE installed in linux machine..?

Hi all, Im new to linux... Im in need to write a shell script to check wthr JRE in linux machine... Wtz de best way to find thru BASH?? Plz help me out to solve this issue... Thanks (3 Replies)
Discussion started by: XivaX
3 Replies

3. Ubuntu

list the softwares installed in Linux

I need list of 3rd party softwares installed in a Unix server (eg: Fedora / RedHat). I know if they are system supported format (like rpm format for fedora/redhat, pkg format for debian/ubuntu etc) we can list them by system specific commands ($ rpm -qa). But how to list the softwares installed... (3 Replies)
Discussion started by: uday123
3 Replies

4. UNIX for Advanced & Expert Users

command to find when Linux OS is installed?

hey , Anyone knows command to find when Linux OS is installed? Date and time? (2 Replies)
Discussion started by: crackthehit007
2 Replies

5. Shell Programming and Scripting

Script to check if SQLLDR has been installed on Unix/Aix servers

How can i check if sqlldr has been installed on my AIX/UNIX mechine? Is there any unix script to check this one out.... (0 Replies)
Discussion started by: msrahman
0 Replies

6. Shell Programming and Scripting

How to find out list of all proccess which are running on unix servers from last two days.

Hi All, I have a requirment, i need to get the list of all the process which are running from last two days on my unix server and also to put this list into an another file. i am giving you a sample example : $ ps -ef UID PID PPID C STIME TTY TIME CMD (1 Reply)
Discussion started by: akshu.agni
1 Replies

7. UNIX for Dummies Questions & Answers

How to check if an application has been installed on a unix/linux box?

hi, guys, now I face a problem. I have developed an application, and when it starts, it shall check if an application has been installed on the running linux/unix. If result is positive, i do something with the application command. just as an example: I want to check if sshd has been... (3 Replies)
Discussion started by: sk1418
3 Replies

8. UNIX for Dummies Questions & Answers

How to check Which Servers are using a particular certificate in Websphere?

Hi Team, I understand that this query does not involve Unix exactly, but can anyone give me pointers as to know which Servers host a particular certificate i.e xyz.intra.com . The Development team has left long back and we have no idea how to ascertain on which servers the certificate is hosted... (1 Reply)
Discussion started by: srkmish
1 Replies

9. Shell Programming and Scripting

Script to find Error: rpmdb open failed on list of servers

Hello all, I have a task to patch red hat servers and some servers have a corrupted rpm database and return the error: Error: rpmdb open failed I know how to fix this when it occurs. What I'm hoping to do is scan a list of servers by IP and report back which server have this error. ... (6 Replies)
Discussion started by: greavette
6 Replies

10. UNIX for Beginners Questions & Answers

Bash find version of an installed application but if none is found set variable to App Not Installed

Hello Forum, I'm issuing a one line bash command to look for the version of an installed application and saving the result to a variable like so: APP=application --version But if the application is not installed I want to return to my variable that the Application is not installed. So I'm... (2 Replies)
Discussion started by: greavette
2 Replies
IO::Socket::SSL::Intercept(3)				User Contributed Perl Documentation			     IO::Socket::SSL::Intercept(3)

NAME
IO::Socket::SSL::Intercept -- SSL interception (man in the middle) SYNOPSIS
use IO::Socket::SSL::Intercept; # create interceptor with proxy certificates my $mitm = IO::Socket::SSL::Intercept->new( proxy_cert_file => 'proxy_cert.pem', proxy_key_file => 'proxy_key.pem', ... ); my $listen = IO::Socket::INET->new( LocalAddr => .., Listen => .. ); while (1) { # TCP accept new client my $client = $listen->accept or next; # SSL connect to server my $server = IO::Socket::SSL->new( PeerAddr => .., SSL_verify_mode => ..., ... ) or die "ssl connect failed: $!,$SSL_ERROR"; # clone server certificate my ($cert,$key) = $mitm->clone_cert( $server->peer_certificate ); # and upgrade client side to SSL with cloned certificate IO::Socket::SSL->start_SSL($client, SSL_server => 1, SSL_cert => $cert, SSL_key => $key ) or die "upgrade failed: $SSL_ERROR"; # now transfer data between $client and $server and analyze # the unencrypted data ... } DESCRIPTION
This module provides functionality to clone certificates and sign them with a proxy certificate, thus making it easy to intercept SSL connections (man in the middle). It also manages a cache of the generated certificates. How Intercepting SSL Works Intercepting SSL connections is useful for analyzing encrypted traffic for security reasons or for testing. It does not break the end-to- end security of SSL, e.g. a properly written client will notice the interception unless you explicitly configure the client to trust your interceptor. Intercepting SSL works the following way: o Create a new CA certificate, which will be used to sign the cloned certificates. This proxy CA certificate should be trusted by the client, or (a properly written client) will throw error messages or deny the connections because it detected a man in the middle attack. Due to the way the interception works there no support for client side certificates is possible. Using openssl such a proxy CA certificate and private key can be created with: openssl genrsa -out proxy_key.pem 1024 openssl req -new -x509 -extensions v3_ca -key proxy_key.pem -out proxy_cert.pem # export as PKCS12 for import into browser openssl pkcs12 -export -in proxy_cert.pem -inkey proxy_key.pem -out proxy_cert.p12 o Configure client to connect to use intercepting proxy or somehow redirect connections from client to the proxy (e.g. packet filter redirects, ARP or DNS spoofing etc). o Accept the TCP connection from the client, e.g. don't do any SSL handshakes with the client yet. o Establish the SSL connection to the server and verify the servers certificate as usually. Then create a new certificate based on the original servers certificate, but signed by your proxy CA. This a the step where IO::Socket::SSL::Intercept helps. o Upgrade the TCP connection to the client to SSL using the cloned certificate from the server. If the client trusts your proxy CA it will accept the upgrade to SSL. o Transfer data between client and server. While the connections to client and server are both encrypted with SSL you will read/write the unencrypted data in your proxy application. METHODS
IO::Socket::SSL::Intercept helps creating the cloned certificate with the following methods: $mitm = IO::Socket::SSL::Intercept->new(%args) This creates a new interceptor object. %args should be proxy_cert X509 | proxy_cert_file filename This is the proxy certificate. It can be either given by an X509 object from Net::SSLeays internal representation, or using a file in PEM format. proxy_key EVP_PKEY | proxy_key_file filename This is the key for the proxy certificate. It can be either given by an EVP_PKEY object from Net::SSLeays internal representation, or using a file in PEM format. The key should not have a passphrase. pubkey EVP_PKEY | pubkey_file filename This optional argument specifies the public key used for the cloned certificate. It can be either given by an EVP_PKEY object from Net::SSLeays internal representation, or using a file in PEM format. If not given it will create a new public key on each call of "new". serial INTEGER This optional argument gives the starting point for the serial numbers of the newly created certificates. Default to 1. cache HASH | SUBROUTINE This optional argument gives a way to cache created certificates, so that they don't get recreated on future accesses to the same host. If the argument ist not given an internal HASH ist used. If the argument is a hash it will store for each generated certificate a hash reference with "cert" and "atime" in the hash, where "atime" is the time of last access (to expire unused entries) and "cert" is the certificate. Please note, that the certificate is in Net::SSLeays internal X509 format and can thus not be simply dumped and restored. The key for the hash is an "ident" either given to "clone_cert" or generated from the original certificate. If the argument is a subroutine it will be called as "$cache->(ident)" to get an existing certificate and with "$cache->(ident,cert)" to cache the newly created certificate. ($clone_cert,$key) = $mitm->clone_cert($original_cert,[ $ident ]) This clones the given certificate. An ident as the key into the cache can be given (like "host:port"), if not it will be created from the properties of the original certificate. It returns the cloned certificate and its key (which is the same for alle created certificates). $string = $mitm->serialize This creates a serialized version of the object (e.g. a string) which can then be used to persistantly store created certificates over restarts of the application. The cache will only be serialized if it is a HASH. To work together with Storable the "STORABLE_freeze" function is defined to call "serialize". $mitm = IO::Socket::SSL::Intercept->unserialize($string) This restores an Intercept object from a serialized string. To work together with Storable the "STORABLE_thaw" function is defined to call "unserialize". AUTHOR
Steffen Ullrich perl v5.18.2 2014-01-07 IO::Socket::SSL::Intercept(3)
All times are GMT -4. The time now is 07:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy