Wow ! @Cloudflare introduces API Shield to protect your APIs

blog.cloudflare.com/introducing-ap…

How does it do ?

By adding mTLS for the API endpoints and enforcing schema validation in JSON / gRPC payloads in API POST requests

Will it really secure / help secure APIs ?

[thread] 1/n
Reading the article, Cloudflare claims to "secure" your APIs with the help of mTLS.

To simply put, mTLS is when both entities (server and client) validate each other's SSL cert and make sure its signed by common trusted Root / Intermediate CA.

2/n
mTLS requires your own PKI and things get tricky when you want to revoke a issued cert, manage access to root CA, etc. But in this case Cloudflare manages for you.

3/n
How can mTLS help ?

It can prevent DoS / DDoS to your application to some extent. It can be used to authenticate but have not really seen it at scale.

4/n
Cloudflare describes schema validation for JSON (beta) and gRPC (in roadmap).

This delegates the responsibility of checking the schema of the POST body to Cloudflare. Also Cloudflare with its WAF technology, "might" (in my opinion) sanitise / reject known malicious payload.

5/n
What this feature doesn't do ?

- 100% API security
- Logical bugs and misconfigurations
- Other API bugs due to requests with post body in different encoding

6/n
For devs, using this feature adds a layer of dependency to your app (PKI going down/compromised).

The mTLS part restricts folks who blindly DoS/fuzz the API endpoints. But once they get the mTLS cert & private key (using say mobile app reverse engineering), nothing stops them.

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Chandrapal Badshah

Chandrapal Badshah Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @bnchandrapal

17 Apr
How we monitor secrets committed in our self hosted @gitlab instance in real time ?

(Twitter thread which summarises multiple experiments)

#ProductSecurity #gitlab #security
Use Pre-commit / Pre-receive / Post-receive git hooks ?

Pre-commit : scan for secrets before commit. Prevents committing secrets by devs

Problem: requires access to dev laptops (privacy issue?). Hard to manage regexes in their laptop. Harder in a company hiring lots of devs
Pre-receive : scan for secrets before commits are saved in Gitlab. If secrets found reject. Easy to manage server controls.

Problem: If a person commits secret to code, server rejects push. The person requires (advanced) git skills to remove secret from git history
Read 15 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!