Issue 130: GitHub’s new token format, MindAPI, Kiterunner

The Latest API Security News, Vulnerabilities and Best Practices
Issue: #130
GitHub’s new token format, MindAPI, Kiterunner
It’s a rare week with no high-profile API breaches in the news, so we can actually take our time to focus on the positives, like the best practices around API tokens and new tools for API reconnaissance and penetration testing.
Best practices: API token format
 

API keys can be or look like pretty much anything. And like any other means of authentication, they are very sensitive if they leak out and fall into the wrong hands.

Designing API tokens that follow unique patterns is one of the security best practices gaining traction lately. This enables tools that can detect these API keys, for example, in code repositories or logs, and can thus prevent leaks.

In our issue 109, we covered the approach that Dynatrace took with their tokens. Now, GitHub has published a blog post on the changes to the token format on their side:

  1. Unique prefix clearly separated by an underscore: All tokens now start with three letters, gh for “GitHub” and the 3rd letter to identify the kind of token:
    • ghp_ for GitHub personal access tokens
    • gho_ for OAuth access tokens
    • ghu_ for GitHub user-to-server tokens
    • ghs_ for GitHub server-to-server tokens
    • ghr_ for refresh tokens
  2. Increased entropy in the random section of the token string
  3. Checksum characters to separate false positive hits from actual tokens

This format allows easily to locate tokens with grep and other tools, with reliable results and not too much additional noise.

Penetration testing: API mindmap
 

Mindmaps can be a great way to visually organize information, especially when it comes to large concepts, and API security is no different here.

David Sopas has put together a project, MindAPI, to bring “order to API hacking chaos.” The project collects best practices, tips and tricks, and tools for:

  • API reconnaissance: how to discover undocumented APIs
  • Vulnerability testing for each of the risks on the OWASP API Security Top 10 list

To make this big bundle of information easier to approach, Sopas has put together an interactive mindmap that shows how things go together.

MindAPI_preview

And if you got interested, you can also contribute to the project.

Penetration testing: GraphQL
 

GraphQL is still small fry in the world of APIs, but it continues to pique pentesters’ interest. Which is no wonder considering that Facebook heavily relies on GraphQL implementation, and quite a few other companies are also starting to expose GraphQL endpoints.

If you need an introduction to GraphQL penetration testing, check out this recent blog post by YesWeHack. They cover:

  • Introspection
  • Fuzzing (when introspection is off)
  • Query flaws
  • Mutation flaws
  • SQL injections
  • Debug information
  • Batching attacks
  • Tools
    • GraphQL Voyager
    • InQL

We have previously featured GraphQL pentesting and resources in our issues 12512111611496, and 82.

Tools: Kiterunner
 

Speaking of API reconnaissance, Kiterunner is a new tool for it that is worth checking out.

Traditionally, API recon is done simply by using large dictionary files of possible paths and path parameters and iterating through them.

Shubham Shah decided to optimize this process. He noticed that many APIs get generated by frameworks, such as Flask, Rails, and Express, rather than designed from scratch by humans. Since frameworks are not exactly random in the way they work, he decided to build a recon model based on a large sample of API contracts.

Shah collected about 67,500 OpenAPI files available on the internet, like in APIs.guru and GitHub, and used them to pull together a model for framework-generated APIs. For more details on the research process, see his detailed blog post.

Kiterunner is an open-source tool. You can check out its repo here.

And if you want to see a demo, here’s a video on it by Katie Paxton-Fear:

Kiterunner_video_preview

 

 
 
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, Inc.   95 Third Street  2nd Floor  San Francisco  CA   94103   United States
You received this email because you are subscribed to API Security News from 42Crunch, Inc..

Update your email preferences to choose the types of emails you receive or Unsubscribe from all future emails  
 
 

Older messages

Issue 129: Facebook and Clubhouse profiles scraped through APIs, Forrester’s “State of Application Security, 2021”📑

Monday, April 19, 2021

Hi, today we look at the huge API data leaks at Facebook and Clubhouse, Forrester's APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #129 Facebook and

Issue 128: API flaws at VMware and GitLab, URL parameters and SSRF, webinar on recent breaches 🎬

Thursday, April 8, 2021

Hi, this week we look at a couple of recent API flaws, the dangers of URL parameters & APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #128 API flaws at

Issue 127: Hidden OAuth attack vectors, Methodology for BOLA/IDOR 🗝️

Thursday, April 1, 2021

Hi, this week we look at how a login API got breached for an code execution APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #127 Hidden OAuth attack vectors,

Issue 126: F5 iControl REST API under attack, Regexploit, Ford’s API security talk recording 🚗

Thursday, March 25, 2021

Hi, today we look at a couple of recent API vulnerabilities, a new regex analysis tool APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #126 F5 iControl REST API

Issue 125: iPhone call recorder API flaw, Burp and OpenAPI, GraphQL pentesting, FAPI 💱

Thursday, March 18, 2021

Hi, today we look at the just released FAPI 1.0, GraphQL pentesting, OpenAPI in Burp, APIsecurity.io The Latest API Security News, Vulnerabilities and Best Practices Issue: #125 iPhone call recorder

You Might Also Like

Quick question

Sunday, April 28, 2024

I want to learn how I can better serve you ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

Kotlin Weekly #404 (NOT FOUND)

Sunday, April 28, 2024

ISSUE #404 28st of April 2024 Announcements Kotlin Multiplatform State of the Art Survey 2024 Help to shape and understand the Kotlin Multiplatform Ecosystem! It takes 4 minutes to fill this survey.

📲 Why Is It Called Bluetooth? — Check Out This AI Text to Song Generator

Sunday, April 28, 2024

Also: What to Know About Emulating Games on iPhone, and More! How-To Geek Logo April 28, 2024 📩 Get expert reviews, the hottest deals, how-to's, breaking news, and more delivered directly to your

Daily Coding Problem: Problem #1425 [Easy]

Sunday, April 28, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Microsoft. Suppose an arithmetic expression is given as a binary tree. Each leaf is an

PD#571 Software Design Principles I Learned the Hard Way

Sunday, April 28, 2024

If there's two sources of truth, one is probably wrong. And yes, please repeat yourself. ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

When Procrastination is Productive & Ghost integrating with ActivityPub

Sunday, April 28, 2024

Automattic, Texts, and Beeper join forces to build world's best inbox, Reflect launches its iOS app, how to start small rituals, and a lot more in this week's issue of Creativerly. Creativerly

C#503 Building pipelines with System.Threading.Channels

Sunday, April 28, 2024

Concurrent programming challenges can be effectively addressed using channels ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

RD#453 Get your codebase ready for React 19

Sunday, April 28, 2024

Is your app ready for what's coming up in React 19's release ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌ ‌

☁️ Azure Weekly #464 - 28th April 2024

Sunday, April 28, 2024

Azure Weekly Newsletter Issue #464 powered by endjin Welcome to issue 464 of the Azure Weekly Newsletter. In AI we have a good mix of high-level and deep-dive technical articles. Next-Gen Customer

Tesla profits tumble, Fisker flatlines, and California cities battle for control of AVs

Sunday, April 28, 2024

Plus, an up-close look at the all-electric Mercedes G-Wagen and more View this email online in your browser By Kirsten Korosec Sunday, April 28, 2024 Welcome back to TechCrunch Mobility — your central