Introducing the In-the-Wild Series
https://googleprojectzero.blogspot.com/2021/01/introducing-in-wild-series.html [googleprojectzero.blogspot.com]
2021-01-13 07:29
tags:
admin
android
browser
exploit
malware
programming
security
series
windows
windows
Leaking silhouettes of cross-origin images
https://blog.mozilla.org/attack-and-defense/2021/01/11/leaking-silhouettes-of-cross-origin-images/ [blog.mozilla.org]
2021-01-13 06:07
tags:
browser
exploit
graphics
security
sidechannel
turtles
web
This is a writeup of a vulnerability I found in Chromium and Firefox that could allow a malicious page to read some parts of an image located on an origin it is not supposed to be able to access. Although technically interesting, it is quite limited in scope—I am not aware of any major websites it could’ve been used against. As of November 17th, 2020, the vulnerability has been fixed in the most recent versions of both browsers.
The time that it takes CanvasRenderingContext2D.drawImage to draw a pixel depends on whether it is fully transparent, opaque, or semi-transparent. By timing a bunch of calls to drawImage, we can reliably infer the transparency of each pixel in a cross-origin image, which is enough to, for example, read text on a transparent background, like this:
source: HN
Stealing Your Private YouTube Videos, One Frame at a Time
https://bugs.xdavidhu.me/google/2021/01/11/stealing-your-private-videos-one-frame-at-a-time/ [bugs.xdavidhu.me]
2021-01-11 19:53
tags:
auth
cloud
investigation
security
web
I quickly Googled “base64 to image”, and pasted the base64 into the first decoder I found, and it displayed a thumbnail from the target Private video! It worked! I have found a working IDOR (Insecure Direct Object Reference) bug, where I could get a frame from any private video on YouTube!
source: HN
Sandboxing and Workload Isolation
https://fly.io/blog/sandboxing-and-workload-isolation/ [fly.io]
2021-01-10 00:19
tags:
defense
development
security
unix
virtualization
Workload isolation makes it harder for a vulnerability in one service to compromise every other part of the platform. It has a long history going back to 1990s qmail, and we generally agree that it’s a good, useful thing.
From chroot to privsep to docker to firecracker.
Data Security on Mobile Devices: Current State of the Art, Open Problems, and Proposed Solutions
http://securephones.io/ [securephones.io]
2020-12-24 21:38
tags:
android
iphone
opsec
paper
security
tech
In this work we attempt a full accounting of the current and historical status of smartphone security measures. We focus on several of the most popular device types, and present a complete description of both the available security mechanisms in these devices, as well as a summary of the known public information on the state-of-the-art in bypass techniques for each. Our goal is to provide a single periodically updated guide that serves to detail the public state of data security in modern smartphones.
source: green
Bouncy Castle crypto authentication bypass vulnerability revealed
https://www.bleepingcomputer.com/news/security/bouncy-castle-crypto-authentication-bypass-vulnerability-revealed/ [www.bleepingcomputer.com]
2020-12-20 01:19
tags:
auth
hash
java
security
That is, the Bcrypt.doCheckPassword() function responsible for performing a byte-by-byte password hash match has an erroneous logic in place.
“The code checks for an index of characters from 0 to 59 inclusive, rather than checking that characters at positions from 0 to 59 match,” reads the report published by Synopsys.
https://www.synopsys.com/blogs/software-security/cve-2020-28052-bouncy-castle/
How to Abuse and Fix Authenticated Encryption Without Key Commitment
https://eprint.iacr.org/2020/1456 [eprint.iacr.org]
2020-12-13 06:03
tags:
crypto
format
paper
security
Authenticated encryption (AE) is used in a wide variety of applications, potentially in settings for which it was not originally designed. Recent research tries to understand what happens when AE is not used as prescribed by its designers. A question given relatively little attention is whether an AE scheme guarantees “key commitment’’: ciphertext should decrypt to a valid plaintext only under the key that was used to generate the ciphertext. As key commitment is not part of AE’s design goal, AE schemes in general do not satisfy it. Nevertheless, one would not expect this seemingly obscure property to have much impact on the security of actual products. In reality, however, products do rely on key commitment. We discuss three recent applications where missing key commitment is exploitable in practice. We provide proof-of-concept attacks via a tool that constructs AES-GCM ciphertext which can be decrypted to two plaintexts valid under a wide variety of file formats, such as PDF, Windows executables, and DICOM. Finally we discuss two solutions to add key commitment to AE schemes which have not been analyzed in the literature: one is a generic approach that adds an explicit key commitment scheme to the AE scheme, and the other is a simple fix which works for AE schemes like AES-GCM and ChaCha20Poly1305, but requires separate analysis for each scheme.
source: white
Baby Sharks - Injecting small order points to threshold EdDSA
https://medium.com/zengo/baby-sharks-a3b9ceb4efe0 [medium.com]
2020-12-11 07:03
tags:
blockchain
crypto
math
security
We showcase one example of how an attacker can inject a low order subgroup group element in threshold EdDSA protocol secure against malicious adversaries, bypassing existing protections.
source: green
PLATYPUS With Great Power comes Great Leakage
https://platypusattack.com/ [platypusattack.com]
2020-12-11 06:55
tags:
cpu
energy
exploit
paper
security
sidechannel
With classical power side-channel attacks, an adversary typically attaches an oscilloscope to monitor the energy consumption of a device. Since Intel Sandy Bridge CPUs, the Intel Running Average Power Limit (RAPL) interface allows monitoring and controlling the power consumption of the CPU and DRAM in software. Hence, the CPU basically comes with its own power meter. With the current implementation of the Linux driver, every unprivileged user has access to its measurements.
Using PLATYPUS, we demonstrate that we can observe variations in the power consumption to distinguish different instructions and different Hamming weights of operands and memory loads, allowing inference of loaded values. PLATYPUS can further infer intra-cacheline control flow of applications, break KASLR, leak AES-NI keys from Intel SGX enclaves and the Linux kernel, and establish a timing-independent covert channel.
With SGX, Intel released a security feature to create isolated environments, so-called enclaves, that are secure even if the operating system is compromised. In our work, we combine PLATYPUS with precise execution control of SGX-Step. As a result, we overcome the hurdle of the limited measuring capabilities of Intel RAPL by repeatedly executing single instructions inside the SGX enclave. Using this technique, we recover RSA keys processed by mbed TLS from an SGX enclave.
source: trivium
Ok Google: please publish your DKIM secret keys
https://blog.cryptographyengineering.com/2020/11/16/ok-google-please-publish-your-dkim-secret-keys/ [blog.cryptographyengineering.com]
2020-12-11 06:27
tags:
admin
crypto
email
opsec
security
This post is about the situation with Domain Keys Identified Mail (DKIM), a harmless little spam protocol that has somehow become a monster. My request is simple and can be summarized as follows: Dear Google: would you mind rotating and publishing your DKIM secret keys on a periodic basis? This would make the entire Internet quite a bit more secure, by removing a strong incentive for criminals to steal and leak emails. The fix would cost you basically nothing, and would remove a powerful tool from hands of thieves.
source: green
This Tiny WiFi Camera Owns Kwikset SmartKey (LockTech LTKSD)
https://www.youtube.com/watch?v=DGdsIrAjp3k [www.youtube.com]
2020-12-08 21:47
tags:
hardware
opsec
security
tech
video
Open a padlock (or probably any keyed lock) by taking a picture of the sliders inside, then cutting a key.
The video shows this in real time and is five minutes long. Open sesame!
PAM Bypass: when null(is not)ok
https://linderud.dev/blog/pam-bypass-when-nullis-notok/ [linderud.dev]
2020-11-25 01:55
tags:
auth
exploit
linux
security
turtles
The commit attempts to avoid a timing attack against PAM. Some attacker can know valid user names by timing how quickly PAM returns an error, so the fix is to use an existing user in the system we always validate against to ensure a consistent timing. But which user is always present on a Linux system? root!
The code does not check if root has any valid passwords set. An invalid user would fail, loop over to root and try validate. root has no password. It’s blank. We have nullok set. And we have pam_permit.so. The invalid user is authenticated. We have enough information to do a quick POC.
1 + 1 = 3.
source: L
NAT Slipstreaming
https://samy.pl/slipstream/ [samy.pl]
2020-11-01 19:51
tags:
browser
exploit
networking
security
turtles
web
NAT Slipstreaming allows an attacker to remotely access any TCP/UDP service bound to a victim machine, bypassing the victim’s NAT/firewall (arbitrary firewall pinhole control), just by the victim visiting a website.
This is neat, although you have to dig in a bit to learn it requires the NAT gateway to do some fancy SIP proxying.
source: L
Enter the Vault: Authentication Issues in HashiCorp Vault
https://googleprojectzero.blogspot.com/2020/10/enter-the-vault-auth-issues-hashicorp-vault.html [googleprojectzero.blogspot.com]
2020-10-11 21:11
tags:
auth
cloud
exploit
security
This is tediously complex, IMO (as someone who doesn’t use the service in question), but the conclusion is worth considering.
In my experience, tricky vulnerabilities like this often exist where developers have to interact with external systems and services. A strong developer might be able to reason about all security boundaries, requirements and pitfalls of their own software, but it becomes very difficult once a complex external service comes into play. Modern cloud IAM solutions are powerful and often more secure than comparable on-premise solutions, but they come with their own security pitfalls and a high implementation complexity. As more and more companies move to the big cloud providers, familiarity with these technology stacks will become a key skill for security engineers and researchers and it is safe to assume that there will be a lot of similar issues in the next few years.
Finally, both discussed vulnerabilities demonstrate how difficult it is to write secure software. Even with memory-safe languages, strong cryptography primitives, static analysis and large fuzzing infrastructure, some issues can only be discovered by manual code review and an attacker mindset.
Reconstruct Instead of Validating
https://buttondown.email/cryptography-dispatches/archive/cryptography-dispatches-reconstruct-instead-of/ [buttondown.email]
2020-10-09 03:33
tags:
development
format
security
turtles
What I want to focus on is (2), because it’s a lesson we learned the hard way in cryptography and didn’t transfer effectively to the rest of security engineering.
One of my favorite cryptographic attacks is the Bleichenbacher‘06 signature forgery. I wrote up how it works when I found it in python-rsa, so again go read that, but here’s a tl;dr. When you verify an RSA PKCS#1 v1.5 signature, you get a ASN.1 DER structure wrapping the message hash that you need to check. If you don’t parse it strictly, for example by allowing extra fields or trailing bytes, an attacker can fake the signature. This was exploited countless times.
The lesson we learned was that instead of parsing the ASN.1 DER to extract the message hash, we should reconstruct the ASN.1 DER we’d expect to see, and then simply compare it byte-by-byte.
The same technique would have saved Vault.
Rust programming language exploit mitigations
http://rcvalle.blog/2020/09/16/rust-lang-exploit-mitigations/ [rcvalle.blog]
2020-10-02 21:28
tags:
compiler
defense
development
rust
security
This section documents the exploit mitigations applicable to the Rust compiler when building programs for the Linux operating system on the AMD64 architecture and equivalent.
source: L
Ethereum is a Dark Forest
https://medium.com/@danrobinson/ethereum-is-a-dark-forest-ecc5f0505dff [medium.com]
2020-08-28 20:22
tags:
blockchain
cloud
finance
security
In the Ethereum mempool, these apex predators take the form of “arbitrage bots.” Arbitrage bots monitor pending transactions and attempt to exploit profitable opportunities created by them. No white hat knows more about these bots than Phil Daian, the smart contract researcher who, along with his colleagues, wrote the Flash Boys 2.0 paper and coined the term “miner extractable value” (MEV).
Phil once told me about a cosmic horror that he called a “generalized frontrunner.” Arbitrage bots typically look for specific types of transactions in the mempool (such a DEX trade or an oracle update) and try to frontrun them according to a predetermined algorithm. Generalized frontrunners look for any transaction that they could profitably frontrun by copying it and replacing addresses with their own. They can even execute the transaction and copy profitable internal transactions generated by its execution trace.
source: HN
Rolling your own crypto gone wrong: A look at a .NET Branca implementation
https://brycx.github.io/2020/08/22/a-look-at-a-branca-implementation.html [brycx.github.io]
2020-08-24 17:43
tags:
crypto
development
security
This is a pretty good example of code that probably looks decent to a casual inspection, and seems to call functions with the right names, etc., but it’s pretty bad.
source: L
Never Run ‘python’ In Your Downloads Folder
https://glyph.twistedmatrix.com/2020/08/never-run-python-in-your-downloads-folder.html [glyph.twistedmatrix.com]
2020-08-24 16:29
tags:
admin
python
security
sh
turtles
Python can execute code. Make sure it executes only the code you want it to.
Not exclusive to python either.
source: L
How to contact Google SRE: Dropping a shell in cloud SQL
https://offensi.com/2020/08/18/how-to-contact-google-sre-dropping-a-shell-in-cloud-sql/ [offensi.com]
2020-08-20 16:29
tags:
cloud
database
exploit
programming
security
sql
Google Cloud SQL is a fully managed relational database service. Customers can deploy a SQL, PostgreSQL or MySQL server which is secured, monitored and updated by Google. More demanding users can easily scale, replicate or configure high-availability. By doing so users can focus on working with the database, instead of dealing with all the previously mentioned complex tasks. Cloud SQL databases are accessible by using the applicable command line utilities or from any application hosted around the world. This write-up covers vulnerabilities that we have discovered in the MySQL versions 5.6 and 5.7 of Cloud SQL.
source: L