The continuation of the previous article discusses other individual algorithms and their properties. The aim is to provide a material that can be used in case of analysis of used technologies.
EAP (Extensive Authentication Protocol) is a framework, containing a set of authentication mechanisms. It was originally designed for PPP connections (Point to Point Protocol). Today, however, it is also used within Ethernet and WiFi networks (IEEE 802.1x), for authentication within VPN networks, mobile networks (most often EAP-SIM), it can also be used on DSL/ADSL and HDSL connections and can be continued. Its deployment is linked to the RADIUS and DIAMETER protocols (EAP in EAPOL protocol). Standardization is covered by IANA, currently about 50 algorithms are registered.
SASL can use authentication mechanisms provided within EAP, the actual transmitted framework is then encrypted using the AES algorithm. In the vast majority it is probably encryption using CBC or CTR mode, but I did not find any documentation that formalizes the procedure. Nor did I find information about formalization of integrity protection. From the security point of view it would be better to use e.g. GCM or CCM mode (AEAD, i.e. authenticated encryption with associated data) either at the level of SASL EAP-AES128, or at least to use encryption within EAP ensuring both confidentiality and integrity protection. At present it is definitely possible to use EAP-TLS, or EAP-PSK, theoretically it should be possible to use any other EAP mechanisms. The basic version transfers information between client and server, the extended version (EAP-AES128-PLUS) links the communication to another channel.
The actual EAP-AES128 uses a simple way of protecting the communication, where the key material and authentication information are processed in the following way.
Client - Server: Agree on a shared secret or provide the key KServer using asymmetric algorithms outside EAP
Key: k=PBKDF2(KServer, salt, iteration, 128b)
Client→ Server: AES128(k,EAP message)
Server→ Client: AES128(k,EAP message)
In the case of a channel, some form of channel authentication should occur, i.e. either ensuring integrity or inserting information inside the channel in a way that will be accepted within EAP. I have not been able to simulate the above, but perhaps the idea of such evaluation can be realized e.g. by the following procedure, where CCC represents a cryptographic checksum and CSD represents Channel Specific Data (certificates, MAC addresses of both parties and others).
CCC = HMAC(PBKDF2(k, salt, iteration),AES128(k(EAP message)||CSD)
Channel Binding: No for the base version, yes for the PLUS version
Realms: according to EAP algorithm
Crypto: Obsolete (MD4, MD5, SHA-1), rundown (RSA), current ECDH
Partner sides: 2
PQC/QRC: No, current asymmetric cryptography is insufficient.
ZKP: No
Crypt interface support: according to EAP algorithm
Tokenization: according to EAP algorithm
Uniqueness: Yes
Credentials protected: Yes, password, under certain conditions even username
Replay protection: Yes
Protection against Relay: Yes
Hijack protection: Not for the basic version, yes for the PLUS version
Protection against Forge: Yes
MFA support: according to EAP algorithm
Integrity protection: No (not found)
Encryption type: Internal, optionally according to EAP could be used TLS
Authentication by this algorithm requires registration of the public key to the user name on the authenticating server side. Within the SASL, he arranges for a shared secret using Montgormery's representation of Curve25519 (x25519). The agreement on the shared secret proceeds as follows. Curve parameters, private keys and value derivation functions are defined. Based on the inputs, they find a shared secret that allows the client to decrypt the masked value of the connection prompt. If at the end of the calculation the corresponding server connection challenge is proven, the authentication is successful.
Client→ Server: IDClient (0x00h || username)
Server → Client: CServer(PubKeyServer||salt|| (ChallengeSession ⊕ ECDH-X25519-KDF)
Client → Server: CClient(PubKeyServer||salt|| (Masked ChallengeSession ⊕ ECDH-X25519-KDF)
ECDH-X25519-KDF
{
IKM = Hash(SharedSecret || PubKeyClient || PubKeyServer)
PRK = HKDF-Extract(salt, IKM)
OKM = HKDF-Expand(PRK, "ECDH-X25519-CHALLENGE", Lenght=32)
}
Channel Binding: Ne
Realms: No
Cryptoprimitives: current
Partner sides: 2
PQC/QRC: No, current asymmetric cryptography is insufficient.
ZKP: No
Crypt interface support: No
Tokenization: No
Uniqueness: Yes
Credentials protected: No, creation of a shared secret
Replay protection: Yes
Relay protection: Yes
Hijack protection: No
Forge protection: Yes
MFA support: No
Integrity protection: Yes
Encryption type: Internal
The above mechanism requires the generation of a private and public key pair. The public key must be registered on the requested service in relation to the given user. In this case, the private key possession is verified based on the result of the signature prompt provided by the server.
Client → Server: Base64(username)
Server → Client: C
Client: Signature
Client → Server: Signature
Channel Binding: No
Realms: No
Cryptoprimitives: current
Partner sides: 2
PQC/QRC: No, current asymmetric cryptography is insufficient.
ZKP: No
Crypt interface support: Ne
Tokenization: No
Uniqueness: Yes
Credentials protected: No, Creating Shared Secrets
Replay protection: Yes
Protection against Relay: Yes
Hijack protection: No
Protection against Forge: Yes
MFA support: No
Integrity protection: Yes
Encryption type: Internal
These are methods that use external authentication. Examples are SSL/TLS authentication or other methods. These methods must be specified and require checking of the corresponding architecture.
Channel Binding: N/A
Realms: N/A
Crypto-primitives: N/A
Number of pages on authentication: N/A
PQC/QRC: N/A
ZKP: N/A
Crypt interface support: N/A
Tokenization: N/A
Uniqueness: N/A
Credentials protected: N/A
Replay protection: N/A
Relay protection: N/A
Hijack protection: N/A
Forge protection: N/A
MFA support: N/A
Integrity protection: N/A
Encryption type: N/A
The original Novell Modular Authentication Services were available since 1999 together with the Novell NetWare 5 version. These mechanisms were designed for authentication against NDS (NetWare Directory Services), were security-oriented and supported by wide support for authentication methods. In parallel with the introduction of Novell NetWare 6.x and the further development of eDirectory (the original NDS), the SASL interface was supported after 2000. Currently, NMAS technology has transitioned to OpenText with intermediate steps via NetIQ and Microfocus.
NMAs support a wide range of authentication methods, from classical methods based on password authentication, to biometric authentication support and token usage. In the case of password processing, the pre-processing is based on a PBKDF2 algorithm to ensure higher protection of the data. The NMAS_AUTHEN authentication mechanism itself is designed for user authentication within eDirectory and works as follows:
Client → Server: InitMessageClient=MechanismID||ClientData
Server → Client: ChallengeServer= AuthRequestID||NonceServer||AdditionalData
Client → Server: RespMessageClient = AutheRequestID||HMAC(KeyMaterial,NonceServer||AdditionalData)||SessionContext
If the received value of HMAC(KeyMaterial,NonceServer||AdditionalData) matches the calculated value on the server side, LogonStatus=Success, otherwise Failure.
Server → Client: LogonStatus||HMAC(ServerKey,AuthRequestID||HMAC(KeyMaterial,NonceServer||AdditionalData)
Channel Binding: Yes
Realms: No
Crypto-primitives: Obsolete(MD5, SHA-1), current (SHA2)
Number of pages on authentication: 2
PQC/QRC: No
ZKP: No
Crypt interface support: No
Tokenization: No
Uniqueness: Yes
Credentials protected: Password, biometrics, key material
Replay protection: Yes
Relay protection: Yes
Hijack protection: Yes
MFA support: Yes
Integrity protection: Yes
Encryption type: Internal
This method is a follow-up to user authentication (NMAS_AUTHN) and is used to log the user to resources such as network drives, printers, etc.Unlike NMAS_AUTHN, it cannot use multi-factor authentication, but it is able to use basic authentication provided by the previous method. As with NMAS_AUTHN, passwords are pre-processed using PBKDF2.
Server → Client: ChallengeServer= Method||NonceServer
Client → Server: RespMessageClient = Hash(Password||NonceServer)
If the received value of the output corresponds to the unidirectional function on the server side, it is LogonStatus=OK, otherwise Fail.
Server → Client: LogonStatus
Channel Binding: No
Realms: No
Cryptoprimitives: Obsolete(MD5, SHA-1), current (SHA2)
Partner sides: 2
PQC/QRC: No
ZKP: No
Crypt interface support: No
Tokenization: No
Uniqueness: Yes
Credentials protected: Password
Replay protection: Yes
Protection against Relay: Yes
Hijack protection: No
Protection against Forge: Yes
MFA support: No
Integrity protection: Yes
Encryption type: Internal
This is a way to enable logging on to SMB servers (Samba, Windows) for NMAS clients. Unlike common systems on the Microsoft Windows platform, a single password (OTP) is also supported here, which can be useful under certain conditions.
Server → Client: ChallengeServer=Method||NonceServer
At the moment it depends on the choice of method. For Kerberos and NTLM the procedure differs, more details can be found in the analysis of these specific methods.
After authentication is completed, the outputs are compared. If the received value of the output corresponds to the unidirectional function on the server side, it is LogonStatus=OK, otherwise Fail.
Server → Client: LogonStatus
Channel Binding: No
Realms: No
Cryptoprimitives: According to the chosen method, in the case of Kerberos also according to the chosen algorithm.
Number of pages during authentication: 2, in case of Kerberos 5 three pages, in case of dedicated SMB server even four pages.
PQC/QRC: No
ZKP: No
Crypt interface support: No
Tokenization: No, the exception is the use of Kerberos 5
Uniqueness: Yes
Credentials protected: Password
Replay protection: Yes
Protection against Relay: No, only when using the Kerberos protocol
Hijack protection: No, only when using the Kerberos protocol
Protection against Forge: Yes
MFA support: No
Integrity protection: Yes
Encryption type: Internal
The NTLM protocol is used for authentication on networks providing services using the SMB protocol. This is an old protocol, more on this topic can be found in a separate article on the topic (Authentication to SMB shared folders). To some extent it describes the problems encountered by the NMAS-SAMBA-AUTH protocol.
The CServerClient> prompt is a random 8B value.
Client –> Server: Send U=Username
Server –> Client: Send CServer
TagClient = (version, time, CClient, domain name)
LMv2 = HMAC-MD5(HMAC-MD5(MD4(Pass), User Name||Domain Name), CServer, CClient)
NTv2 = HMAC-MD5(HMAC-MD5(MD4(Pass), User Name||Domain Name), CServer, TagClient)
Client –> Server): LMv2 || CClient || NTv2 || TagClient
Channel Binding: No
Realms: No
Cryptorimitives: Obsolete (MD4, MD5)
Number of pages on authentication: 2
PQC/QRC: No
ZKP: No
Crypt interface support: No
Tokenization: No
Uniqueness: Yes
Credentials protected: Password
Protection against Replay: Yes
Protection against Relay: No
Protection against Hijack: No
Protection against Forge: Yes
MFA support: No
Integrity protection: Yes
Encryption type: Internal
The OTP (One Time Password) method consists of generating a one-time password based on the current time or counter change. Generally, the generation is done by a token (e.g. RSA SecureID), but is not a condition. Similar apps for mobile phones currently exist and can be used as an additional factor for logging in. Generally, these methods should not be used alone, the reason may be the leakage of initialization data (seed, otherwise also user secret) and their subsequent misuse.
This algorithm uses two basic methods, either HOTP (RFC 4226) or TOTP (RFC 6238). While HOTP uses the general hash(seed, counter) approach, TOTP uses the hash(seed, the time interval from January 1, 1970). Both of these methods are covered by the OATH. In both cases, it is imperative to synchronize the time of the token and the server verifying this information.
OTP = HMAC(seed, step)
HOTP = RIGHT(HMAC(Seed,Counter),6)
TOTP = RIGHT(HMAC(Seed,Second since 1 Jan 1970/Time Interval,6)
Channel Binding: No
Realms: No
Cryptoprimitives: Obsolete (MD4, MD5, SHA-1), current (SHA2-256, SHA2-512)
Partner sides: 2
PQC/QRC: No
ZKP: No
Crypt interface support: No
Tokenization: No
Uniqueness: Yes
Credentials protected: No
Replay protection: Yes
Protection against Relay: No
Hijack protection: No
Protection against Forge: Yes
MFA support: No, it serves as 2FA and should not be used otherwise
Integrity protection: No
Encryption type: No
The SKEY or S/KEY (Secure Key) algorithm is a method for authenticating identity using a one-time password. It uses recursive compound functions and is usually used as a second factor.
SKEY=HMAC(seed, HMAC(seed, HMAC(seed, ...))
Channel Binding: No
Realms: No
Cryptoprimitives: Obsolete (MD5, SHA-1), current (SHA2-256)
Partner sides: 2
PQC/QRC: No
ZKP: Ne
Crypt interface support: Ne
Tokenization: Ne
Uniqueness: Yes
Credentials protected: No
Replay protection: Yes
Relay protection: No
Hijack protection: No
Forge protection: Yes
MFA support: No, it serves as 2FA and should not be used otherwise
Integrity protection: No
Encryption type: No
This is the original RSA SecureID technology. Originally, these were physical tokens, and over time, software versions were also available. The token or its emulation software based on a secret key (seed) generated a new, usually six-digit password every 30s using simple or compound hash functions.
Over time, several vulnerabilities were found that were caused by synchronization problems, leaks of seeds (generating information) and MITM vulnerabilities. The general working principle is similar to other OTPs:
OTP=Hash(Seed,Counter)
Channel Binding: No
Realms: No
Crypto-primitives: Obsolete (MD5, SHA-1), current (SHA2-256)
Number of pages on authentication: 2
PQC/QRC: No
ZKP: No
Interface support: No
Tokenization: No
Uniqueness: Yes
Replay protection: Yes
Protection against Relay: No
Hijack protection: No
Protection against Forge: Yes
MFA support: No, it serves as 2FA and should not be used otherwise
Integrity protection: No
Encryption type: No
The SCRAM algorithm is designed to provide a secure alternative for password exchange versus pure compound hash functions. In this case
client and server share client password, for hash functions they can use both SHA-1 and SHA2-256, SHA2-384 or SHA2-512. It exists in SCRAM and SCRAM-PLUS versions, where the latter supports Channel Binding technology. This is applied e.g. with GS2 or TLS, where it allows linking authentication with an external method or protocol. In the case of TLS, the corresponding authentication string is encoded using Base64 and the method is added to the authentication message. Possible options for choosing the authentication method are:
tls-server-end-point: uses a certificate hash for authentication (fingerprint, usually based on SHA2-256).
tls-unique: Uses TLS identifier based on messages confirming agreement on keys.
tls-exporter: Based on export mechanism of TLS keys according to RFC 5705.
Key1 = Hash(HMACalgorithm(PBKDF2algorithm(Password, salt, iterations),Password)
Key2 = HMACalgorithm(PBKDF2algorithm(Password, salt, iterations)
Client → Server: Signature=HMACalgorithm(Key1,AuthMessage)
Client → Server: Proof=Key2 ⊕ Signature
Verification on server against received message:
Verify=HMAC(HMAC(PBKDF2(Hash,Password, salt, iterations),Auth Message)
Channel Binding: Not for the basic version, yes for the PLUS version
Realms: No
Cryptoprimitives: Obsolete (SHA-1), current (SHA2)
Partner sides: 2
PQC/QRC: For SHA2-384 and SHA2-512
ZKP: No
Crypt interface support:
Tokenization: No
Uniqueness: Yes
Credentials protected: Password
Replay protection: Yes
Relay protection: No, yes for PLUS version
Hijack protection: No, yes for PLUS version
Forge protection: Yes
MFA support: No
Integrity protection: N/A
Encryption type: Internal
The XOVER algorithm has been in the original designs for SASL since early versions. Although it was also described in the SASLv1 standard to ensure the ability to interact between systems (DIAMETER, EAP, Kerberos, ...), there is no further mention of it. The exception is information about low security, due to the lack of cryptographic support. The algorithm relied on protection on the transport layer and was equivalent to the PLAIN algorithm. The author was probably J. G. Myers, which is also behind the original standard. SXOVER evolved from this algorithm and its extended version with Channel Binding support SXOVER-PLUS was subsequently adopted into the SASLv2 standard.
The current SXOVER-PLUS algorithm is still not standardized, therefore all the information provided describes how it should work. Based on the available information, it should use asymmetric cryptography.
Key exchange using asymmetric cryptography (RSA, DH, ECDH) allows to create a shared symmetric Key.
Server → Client: MessageServer = ("r=" || CServer ||",cb="|| hash(Channel) |",sk="|| PublicKeyServer ||",sid="|| ServerID )
Client → Server: MessageClient = ("c="||hash(Channel) |",r="|| CClient ||",ck="|| PublicKeyClient ||",sig="|| SignatureClient )
Where in the exchange of the above information stands ECDH (Diffie Hellman agreement over elliptic curves NIST P-256 or Curve25519). The following functions are used for generating individual data:
KeyMaterial = HMAC(SharedKey, "SXOVER Key Derivation")
KeyENC = KDF(KeyMaterial, "enc")
KeyMAC = KDF(KeyMaterial, "mac")
SignatureClient = DSA(PrivateKeyClient, ServerID || PublicKeyClient || PublicKeyServer )
Normal equations are used for the actual calculation of the key pair:
PublicKeyServer=gPrivateKeyServer mod p
PublicKeyClient=gPrivateKeyClient mod p
which subsequently allows an agreement over a shared secret:
SharedKeyServer=PublicKeyClientPrivateKeyServer mod p
SharedKeyClient=PublicKeyServerPrivateKeyClient mod p
Channel Binding: Yes
Realms: Yes
Cryptoprimitives: Current
Partner sides: 2 or more
PQC/QRC: No
ZKP: No
Crypt interface support: Ne
Tokenization: Possible, by default not
Uniqueness: Yes
Credentials protected: Yes
Replay protection: Yes
Protection against Relay: Yes
Hijack protection: Yes
Protection against Forge: Yes
MFA support: Not by default, but possible by configuration
Integrity protection: Yes
Encryption type: Internal
This effectively concludes the overview of mechanisms used for authentication between client and server, i.e. for two parties (although some mechanisms support multiple parties). It can be seen that, despite all the developments, some mechanisms today deserve to be further developed or replaced. Their implementation can currently bring serious impacts, so it is necessary to consider their advantages and disadvantages when choosing authentication mechanisms. Further parts will be devoted to mechanisms based on Kerberos protocols, OAUTH protocols and related protocols. The last part will then compare individual libraries, supported algorithms and other interesting software products, usable in authentication.
1. Introductory Provisions
1.1. These General Terms and Conditions are, unless otherwise agreed in writing in the contract, an integral part of all contracts relating to training organised or provided by the trainer, Jan Dušátko, IČ 434 797 66, DIČ 7208253041, with location Pod Harfou 938/58, Praha 9 (next as a „lector“).2. Creation of a contract by signing up for a course
2.1. Application means unilateral action of the client addressed to the trainer through a data box with identification euxesuf, e-mailu with address register@cryptosession.cz or register@cryptosession.info, internet pages cryptosession.cz, cryptosession.info or contact phone +420 602 427 840.3. Termination of the contract by cancellation of the application
3.1. The application may be cancelled by the ordering party via e-mail or via a data mailbox.4. Price and payment terms
4.1. By sending the application, the ordering party accepts the contract price (hereinafter referred to as the participation fee) indicated for the course.5. Training conditions
5.1. The trainer is obliged to inform the client 14 days in advance of the location and time of the training, including the start and end dates of the daily programme.6. Complaints
6.1. If the participant is grossly dissatisfied with the course, the trainer is informed of this information.7. Copyright of the provided materials
7.1. The training materials provided by the trainer in the course of the training meet the characteristics of a copyrighted work in accordance with Czech Act No 121/2000 Coll.8. Liability
8.1. The trainer does not assume responsibility for any shortcomings in the services of any third party that he uses in the training.9. Validity of the Terms
9.1 These General Terms and Conditions shall be valid and effective from 1 October 2024.Consent to the collection and processing of personal data
According to Regulation (EU) No 2016/679 of the European Parliament and of the Council on the protection of individuals with regard to the processing of personal data and on the free movement of such data and repealing Directive 95/46/EC (General Data Protection Regulation, hereinafter referred to as "the Regulation"), the processor xxx (hereinafter referred to as "the Controller") processes personal data. Individual personal data that are part of the processing during specific activities at this web presentation and in the course of trade are also broken down.Information about the records of access to the web presentation
This website does not collect any cookies. The site does not use any analytical scripts of third parties (social networks, cloud providers). For these reasons, an option is also offered for displaying the map in the form of a link, where the primary source is OpenStreet and alternatives then the frequently used Maps of Seznam, a.s., or Google Maps of Google LLC Inc. The use of any of these sources is entirely at the discretion of the users of this site. The administrator is not responsible for the collection of data carried out by these companies, does not provide them with data about users and does not cooperate on the collection of data.Information about contacting the operator of the site
The form for contacting the operator of the site (administrator) contains the following personal data: name, surname, e-mail. These data are intended only for this communication, corresponding to the address of the user and are kept for the time necessary to fulfil the purpose, up to a maximum of one year, unless the user determines otherwise.Information about the order form
In case of an interest in the order form, the form contains more data, i.e. name, surname, e-mail and contact details for the organisation. These data are intended only for this communication, corresponding to the address of the user and are kept for one year, unless the user determines otherwise. In the event that a business relationship is concluded on the basis of this order, only the information required by Czech law on the basis of business relations (company name and address, bank account number, type of course and its price) will continue to be kept by the administrator.Information about the course completion document
Within the course, a course completion document is issued by the processor. This document contains the following data: student's name and surname, the name and date of the course completion and the employer's name. The information is subsequently used for the creation of a linear hash tree (non-modifiable record). This database contains only information about the provided names and company names, which may or may not correspond to reality and is maintained by the processor for possible re-issuance or verification of the document's issuance.Rights of the personal data subject
The customer or visitor of this website has the possibility to request information about the processing of personal data, the right to request access to personal data, or the right to request the correction or deletion of any data held about him. In the case of deletion, this requirement cannot be fulfilled only if it is not data strictly necessary in the course of business. The customer or visitor of this website also has the right to obtain explanations regarding the processing of his personal data if he finds out or believes that the processing is carried out in violation of the protection of his private and personal life or in violation of applicable legislation, and the right to request removal of the resulting situation and to ensure the correction.