Chapter 10
Carnivore and Magic Lantern
(more of a keylogger than an attack apllication) were created by the US government for law enforcement use in cracking codes.
Cross-Certification
A certificate authority can be set up to trust a CA in a completely different PKI through this. This allows both PKI CAs to validate certificates generated from either side.
FREAK (Factoring Attack on RSA-Export Keys)
A man in the middle attack that forces a downgrade of an RSA key to a weaker length. The attacker forces the use of a weaker encryption key length, enabling successful brute force attacks.
Brute Force
An attempt to try every possible combination against a target until successful. (can be applied to cracking encryption schemes)
Products/Applications that provide FDE
BitLocker (Microsoft), McAfee Endpoint Encryption (with administrative dashboard and controls), Symantec Drive Encryption, and Gilisoft Full Disk Encryption.
Stream Ciphers
Bits of data are encrypted as a continuous stream. Readable bits in their regular pattern are fed into the cipher and are encrypted one at a time, usually by an XOR operation. Work at a very high rate of speed.
Heartbleed CVE notation
CVE-2014-0160
POODLE aka Poodlebleed CVE notation
CVE-2014-3566
FDE
Can be software or hardware based, and it can use network based authentication (Active Directory for example) and/or local authentication sources (a local account or locally cached from a network source).
Software based FDE
Can provide central management, making key management and recovery actions much easier.
Encryption type attack applications
Carnivore, Magic Lantern, L0phtcrack, John the Ripper, PGPcrack, CryptTool, Cryptobench, Jipher
examples of symmetric algorithms
DES, 3DES, AES, IDEA, Twofish, Blowfish, RC
Data at rest (DAR)
Data that is in a stored state and not currently accessible.
Tools to hide messages in audio files
DeepSound and MP3Stego
Examples of Assymetric Encryption
Diffie-Hellman, Elliptic Curve Cryptosystem, El Gamal, RSA
Mitigation for POODLE
Don't use SSL 3.0 at all. There are old clients and servers that just don't support TLS 1.0 and above. therefore, you can implement TLS_FALLBACK_SCSV to prevent the attack. Implement anti-POODLE record splitting.
Tools to encrypt files and folders/drives
EFS, VeraCrypt, AxCrypt, GNU Privacy Guard to using PKI within the system-such as Entrust Products
Heartbleed
Exploits a small feature in open SSL. Open SSL uses a heart beat during an open session to verify that data was received correctly, and it does this by echoing data back to the other system. In heartbleed, an attacker sends a single byte of data while telling the server it sent 64Kb of data. The server will then send back 64Kb of data-64Kb of random data from its memory.
Mobile Tools to create and view hashes
Hash Droid
Tools to create and view hashes
HashCalc, MD5 Calculator, HashMyFiles
Exploits for SSL communications
Heartbleed and POODLE
Validation Authority (VA)
In many PKI systems an outside entity is used to validate certificates-usually done via Online Certificate Status Protocol (OCSP).
Examples of Hash Algorithms
MD5, SHA-1, SHA-2, SHA-3
Encrypted File Systems (EFS)
Microsoft builds into it's operating systems now for files, folders, and drives needing encryption.
Formula for calculating how many key pairs you will need
N(N-1)/2 - where N is the number of nodes in the network.
Private Keys
Not shared
Tools to hide messages in Video files
OmniHide Pro, Masker
PGP vs S/MIME
PGP can be used to encrypt not only email messages but also files and entire drives.
Allows for the creation and dissemation of digital certificates
PKI
PGP
Pretty good privacy was created way back in 1991 and is used for signing, compression, and encrypting and decrypting emails, files, directories, and even whole disk partitions, mainly in an effort to increase the security of email communications. PGP follows the OpenPGP standard (RFC 4880) encrypting and decrypting data. PGP is known as a hybrid cryptosystem, because it uses features of conventional and public key cryptography.
Proves authenticity through the digital signature
Private key
Encrypted with public key
Private key decrypts it
Basic template multiple providers of encryption frameworks use
Public Key Infrastructure
Steganography Tools
QuickStego, gifshiffle, Steganography Studio, SNOW, OpenStego.
Open SSL versions vulnerable to Heartbleed
SSL versions 1.0.1 and 1.0.1f
Methods for Communicating securely
Secure Shell, Secure Sockets Layer, Transport Layer Security, Internet Protocol Security, PGP
DROWN (Decrypting RSA with Obselete and Weakened eNcryption) attack
Serious vulnerability that affects HTTPS and other services that rely on SSL and TLS (essential cryptographic protocols for internet security). Allows attackers to break the encryption and read or steal sensitive communications, including passwords, credit card numbers, trade secrets, and financial data.
Self-Signed Certificate (ECC)
Signed by the same entity whose identity it certifies (that is, signed using the entities own private key).
Bulk encryption needs
Symmetric algorithms and techniques
Chosen plain-text attack
The attacker encrypts multiple plain text copies himself in order to gain the key.
Adaptive chosen plain-text attack
The attacker makes a series of interactive queries, choosing subsequent plain text based on the information from the previous encryptions. The attacker sends a bunch of cipher text to be decrypted and then uses the results of the decryptions to select different, closely related cipher texts. The idea is to gradually glean more and more information about the full target cipher text or about the key itself.
Cipher-text-only attack
The hacker gains copies of several messages encrypted in the same way (with the same algorithm). statistical analysis can then be used to reveal, eventually, repeating code, which can be used to decode messages later.
Known plain-text attack
The hacker has both plain text and corresponding cipher text messages- the more the better. The plain text copies are scanned for repeatable sequences, which are then compared to the cipher text versions. Over time, and with effort, this can be used to decipher the key.
Optional Fields
These fields include Issuer Unique Identifier, Subject Alternative Name, and Extensions.
Valid From and Valid To
These fields show the dates the certificate is good through.
Secure Sockets Layer (SSL)
This encrypts data at the transport layer, and above, for secure communication across the Internet. It uses RSA encryption and digital certificates and can be used with a wide variety of upper layer protocols. Uses a six step process for securing a channel, it is being largely replaced by Transport Layer Security (TLS).
SHA-2
This hash algorithm actually holds four separate hash functions that produce outputs of 224, 256, 384, and 512 bits. Although designed as a replacement to SHA-1, it is still not as widely used.
SHA-3
This hash algorithm uses something called "sponge construction" where data is "absorbed" into the sponge (by XOR-ing the initial bits of the state) and the "sqeezed" out (output blocks are read and alternated with state transformations).
Internet Protocol Security (IPsec)
This is a network layer tunneling protocol that can be used in 2 modes: tunnel (entire IP packet encrypted) and transport (data payload encrypted). IPSec is capable of carrying nearly any application. The authentication header (AH) protocol verifies an IP packets integrity and determines the validity of its source: it provides authentication and integrity, but not confidentiality. Encapsulating security payload (ESP) encrypts each packet (in transport mode, the data is encrypted but the headers are not encrypted; in tunnel mode, the entire packet, including the headers, is encrypted).
RSA
This is an algorithm that achieves strong encryption through the use of two large prime numbers. Factoring these numbers creates key sizes up to 4096 bits. Can be used for encryption and digital signatures and is the modern de facto standard.
MD5 (Message Digest algorithm)
This produces a 128 bit hash value output, expressed as a 32 digit hexadecimal. Created by Ronald rivest, was originally popular for ensuring file integrity. However, serious flaws in the algorithm and the advancement of other hashes have resulted in this hash being rendered obsolete. is still used for file verification on downloads and to store passwords.
Algorithm ID (or Signature Algorithm)
This shows the algorithm that was used to create the digital signature.
Elliptic Curve Cryptosystem (ECC)
This uses points on an elliptical curve, in conjunction with logarithmic problems, for encryption and signatures. It uses less processing power than other methods, making it a good choice for mobile devices.
Transport Layer Security (TLS)
Using an RSA algorithm of 1024 and 2048 bits, is the successor to SSL. The handshake portion (TLS handshake protocol) allows both the client and the server to authenticate to each other, and TLS record protocol provides the secured communication channel.
Applications and organizations affected by Heartbleed
VMWare products, Yahoo, FileMaker, Cisco routers, HP server applications, SourceForge, and GitHub
Contents of a Digital Certificate
Version, Serial Number, Subject, Algorithm ID, Issuer, Valid From and Valid To, Key Usage, Subjects Public Key, Optional Fields.
John the Ripper
a Unix/Linux tool for the same purpose, aimed at cracking password hashes.
IDEA (International Data Encryption Algorithm)
a block cipher that uses a 128 bit key and was also designed to replace DES. originally used in Pretty Good Privacy (PGP) 2.0, was patented and used mainly in Europe.
3DES (aka triple DES)
a block cipher that uses a 168 bit key. Can use up to three keys in a multiple encryption method. it's much more effective than DES but is much slower.
DES
a block cipher that uses a 56 bit key (with 8 bits reserved for parity). Because of the small key size, this encryption standard became quickly outdated and is not considered a very secure encryption algorithm.
AES (Advanced Encryption Standard)
a block cipher that uses a key length of 128, 192, or 256 bits, and effectively replaces DES. it's much faster than DES or 3DES.
Twofish
a block cipher that uses a key size up to 256 bits.
Boot-n-root Attack
a bootable USB you can plug in to, boot off of, and then wreak havoc on the desktop system.
Salt
a collection of random bits that are used as a key in addition to the hashing algorithm. Because the bits, and length, are random, a good one makes a collision attack difficult to pull off. Every time a bit is added to the salt it adds a power of 2 to the complexity of the number of computation involved to derive the outcome. Necessity in protecting password files.
Subjects Public Key
a copy of this is included in the digital certificate for obvious purposes.
TLS_FALLBACK_SCSV
a fake cipher suite advertised in the client hello message, which starts the SSL/TLS handshake.
Blowfish
a fast block cipher, largely replaced by AES, using a 64 bit block size and a key from 32 to 448 bits. Is considered public domain.
Digital Signature Algorithm (DSA)
a federal information processing standard that was proposed by the National Institute of Standard and Technology (NIST) for use in their Digital Signature Standard (DSS).
what are key generation, distribution, and revocation best handled within?
a framework, often referred to as PKI
Hashing Algorithm
a one way mathematical function that takes an input and typically produces a fixed length string (usually a number), or hash, based on the arrangement of the data bits in the input. Sole purpose is to provide a means to verify the integrity of a piece of data. There is not a way for a hash to be reverse engineered.
A classic (and the most common) asymmetric encryption scheme
a public and a private key, at a minimum, have to be created, managed, distributed, stored, and, finally, revoked.
Secure Shell (SSH)
a secured version of telnet. uses TCP port 22, by default, and relies on public key cryptography for its encryption. originally designed for remote sessions into Unix machines for command execution, it can be used as a tunneling protocol. SSH2 is the successor. it's more secure, efficient, and portable, and it includes a built in encrypted version of FTP (SFTP).
Public Key Infrastructure (PKI)
a structure designed to verify and authenticate the identity of individuals within the enterprise taking part in data exchange. It consists of hardware, software, and policies that create, manage, store, distribute, and revoke keys and digital certificates. Not all systems are identical.
Concerns addressed with assymetric encryption
addresses concerns over key distribution and management, as well as scalability. Also addresses the nonrepudiation problem.
GAK (Government Access to Keys)
aka key escrow. software companies provide their encryption keys (Or at least enough of the key so that the remainder can be cracked) to the government, and the government promises to use them only when it really needs to (that is when a court issues a warrent).
POODLE (Padding Oracle On Downgraded Legacy Encryption)
aka poodlebleed per ECCouncil. The transport layer security (TLS) protocol had largely replaced SSL for secure communication on the Internet, but many browsers would still revert to SSL 3.0 when a TLS connection was unavailable. They did this because TLS clients performed a handshake effort, design to degrade service until something acceptable was found.
Hierarichal Trust System
also has a CA at the top (which is known as the root CA) but makes use of one or more registration authorities (subordinate CAs) underneath it to issue and manage certificates.
Symmetric Encryption
also know as single key or shared key; one key is used both to encrypt and decrypt the data.
Digital Signature
an algorithmic output that is designed to ensure the authenticity (and integrity) of the sender- basically a hash algorithm.
XOR operations
at the core of a lot of computing. requires two inputs. in encryption, this would be the data bits and the key bits. each bit is fed into the operation-one from the data, the next from the key-and then XOR makes a determination. If the bits match the output is 0; if they don't, it's a 1.
Encryption Cracking
attack may be successful, attempts to crack encrypting take a long time. the stronger the encryption method and the longer the key used in th algorithm, the longer the attack will take to be successful. Not a good security practice to assign a key and never change it.
Collision or Collision Attack
attack or effort used against hashing algorithms. Two or more files create the same output, which is not supposed to happen. When a hacker can create a second file that produces the same hash value output as the original, he may be able to pass of the fake file as the original.
Man in the middle attack
attacker has positioned himself between two communicating entities. Once there, he can launch a variety of attacks (interference, fake keys, replay, etc.)
plain text
can be used to define text data in ASCII format. In cryptography, refers to anything not encrypted-whether text or not.
How can you tell a text file is a stego file?
character positions are key (look for text patterns, unusual blank spaces, and language anomalies).
Uncrackable Encryption
combine a long key with a commitment to changing it within a reasonable time period. An algorithm using at least a 256 bit key cannot be cracked (see AES).
Hashing passwords
common uses for a hash algorithm. The original password is hashed; then the hash value is sent to the server (or the resource doing the authentication), where it is stored. When the user logs in, the password is hashed with the same algorithm and key; if the two match, then the user is allowed access. Can be subject to a collision attack.
What does encryption provide?
confidentiality, integrity (hashes that ensure the message hasnt been changed), and nonrepudiation.
Assymetric Encryption Advantages
confidentiality, nonrepudiation, solves the problems of key distribution and scalability.
Symmetric Encryption Advantages
considered fast and strong, a great choice for bulk encryption because of its speed. Does a great job with confidentiality.
Public Key (aka encryption key)
could be sent anywhere, to anyone.
Block Ciphers
data bits are split up into blocks and fed into the cipher. each block of data (commonly 64 bits at a time) is then encrypted with the key and algorithm. Use methods such as substitution and transportation in their algorithms and are considered simpler, and slower, than stream ciphers.
X.509 Standard
defines what should and should not be in a digital certificate. Because of the standard, any system complying with this can exchange and use digital certificates to establish authenticity.
Trust Model
describes how entities within an enterprise deal with keys, signature, and certificates for one another. Uses within this system trust each other based on certificates they receive from other users on the same system.
PGPcrack
designed to go after PGP encrypted systems
SHA-1
developed by the NSA, produces a 160 bit value output and was required by law for use in US government applications.In late, 2005, however, serious flaws became apparent and the us government began recommending the replacement with SHA-2 after the year 2010.
Diffie-Hellman
developed for use as a key exchange protocol, is used in Secure Sockets Layer (SSL) and IPSec encryption. It can be vulnerable to man in the middle attacks, however, if the use of digital signatures is waived.
Legitimate uses for steganography
digital watermarks (used by some companies to identify their applications).
Fallback to SSL 3.0
disabled In chrome 40
Mozilla Firefox
disabled SSL 3.0 in Firefox 34 ESR 31.3 and added TLS_FALLBACK_SCSV in Firefox 35.
RC (Rivest Cipher)
encompasses several versions from RC2 through RC6. A block cipher that uses a variable key length up to 2040 bits. RC6, the latest version, uses 128 bit blocks and 4 bit working registers, whereas RC5 uses variable block sizes (32, 64, or 128) and 2 bit working registers.
Hashes
even though they are one way functions, a sufficient collision attack may break older versions (MD5).
Rainbow Tables
every word, phrase, and compilation of characters ran through a hash algorithm and stored for later use. Can compare hashed file to table (may aid in collision attacks)
Signed Certificates
generally indicates a CA is involved and the signature validating the identity of the entity is confirmed via an external source-in some cases a validation authority (VA). Can be trusted assuming the CA chain is validated and not corrupted, it's good everywhere. Anything accessible to (Or using) external connectivity will require this.
Single Authority System
has a CA at the top that creates and issues certificates. Users trust each other based on the CA.
Algorithmic transformation technique in image steganography
hide data in the mathematical functions used in image compression. The image appears normal, except it's file size is much bigger.
Examples of steganography
hiding the message in the text of a written correspondence, changing bits within a huge media file to carry a message, if you had an image file you could change the least meaningful bit in every byte to represent data-anyone looking at it would hardly notice the slight change of color or loss of sharpness.
Most secure system
hierarichal trust system-because users can track the certificate back to the root to ensure authenticity without a single point of failure.
Assymetric Encryption
in this key pair system, both are generated together, with one key used to encrypt a message and the other to decrypt it. What one key encrypts the other key decrypts.
S/MIME (Secure/Multipurpose Internet Mail Extensions)
is a standard for public key encryption and signing of MIME data (when email is the topic).
algorithm
is a step by step method of solving a problem
Replay Attack
is most often performed within the context of A man in the middle attack. The hacker repeats a portion of a cryptographic exchange in hopes of fooling the system into setting up a communications channel. The attacker doesn't really have to know the actual data (such as the password) being exchanged; he just has to get the timing right in copying and then replaying the bit stream. Session tokens can be used in the communications process to combat this attack.
Digital Certificate
isn't really involved with encryption at all; it is, instead, a measure by which entities on a network can provide identification. Is an electronic file that is used to verify a user's identity, providing nonrepudiation throughout the system.
Side Channel Attack
it is a physical attack that monitors environmental factors (like power consumption, timing, and delay) on the Cryptosystem itself.
Assymetric Encryption Weaknesses
it's performance (slower than symmetric, especially on bulk encryption), and processing power (usually requiring a much longer key length, it's suitable for smaller amounts of data).
Private Key (aka decryption key)
kept secured on the system
Symmetric Key Encryption Weaknesses
key distribution and management in this type of system are difficult, if sent over the network someone can steal it. Number of keys needed is a problem because everyone has to have a specific key from each partner they want to communicate with.
Disadvantages of Symmetric Encryption
key distribution is an issue because the delivery of the key for the secured channel must be done offline. Also, scalability is a concern because the larger the network gets, the number of keys that must be generated increases greatly. Does nothing to provide for nonrepudiation.
Cryptography and XOR ciphers
key length is of utmost importance. If the key chose is actually smaller than the data, the cipher will be vulnerable to frequency attacks. Because the key will be used repeatedly in the process, it's very frequency makes guessing it easier.
Crytography Attacks
known plain text attack, chosen plain text attack, adaptive chosen plain text attack, cipher text only attack, replay attack, and chosen cipher attack
Three main techniques in image steganography
least significant bit insertion, masking and filtering, and algorithmic transformation.
encryption algorithms
mathematical formulas used to encrypt and decrypt data (highly specialized and sometimes very complex). Are also known as ciphers.
encryption algorithms or ciphers
mathematical procedures used to encrypt and decrypt data
nonrepudiation
means by which a recipient can ensure the identity of the sender and neither party can deny having sent or received the message.
Interference attack
means you can derive information from the cipher text without actually decoding it.
Pulling off the Heartbleed exploit
metasploit auxiliary module openssl_heartbleed. module loads, some parameters are set, initiated by typing exploit, and the return of the 64Kb of memory the server provides.
Tools and methods to look for and prevent steganographic file usage
most antivirus programs and spyware tools actively look for steganography.
nmap -d -script ssl-heartbleed -script-args vulns.showall -sV [host]
nmap command to search for the vulnerability: the return will say "state:NOT VULNERABLE" if you're good to go.
El Gamal
not based on prime number factoring, this method uses the solving of discrete logarithm problems for encryption and digital signatures.
Self Signed certificate
one created internally and never intended to be used in any other situation or circumstance (used in most enterprise level networks). Save money and complexity, and easy to put into place. any external access to them is a definite no no.
Steganography
practice of concealing a message inside another medium (such as another file or image) in such a way that only the sender or recipient even know if it's existence, let alone the manner in which to decipher it.
Difference between encrypting an entire disk with a pre boot authenticating system and individual volume, folder, and file encryption
pre boot authenticating system changes the MBR
DAR vendors
protect the data on mobile devices from loss or theft while it is in a resting state. usually this entails Full Disk Encryption (FDE).
Benefit to WDE
protection against boot-n-root attack
Encrypted with private key
public key decrypts it
How can you tell an audio or video file is a stego file?
requires some statistical analysis and specific tools.
Cryptography
securing communication between two or more parties
Public Keys
shared
plain text
something you can read
cipher text
something you can't read
FIPS 186-2
specifies that something called the Digital Signature Algorithm (DSA) be used in the generation and verification of digital signatures.
anti-POODLE record splitting
splits records into several parts, ensuring none of them can be attacked. May cause compatibility issues due to problems in server side implementation.
Two methods encryption algorithms use to encrypt data
stream ciphers and block ciphers
Google Chrome Browser and Google Servers
support TLS_FALLBACK_SCSV with SSL 3.0 being removed completely.
Two main methods by which keys can be used and shared
symmetric and asymmetric
Overall Cryptography Process
take plain text data, apply a cryptographic method, and turn it into cipher text-so long as there is some provision to allow you to bring the cipher text back to plain text.
Audio Steganography
takes advantage of frequencies the human ear can't pick up, not to mention hiding data in a variety of other methods, like phase encoding and tone insertion.
Chosen Cipher Attack
the attacker chooses a particular cipher text message and attempts to discern the key through comparative analysis with multiple keys and a plain text version. RSA is particularly vulnerable to this attack.
what validates the entire PKI system?
the fact that the CA signs it digitally
Key to a successful encryption system
the infrastructure in place to create and manage the encryption keys.
Common among all PKI systems
the initial request for keys and certs is done in person.
Cryptography
the science or study of protecting information, whether in transit or at rest, by using techniques to render the information unusable to anyone who does not possess the means to decrypt it.
Cyptanalysis
the study and methods used to crack encrypted communications.
Hashes
they're used for integrity (any deviation in the value, no matter how small, indicates the original file has been corrupted).
Version
this identifies the certificate format. Over time, the actual format of the certificate has changed slightly, allowing for different entries. The most common in use is 1.
Subject
this is whoever or whatever is being identified by the certificate.
Key Usage
this shows for what purpose the certificate was created.
Issuer
this shows the entity that verifies the authenticity of the certificate. Is the one who creates the certificates.
Mitigation for DROWN
turn off support for the offending Encryption (in this case, SSLv2). Server operators need to ensure that their private keys are not used anywhere with server software that allows SSLv2 connections. This includes web servers, SMTP servers, IMAP and POP servers, and any other software that supports SSL/TLS.
Protection against collision attacks and the use of rainbow tables
use a salt
L0phtcrack
used mainly on Microsoft Windows against SAM password files, aimed at cracking password hashes.
certificate revocation list (CRL)
used to track which certificates have problems and which have been revoked.
Serial Number
used to uniquely identify the certificate
SSL 3.0
uses RC4. Has a design flaw that allows the padding data at the end of a block cipher to be changed so that the encryption cipher becomes less secure each time it is passed. Defined as RC4 biases in OpenSSLs paper on the subject. An attacker need only make 256 SSL 3.0 request to reveal one byte of encrypted messages.
Masking and filtering technique in image steganography
usually accomplished on grayscale images. Masking hides the data in much the same way as a watermark on a document; however, it's accomplished by modifying the luminescence of image parts.
Full Disk Encryption (FDE)
where pre boot authentication (usually an account and password) is necessary to unlock the drive before the system can even boot up- once it's up and running protection of the data falls to other measures.
reverse heartbleed
where severs are able to perform the exact same thing in reverse, stealing data from clients
How can you tell an image file is a stego file?
will be larger in size, and may show some weird color palette faults.
Encryption algorithms dependent on a separate key
without the key, the algorithm itself should be useless in trying to decode the data.