Security Experts:

Critical Signature Forgery Flaw Found in Mozilla NSS Crypto Library

Two independent research teams have discovered that a serious vulnerability in Mozilla's Network Security Services (NSS) cryptographic library can be exploited for signature forgery attacks.

Malicious actors can leverage the flaw to forge RSA signatures and set up fake websites that impersonate the sites of legitimate organizations. Many Internet users know that they can recognize fake websites by checking to see if they're protected by a SSL/TLS certificate. However, by forging the certificates, cybercriminals can set up phishing and malware-serving sites that look just like the legitimate ones, researchers warned.

"Users on a compromised network could be directed to sites using a fraudulent certificate and mistake them for legitimate sites. This could deceive them into revealing personal information such as usernames and passwords. It may also deceive users into downloading malware if they believe it’s coming from a trusted site," Mozilla's Daniel Veditz wrote in a blog post on Wednesday.

The vulnerability was discovered independently by researchers at Intel Security Advanced Threat Research Team and by Antoine Delignat-Lavaud, a member of the Prosecco team at INRIA Paris-Rocquencourt. The flaw is actually a variant of a signature forgery attack described by Daniel Bleichenbacher back in 2006.

"This attack exploits a vulnerability in the parsing of ASN.1 encoded messages during signature verification. ASN.1 messages are made up of various parts that are encoded using BER (Basic Encoding Rules) and/or DER (Distinguished Encoding Rules). This attack exploits the fact that the length of a field in BER encoding can be made to use many bytes of data. In vulnerable implementations, these bytes are then skipped during parsing. This condition enables the attack," explained Michael Fey, executive VP, CTO and general manager of corporate products at McAfee, which is now part of Intel Security.

Because the vulnerability involves BER encoding Intel Security has dubbed it "BERserk."

The CERT Coordination Center at Carnegie Mellon University (CERT/CC) has also published an advisory for this vulnerability, which has been assigned the CVE identifier CVE-2014-1568.

The NSS crypto library is used in Mozilla products such as Firefox, Thunderbird and SeaMonkey. However, CERT/CC has pointed out that it's also utilized in Google Chrome, Chrome OS, and several Linux distributions and packages. "It is also possible that other cryptographic libraries may have similar vulnerabilities," CERT/CC wrote in its advisory.

Fortunately, Mozilla has released updates for its products to address the issue. Google has also updated Chrome and Chrome OS to prevent potential attackers from exploiting the vulnerability. The companies have advised customers to install the latest versions as soon as possible.

view counter
Eduard Kovacs (@EduardKovacs) is a contributing editor at SecurityWeek. He worked as a high school IT teacher for two years before starting a career in journalism as Softpedia’s security news reporter. Eduard holds a bachelor’s degree in industrial informatics and a master’s degree in computer techniques applied in electrical engineering.