Archive for the ‘Security’ Category

Secure Hashing Algorithms SHA-1 and SHA-2

May 15th, 2015 No comments

First implemented by the National Security Agency (NSA) in 1993, the Secure Hashing Algorithm (SHA) is used by certification authorities such as Verisign and Thawte to sign certificates and Certificate Revocation Lists. SHA is used to generate unique hash values from files.

This is the SHA-1 hash fingerprint from the website:

root@raspberrypi:/# echo | openssl s_client -connect 2>/dev/null | openssl x509 -fingerprint -noout
SHA1 Fingerprint=EA:D2:F2:79:18:A0:CD:2B:10:3B:12:01:CF:B1:9E:CC:AF:0F:28:0C

SHA versions:

  • SHA0 Obsoleted
  • SHA1 Currently the most widely implemented
  • SHA2 Stronger than SHA-1 due to longer hash (SHA224, SHA256, SHA384 and SHA512)

As part of their SHA-2 migration plan, Microsoft, Google, and Mozilla have announced that they will stop trusting SHA-1 certificates. Google began phasing out trust in SHA-1 certificates in November 2014. Read more…

Categories: Network Design, Security Tags: ,

Using nMap to Identify Applications

March 3rd, 2015 No comments

nMap uses a list of “default” applications in the nmap services file, used to list services running on scanned open ports.  To see the “real” application execute nMap using the “-sV” option. Read more…

OpenSSL – Self Signed Certificates / Becoming a Root CA

February 10th, 2015 No comments

Following on from the brief personal aide-memoir: OpenSSL – Generate CSR and Test x509 Certificate, this post contains the recipe to generate a self-signed certificate and use this as a CA, to sign other certificates. This is because the term “Self signed certificate” is really incorrect, the proper phrase ought to be “Being your own Certificate Authority”, (or CA)
– You have the “root key”
– And you can “sign” other certificates
Read more…

Categories: Security Tags: ,

Troubleshooting ISAKMP Phase 1 Messages – Part 1

January 22nd, 2015 No comments

This is a must-keep aide-memoir for troubleshooting VPN connections.

IKE (PHASE 1) Messages: Read more…

Categories: CISCO, Security Tags: , ,

Cisco ASA Java 7 update causes ASDM not to Launch

April 14th, 2014 No comments

The recent update to Java has caused problems when the web interface of the Cisco ASDM has a security problem such as an unsigned or expired certificate. Java no longer allows ASDM to launch. The error message is shown as “This application will be blocked in a future Java security update because the JAR file manifest does not contain the Permissions attribute”. This problem is fixed by adding a site exception to Java. Read more…

Categories: CISCO, Security Tags:

SSL/TLS Handshake and Record Data Protocol

March 3rd, 2014 No comments

When an TLS/SSL session (such as HTTPS (default port 443) is established an SSL handshake or exchange of messages occur between the client (initiating the connection) – and a server. (See this post for an explanation of SSL certificates and encoding).

The first set of messages are called the Handshake Protocol after which both client and server enter the Record (or Data) Protocol. The messages exchanged during the Handshake Protocol achieves the following: Read more…

Categories: Security, SSL/TLS Tags: ,

Peer-to-Peer IPSec VPN using PAT

February 28th, 2014 No comments

There may be an occasion to setup a site-to-site VPN with a customer or partner network but due to the risk of overlapping private RFC1918 address space, to use a single public address and Port Address Translation.  This methos uses a single IP address in a NAT (PAT) object.  This example uses simplified NAT available from  ASA software version 8.3+

crypto ipsec transform-set ESP-AES-256-MD5 esp-aes-256 esp-md5-hmac
ccrypto ipsec transform-set ESP-AES-256-MD5 esp-aes-256 esp-md5-hmac Read more…

Categories: CISCO, Security Tags: , ,

Executing ipconfig and other commands on remote machines

February 25th, 2014 No comments

To execute the “ipconfig /all” command on one or more remote machines you can use the psexec utility that is part of pstools, available from Microsoft. The syntax is: pstools \\machine_name command
For example:

C:\Users\dmatthews\Desktop\pstools>psexec \\L00151270 ipconfig /all

To list just the IP version 4 address, pipe the output throught the ‘find’ command:

C:\Users\dmatthews\Desktop\pstools>psexec \\L00151270 ipconfig /all | find “IPv4” Read more…

Categories: Network Management, Security Tags:

Troubleshooting ISAKMP Phase 1 Messages – Part 2

January 24th, 2014 No comments

This post explains the IKE Debug message: “Duplicate first packet detected”

This event is logged when packets do not reach their destination, usually due to network routing problems. The Phase 1 IKE exchange between the tunnel peers fail at MM_WAIT_MSG2

( see: Troubleshooting ISAKMP Phase 1 Messages – Part 1 to understand the IKE Messages further)

1) IKE initator sends MM_SND_MSG1 and goes into MM_WAIT_MSG2 state
2) IKE responder receives MM_SND_MSG1 and sends MM_SND_MSG2 back to the initiator and goes into a MM_WAIT_MSG3 state, expecting MM_SND_MSG3 as the next exchage from the initiator
3) IKE initiator having not received MM_SND_MSG2 from the responder, resends MM_SND_MSG1, resulting in the “Duplicate first packet detected” being logged on the responder. Read more…

Categories: CISCO, Security Tags: , ,

Understanding IPSec VPN

January 16th, 2014 No comments

IPSec involves many component technologies and encryption methods. Yet IPSec’s operation can be broken down into five main steps. The five steps are summarised as follows:

Step 1 Interesting traffic initiates the IPSec process—Traffic is deemed interesting when the IPSec security policy configured in the IPSec peers starts the IKE process.
Step 2 IKE phase one—IKE authenticates IPSec peers and negotiates IKE SAs during this phase, setting up a secure channel for negotiating IPSec SAs in phase two.
Step 3 IKE phase two—IKE negotiates IPSec SA parameters and sets up matching IPSec SAs in the peers.
Step 4 Data transfer—Data is transferred between IPSec peers based on the IPSec parameters and keys stored in the SA database.
Step 5 IPSec tunnel termination—IPSec SAs terminate through deletion or by timing out.

A crypto map—is a Cisco IOS software configuration entity that performs two primary functions. First, it selects data flows that need security processing. Second, it defines the policy for these flows and the crypto peer that traffic needs to go to. A crypto map is applied to an interface. The concept of a crypto map was introduced in classic crypto but was expanded for IPsec.  This aide-memoir pulls together items from to provide a useful recipe and refresher. Read more…

Categories: CISCO, Security, SSL/TLS Tags: