Issue 90: Twitter API data security incident, skimmers and Google Analytics API 💳

The Latest API Security News, Vulnerabilities and Best Practices
Issue: #90
Twitter API data security incident, Google Analytics APIs used with skimmers
This week, we take a look at how Twitter API erroneously allowed browsers to cache sensitive data, and how skimmers have found a way to use Google Analytics APIs to get their hands on credit card data. Plus, there is a live demo of API hacking, as well as a new book on API security.
Vulnerability: Twitter
 

HTTP headers can play an important role in API security, like the case with Twitter API shows. The header  cache-control:no-store  had not been set on the API, which meant that the data that this API returned to the web page was stored in the browser cache.

Unfortunately, this particular API was for Twitter’s advertisers’ portal ads.twitter.com and their analytics.twitter.com site, and the returned data did include sensitive billing information. The flaw could not be exploited remotely, but someone with a physical access to the computer a user used could gain access to the information, meaning that Twitter still had to classify this as a Data Security Incident.

Twitter has since fixed this vulnerability.

Attack vector: Google Analytics APIs
 

Attackers use skimmers on e-commerce sites to inject their code (for example, JavaScript) to intercept credit card information on purchases. This is the first leg of the journey: attackers still need a way to ship that stolen data to their servers, and lots of sites are using Content Security Policy (CSP) to prevent that. With CSP, site owners effectively prohibit any API calls outside of their own. Sounds good, right?

Unfortunately, as Amir Shaked from PerimeterX demonstrates, CSP is not really compatible with Google Analytics APIs. Google Analytics is widely used on websites to gather statistics and data for business decisions, and thus its domain is typically placed in the allowlist of the CSP.

In a way, this opens a backdoor (or open window, as Shaked puts it) to CSP. All attackers need to do to get that stolen data from the skimmer is to just call Google Analytics APIs and ship the data to their Google Analytics account. The domain of this call is identical to any other Google Analytics call, only the tag parameter is different. This it not enough for CSP to use as a discriminator, so the call sails through no problem.

This is a cautionary tale to keep in mind whenever a multitenant 3rd-party API is in use.

Book: API Security in Action
 

Neil Madden has just finished his book “API Security in Action”, published by Manning. This was one of the books in their early access program (MEAP) that allowed readers to get it chapter by chapter as released by the author. Now you can get full content, and pre-order your hard-copy if you want.

Here’s the quick abstract of the book:

“API Security in Action shows you how to create secure web APIs that you can confidently share with your business partners and expose for public usage. Security expert Neil Madden takes you under the hood of modern API security concepts, including token-based authentication for flexible multi-user security, bootstrapping a secure environment in a Kubernetes microservices architecture, and using lightweight cryptography to secure an IoT device.”

Madden goes into great detail about different authentication mechanisms used in REST APIs and also covers modern API-based architectures, including microservice and IoT deployments.

As a cherry on top, you can get 42% off the list price when you use the coupon code 42Crunch40 at checkout!

Video: API Hacking Demo
 

Live, practical demos are always exciting. Katie Paxton-Fear has posted a recording of her live API Hacking Demo that is definitely worth checking out.

In her demo, she uses Burp to discover APIs on a server, enumerates paths, discovers IDOR/BOLA vulnerabilities, takes over an account, and concludes by escalating her privileges.

To provide practical examples, Paxton-Fear also shows what these bugs look like in her sample application code.

Live API Hacking tutorial video thumbnail

 

 
dmitry_apisec-1  

Dmitry Sotnikov

APIsecurity.io

 
Thanks for reading.

That's it for today. If you have any feedback or stories to share, simply reply to this email.

Please forward the newsletter to your friends and colleagues who might benefit from it.

 
42Crunch Ltd   71-75 Shelton Street  Covent Garden  London  Greater London   WC2H 9JQ   United Kingdom
You received this email because you are subscribed to API Security News from 42Crunch Ltd.

Update your to choose the types of emails you receive or   
 
 

Older messages

Issue 89: Starbucks API flaw exposes almost 100 million customer accounts ☕

Thursday, June 25, 2020

Hi, today we look at the recent API flaws at Starbucks & Drupal, BBVI APICheck tools, APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #89 Starbucks API flaw

Issue 88: JWT pentesting, API discovery, the present and future of OpenAPI 🔭

Thursday, June 18, 2020

Hi, this week we have a new JWT security toolkit, video on API discovery, new ebook and APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #88 JWT pentesting, API

Issue 87: Vulnerabilities in Digilocker, Facebook, VMware Cloud Director 🌩️

Thursday, June 11, 2020

Hi, this week we have a video on API recon and details of 3 recent API vulnerabilities APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #87 Vulnerabilities in

Issue 86: Vulnerabilities in Sign in with Apple 📱, Qatar’s COVID19 app, GitLab

Thursday, June 4, 2020

Hi, this week we look at the 3 recent API vulnerabilities and a new Burp plugin APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #86 Vulnerabilities in Sign in

Issue 85: Vulnerability in Google Cloud Deployment Manager ⛅, a pentester’s guide to OAuth 🌩️

Thursday, May 28, 2020

Hi, this week we have a Gartner report, API Security Q&A panel, OAuth pentesting guide APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #85 Vulnerability in

You Might Also Like

JSter #234 - Libraries and more

Monday, January 6, 2025

Happy new year JavaScripters! New year, new challenges. I have a small favor to ask you. I have a MSc student researching how AI is used for web development. To help out, fill his query (5-15 mins).

WP Weekly 225 - Wins - New Launches, 2025 Predictions, Year 2024 Recap

Monday, January 6, 2025

Read on Website WP Weekly 225 / Wins All the 2024 stuff is behind us; hoping everyone is a winner going forward in this amazing WordPress community. Let's start 2025 with WordPress goodness upfront

SRE Weekly Issue #458

Monday, January 6, 2025

View on sreweekly.com A message from our sponsor, incident.io: Ever wonder how Netflix handles incidents at their scale? With incident.io, they've built a process that's smooth, scalable, and

OpenAI proposes a new corporate structure - Sync #500

Sunday, January 5, 2025

Plus: Nvidia's next move; the state of AI hardware startups; "AI factories" for war; BYD enters humanoid robot race; ChatGPT Search vs. Google Search; and more! ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏ ͏

🔋 You Need a Super-Fast USB Car Charger — First-Party vs. Third-Party Cookies

Sunday, January 5, 2025

Also: How I Use Shortcuts and Apple Numbers to Track My Time How-To Geek Logo January 5, 2025 Did You Know Theodore Roosevelt was the first US President to ride in an automobile while in office.

RD#487 Instance Hook Pattern

Sunday, January 5, 2025

co-located logic and controlled API ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

PD#607 Systems Ideas that Sound Good But Almost Never Work

Sunday, January 5, 2025

"let's just..." scenarios ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏ ‌ ͏

Android Weekly #656 🤖

Sunday, January 5, 2025

View in web browser 656 January 5th, 2025 Articles & Tutorials Sponsored Sick of your mobile apps crashing? Simon Grimm will show you how to fix them with less guesswork. Join Sentry's workshop

Daily Coding Problem: Problem #1659 [Easy]

Sunday, January 5, 2025

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by WhatsApp. Given an array of integers out of order, determine the bounds of the smallest

C#538 Unit Testing Clean Architecture Use Cases

Sunday, January 5, 2025

Battle-tested approach to unit testing ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌