SlideShare a Scribd company logo
1 of 35
Download to read offline
API Days workshop
API Gateway &
Identity Providers,
a Match Made in
Microservices
Heaven
Yaara Letz
Partner Consulting &&/|| Engineer @Tyk
London, UK
www.linkedin.com/in/yaara-letz-3439ba4
About me
Tyk in 1 Minute
API Management Platform:
• API Gateway
• Control Plane
• Developer Portal
• Flexible: SaaS and On-Premises
By engineers for engineers:
• Microservice architecture
• Integration over vendor lock-in
• Go Lang - fast and lean
Tyk
Today’s talk
• Set the scene: Privacy, data breaches and keyless APIs
• The Problem: How to prevent those when using APIs in microservices architecture.
• Action: Use API gateway to ease the pain
• Demo: Securing my API with Tyk and external Identity Provider
• Q & A
Tyk
Privacy, regulation and Data breaches
Privacy - Personal information is collected
GDPR - General Data Protection Regulation - May 2018
Data breaches – You are liable for the data you hold.
Invest in security today to avoid to avoid reputational and
financial Consequences tomorrow
Tyk
Story time –
Domino's Pizza are keeping your data safe
Tyk
How does it apply to APIs?
2018, many organisations had their APIs exposed to data breach and cyber attacks:
👺 Facebook
- What: Cambridge Analytica harvested 50M users’ profiles for political adverts
- How: Graph API of early version of FB’s API
👺 Uber
- What: Compromised sensitive information of 57m users
- How: Hackers found login credentials on an insecure private gist
👺 Tinder
- What1: Undocumented APIs leaked location in 2013
- What2: Exposed users’ photos and activities
- How: Didn’t use HTTPS end-to-end and poor encryption HTTPS
https://www.helpnetsecurity.com/2017/11/22/uber-data-breach/
https://qz.com/106731/tinder-exposed-users-locations/
https://www.wired.com/story/tinder-lack-of-encryption-lets-strangers-spy-on-swipes/
Tyk
APIs are vulnerable too
Gartner, 2017:
By 2022, Data breaches in enterprises will be mainly in web
applications space and by API abuses attacks
Tyk
Let’s talk about Keyless APIs
1. What is a keyless API?
2. When do people use keyless APIs
3. Is it dangerous? Why?
4. How can we address it?
Tyk
Keyless APIs - unofficial definition
• An unprotected API – open for everyone, public
• No need for key/token/password/identifying details
• Its consumer is unidentified and unlimited
Tyk
When do I use keyless APIs
• For internal usage (hint: trust model L bad decision)
• When I want everyone to access my APIs
• When I want barriers-free access to drive adoption of my API
• When I don’t need to know who is accessing my APIs
• When my APIs provide access to an already freely available data
• When I “only” serve data
So what is the danger?
Tyk
What is the danger?
è The temptation:
You have static website…
…just for reading…
…only does a simple HTTP GETs…
…I don’t need to know who’s using my APIs
è Implicit trust
è This is an opportunity for an attacker to
exploit!
Tyk
What are the risks of keyless APIs?
• Back door - Give the world direct access to your code
• In case of a bug -
Expose your services to malicious access
Worse – expose your clients data ( remember Gartner prediction?)
• No rate limit and quota –
Degrade API performance for everyone – noisy neighbour (bad code, load test)
Results in an overloaded API service and increased cloud consumption
• No identity
You can’t identify the abuser and block his API calls.
Lost business opportunity - can’t to use clients’ details to build your business and it’s hard
to segment your API traffic by users
So what should I do?
Tyk
Even Google stopped using keyless API (June 2018)
{
"error_message" : "Keyless access to Google
Maps Platform is deprecated. Please use an
API key with all
your API calls to avoid
service interruption.
For
details please
refer to http://g.co/dev/no-account",
"status" : "OVER_QUERY_LIMIT"
}
Tyk
How Do I Drive Innovation While Still Protecting Keyless APIs?
Tyk
à With An API gateway
Tyk
Front Keyless APIs with an API gateway (or implement yourself) :
if (you do):
• Leave only necessary endpoints
• Set a global rate limiting and throttling
• Use common headers for user identification, rate-
limiting, quota capping, tracing and analytics
(User-Agent, X-Real-IP, Authorization)
then (you will):
• Avoid overloading of your API
• Avoid cloud consumption
• Gather analytics and ability to do user
segmentation
• Identify and block abusers
else – next slide
Tyk
Let’s summaries the risks we are facing with APIs
1. Data breaches on poorly protected APIs (MITM)
2. Cyber attacks on poorly designed flows (Session Cookie Tampering, DDoS)
3. Leaked information via poorly designed APIs (TLS, API Parameter Tampering)
4. Degrade in all of my services and spike of my cloud consumption (Noisy neighbour)
5. Abusing the trust model (User’s ID can be compromised)
Tyk
The goal – basically prevention
• Prevent the next data breach
• Avoid data leaking (which can happen in every new release)
• Protect your APIs from abuse by innocent or not so innocent caller
• Keep metrices on the users in case of a breach or attack
Security approach should be a balance between exposing web APIs in approachable way
to ensure adoption with control to prevent abuse or attacks.
Tyk
à An API gateway can help – Duh #2
Tyk
How Can Tyk Help?
1. Authentication + Authorization – to identify and approve the caller
2. Throttle, Quota and Rate Limit users, apps and APIs - protect from abuse, brute force
attack and noisy neighbours
3. Policies - to enforce tiered, metered and granular user access per path and method
4. Metrices – analytics per key, per API, or per request
5. lots more - versioning, clean leaking data, json validation, help SQL injection, backend
protection (mTLS, Certificate pinning, RSA sign RSA request to upstream)…
Tyk
Apply AuthN and
AuthZ To
Microservices
Tyk
Why Microservices – A Quick Touchbase
• Reduced coordination
• Fast onboarding new joiners
• Flexibility in development and deployment
• Compatible with modern approaches
• Reduced risk with no single point of failure
Tyk
AuthN and AuthZ Definitions
• Authentication is the process through which a client proves their identity to the server
• Authorisation is the server controlling what actions a specific identified client is able to
perform
Tyk
Options For Adding AuthN and AuthZ To Microservice
1. Internally within each microservice
2. Externally by a gateway
3. Combination of internal and external
4. Wait-and-see
Tyk
Microservices - internal approach
Pros:
• Gives fined grained control
• Self-reliance
Cons:
• More development effort
• Complicates the code
• Larger microservices
• Repeated code - Risk of Copy/paste code
• Will probably not cover all aspects or new ones
• Not visible to security team
Gartner suggest – “Don not code API security policies into the APIs”
Tyk
Microservices - external approach
Pros:
• Centrally handled
• Enforce AuthN and AuthZ
• Less development effort
• Smaller microservices
• Flexible with configuration
Cons:
• Vulnerability – circumvent the gateway à sort with mTLS and network set up
• Less control – when needs DB to decide AuthZ à use Tyk as TCP proxy
Tyk
Microservices - combined approach
Pros:
• Relieves burden of
authentication
• Gives control of authorisation
(for complex decisions)
Cons:
• More development effort
• Larger microservices
• Repeated code
Tyk
Choosing the right AuthN + AuthZ Methods
✔ Regulations industry
✔ Consistency
✔ Scenarios
✔ Users’ directory
Tyk
Identity providers
Central hub for all of your identity needs:
- Authentication – standards and protocols
- Single Sign-On (SSO) - in the intranet and internet
- Multi-factor authentication (MFA) - emails OTP, SMS, USB key etc.
- Federation identity and multiple user’s identities
Tyk
Forth approach – With An Identity Providers
You don’t have to on-board all the existing keys just
let a the IdP to manage the user identity for you
Tyk
Using a
proprietary
signed generic
JWT
Demo 2: Securing an API
Tyk
Conclusion
There is no single best solution
I’d favour the “external” approach –
ü Use an API gateway to offload and simplify and centralise AuthN and AuthZ trivial flows
ü Use an IdP to offload identity management and maintenance from your code and your
data stores
ü You can focus on your core business
Mental note for future talk J – discuss AuthN/AuthZ requirement and setup for service
mesh "east-west" traffic and not via the Edge API gateway.
Tyk
Tyk
Q & A
Yaara Letz @yaarale
twitter.com/tyk_io
github.com/TykTechnologies
facebook.com/Tyk.API.Management

More Related Content

What's hot

I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
Apigee | Google Cloud
 
API Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
API Design Best Practices & Tech Talk : API Craft Meetup @ ApigeeAPI Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
API Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
Anil Sagar
 

What's hot (20)

apidays LIVE New York 2021 - Top 10 API security threats every API team shoul...
apidays LIVE New York 2021 - Top 10 API security threats every API team shoul...apidays LIVE New York 2021 - Top 10 API security threats every API team shoul...
apidays LIVE New York 2021 - Top 10 API security threats every API team shoul...
 
I Love APIs 2015: Advanced Security Extensions in Apigee Edge - HMAC and http...
I Love APIs 2015: Advanced Security Extensions in Apigee Edge - HMAC and http...I Love APIs 2015: Advanced Security Extensions in Apigee Edge - HMAC and http...
I Love APIs 2015: Advanced Security Extensions in Apigee Edge - HMAC and http...
 
APIs: The New Security Layer
APIs: The New Security LayerAPIs: The New Security Layer
APIs: The New Security Layer
 
How to Build an Effective API Security Strategy
How to Build an Effective API Security StrategyHow to Build an Effective API Security Strategy
How to Build an Effective API Security Strategy
 
apidays LIVE India - 10 steps to secure your API by Pabitra Kumar Sahoo, Qual...
apidays LIVE India - 10 steps to secure your API by Pabitra Kumar Sahoo, Qual...apidays LIVE India - 10 steps to secure your API by Pabitra Kumar Sahoo, Qual...
apidays LIVE India - 10 steps to secure your API by Pabitra Kumar Sahoo, Qual...
 
Serverless Functions and Machine Learning: Putting the AI in APIs
Serverless Functions and Machine Learning: Putting the AI in APIsServerless Functions and Machine Learning: Putting the AI in APIs
Serverless Functions and Machine Learning: Putting the AI in APIs
 
apidays Paris 2019 - How Do Async APIs Survive in a Rest World? by Luca Ferra...
apidays Paris 2019 - How Do Async APIs Survive in a Rest World? by Luca Ferra...apidays Paris 2019 - How Do Async APIs Survive in a Rest World? by Luca Ferra...
apidays Paris 2019 - How Do Async APIs Survive in a Rest World? by Luca Ferra...
 
Adapt or Die Sydney - API Security
Adapt or Die Sydney - API SecurityAdapt or Die Sydney - API Security
Adapt or Die Sydney - API Security
 
What are your APIs Worth?
What are your APIs Worth?What are your APIs Worth?
What are your APIs Worth?
 
Apigee Edge Overview and Roadmap
Apigee Edge Overview and RoadmapApigee Edge Overview and Roadmap
Apigee Edge Overview and Roadmap
 
I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
I Love APIs 2015: Advanced Crash Course in Apigee Edge Workshop
 
Protect your APIs from Cyber Threats
Protect your APIs from Cyber ThreatsProtect your APIs from Cyber Threats
Protect your APIs from Cyber Threats
 
API Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
API Design Best Practices & Tech Talk : API Craft Meetup @ ApigeeAPI Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
API Design Best Practices & Tech Talk : API Craft Meetup @ Apigee
 
API Services: Harness the Power of Enterprise Infrastructure
API Services: Harness the Power of Enterprise InfrastructureAPI Services: Harness the Power of Enterprise Infrastructure
API Services: Harness the Power of Enterprise Infrastructure
 
Executing on API Developer Experience
Executing on API Developer Experience Executing on API Developer Experience
Executing on API Developer Experience
 
London Adapt or Die: Opening Keynot
London Adapt or Die: Opening KeynotLondon Adapt or Die: Opening Keynot
London Adapt or Die: Opening Keynot
 
Apigee Edge Product Demo
Apigee Edge Product DemoApigee Edge Product Demo
Apigee Edge Product Demo
 
I Love APIs 2015: Implementing an API Tier to Enable a New Mobile Platform
I Love APIs 2015: Implementing an API Tier to Enable a New Mobile PlatformI Love APIs 2015: Implementing an API Tier to Enable a New Mobile Platform
I Love APIs 2015: Implementing an API Tier to Enable a New Mobile Platform
 
Pivotal + Apigee Workshop (June 4th, 2019)
Pivotal + Apigee Workshop (June 4th, 2019)Pivotal + Apigee Workshop (June 4th, 2019)
Pivotal + Apigee Workshop (June 4th, 2019)
 
Transforming Your Business Through APIs
Transforming Your Business Through APIsTransforming Your Business Through APIs
Transforming Your Business Through APIs
 

Similar to APIdays Paris 2019 - API Gateway & Identity Providers, a Match Made in Microservices Heaven by Yaara Letz, Tyk

Similar to APIdays Paris 2019 - API Gateway & Identity Providers, a Match Made in Microservices Heaven by Yaara Letz, Tyk (20)

Fragments-Plug the vulnerabilities in your App
Fragments-Plug the vulnerabilities in your AppFragments-Plug the vulnerabilities in your App
Fragments-Plug the vulnerabilities in your App
 
INTERFACE by apidays 2023 - The Swiss Cheese Model of Layered API Security, L...
INTERFACE by apidays 2023 - The Swiss Cheese Model of Layered API Security, L...INTERFACE by apidays 2023 - The Swiss Cheese Model of Layered API Security, L...
INTERFACE by apidays 2023 - The Swiss Cheese Model of Layered API Security, L...
 
API Security In Cloud Native Era
API Security In Cloud Native EraAPI Security In Cloud Native Era
API Security In Cloud Native Era
 
Securing Microservices in Hybrid Cloud
Securing Microservices in Hybrid CloudSecuring Microservices in Hybrid Cloud
Securing Microservices in Hybrid Cloud
 
apidays LIVE Singapore 2021 - Novel approaches in API security by Dr Tal Stei...
apidays LIVE Singapore 2021 - Novel approaches in API security by Dr Tal Stei...apidays LIVE Singapore 2021 - Novel approaches in API security by Dr Tal Stei...
apidays LIVE Singapore 2021 - Novel approaches in API security by Dr Tal Stei...
 
Catalyst 2015: Patrick Harding
Catalyst 2015: Patrick HardingCatalyst 2015: Patrick Harding
Catalyst 2015: Patrick Harding
 
apidays Australia 2023 - The Swiss Cheese Model of Layered API Security, Leon...
apidays Australia 2023 - The Swiss Cheese Model of Layered API Security, Leon...apidays Australia 2023 - The Swiss Cheese Model of Layered API Security, Leon...
apidays Australia 2023 - The Swiss Cheese Model of Layered API Security, Leon...
 
Why Network and Endpoint Security Isn’t Enough
Why Network and Endpoint Security Isn’t EnoughWhy Network and Endpoint Security Isn’t Enough
Why Network and Endpoint Security Isn’t Enough
 
Cybersecurity update 12
Cybersecurity update 12Cybersecurity update 12
Cybersecurity update 12
 
2022 APIsecure_The Real World, API Security Edition
2022 APIsecure_The Real World, API Security Edition2022 APIsecure_The Real World, API Security Edition
2022 APIsecure_The Real World, API Security Edition
 
Cartes Asia Dem 2010 V2
Cartes Asia Dem 2010 V2Cartes Asia Dem 2010 V2
Cartes Asia Dem 2010 V2
 
Enhancing your Security APIs
Enhancing your Security APIsEnhancing your Security APIs
Enhancing your Security APIs
 
WSO2Con EU 2015: API Management Strategies and Best Practices
WSO2Con EU 2015: API Management Strategies and Best PracticesWSO2Con EU 2015: API Management Strategies and Best Practices
WSO2Con EU 2015: API Management Strategies and Best Practices
 
Virtual Meetup - API Security Best Practices
Virtual Meetup - API Security Best PracticesVirtual Meetup - API Security Best Practices
Virtual Meetup - API Security Best Practices
 
Hacker vs AI
Hacker vs AI Hacker vs AI
Hacker vs AI
 
Lock it Down: Access Control for IBM i
Lock it Down: Access Control for IBM iLock it Down: Access Control for IBM i
Lock it Down: Access Control for IBM i
 
APIsecure 2023 - The Importance of Real-Time Protection in API Security, Jere...
APIsecure 2023 - The Importance of Real-Time Protection in API Security, Jere...APIsecure 2023 - The Importance of Real-Time Protection in API Security, Jere...
APIsecure 2023 - The Importance of Real-Time Protection in API Security, Jere...
 
Jobvite: A Holistic Approach to Security
Jobvite: A Holistic Approach to SecurityJobvite: A Holistic Approach to Security
Jobvite: A Holistic Approach to Security
 
Secure Your Web Applications and Achieve Compliance
Secure Your Web Applications and Achieve Compliance Secure Your Web Applications and Achieve Compliance
Secure Your Web Applications and Achieve Compliance
 
What Hackers Don’t Want You To Know: How to Maximize Your API Security
What Hackers Don’t Want You To Know: How to Maximize Your API SecurityWhat Hackers Don’t Want You To Know: How to Maximize Your API Security
What Hackers Don’t Want You To Know: How to Maximize Your API Security
 

More from apidays

More from apidays (20)

Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
Apidays New York 2024 - The secrets to Graph success, by Leah Hurwich Adler, ...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
Apidays New York 2024 - API Discovery - From Crawl to Run by Rob Dickinson, G...
 
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
Apidays Singapore 2024 - Building with the Planet in Mind by Sandeep Joshi, M...
 
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
Apidays Singapore 2024 - Connecting Cross Border Commerce with Payments by Gu...
 
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
Apidays Singapore 2024 - Privacy Enhancing Technologies for AI by Mark Choo, ...
 
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
Apidays Singapore 2024 - Blending AI and IoT for Smarter Health by Matthew Ch...
 
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
Apidays Singapore 2024 - OpenTelemetry for API Monitoring by Danielle Kayumbi...
 
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
Apidays Singapore 2024 - Connecting Product and Engineering Teams with Testin...
 
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
Apidays Singapore 2024 - The Growing Carbon Footprint of Digitalization and H...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
Apidays Singapore 2024 - API Monitoring x SRE by Ryan Ashneil and Eugene Wong...
 
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
Apidays Singapore 2024 - A nuanced approach on AI costs and benefits for the ...
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
Apidays Singapore 2024 - How APIs drive business at BNP Paribas by Quy-Doan D...
 

Recently uploaded

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Recently uploaded (20)

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 

APIdays Paris 2019 - API Gateway & Identity Providers, a Match Made in Microservices Heaven by Yaara Letz, Tyk

  • 1. API Days workshop API Gateway & Identity Providers, a Match Made in Microservices Heaven
  • 2. Yaara Letz Partner Consulting &&/|| Engineer @Tyk London, UK www.linkedin.com/in/yaara-letz-3439ba4 About me
  • 3. Tyk in 1 Minute API Management Platform: • API Gateway • Control Plane • Developer Portal • Flexible: SaaS and On-Premises By engineers for engineers: • Microservice architecture • Integration over vendor lock-in • Go Lang - fast and lean
  • 4. Tyk Today’s talk • Set the scene: Privacy, data breaches and keyless APIs • The Problem: How to prevent those when using APIs in microservices architecture. • Action: Use API gateway to ease the pain • Demo: Securing my API with Tyk and external Identity Provider • Q & A
  • 5. Tyk Privacy, regulation and Data breaches Privacy - Personal information is collected GDPR - General Data Protection Regulation - May 2018 Data breaches – You are liable for the data you hold. Invest in security today to avoid to avoid reputational and financial Consequences tomorrow
  • 6. Tyk Story time – Domino's Pizza are keeping your data safe
  • 7. Tyk How does it apply to APIs? 2018, many organisations had their APIs exposed to data breach and cyber attacks: 👺 Facebook - What: Cambridge Analytica harvested 50M users’ profiles for political adverts - How: Graph API of early version of FB’s API 👺 Uber - What: Compromised sensitive information of 57m users - How: Hackers found login credentials on an insecure private gist 👺 Tinder - What1: Undocumented APIs leaked location in 2013 - What2: Exposed users’ photos and activities - How: Didn’t use HTTPS end-to-end and poor encryption HTTPS https://www.helpnetsecurity.com/2017/11/22/uber-data-breach/ https://qz.com/106731/tinder-exposed-users-locations/ https://www.wired.com/story/tinder-lack-of-encryption-lets-strangers-spy-on-swipes/
  • 8. Tyk APIs are vulnerable too Gartner, 2017: By 2022, Data breaches in enterprises will be mainly in web applications space and by API abuses attacks
  • 9. Tyk Let’s talk about Keyless APIs 1. What is a keyless API? 2. When do people use keyless APIs 3. Is it dangerous? Why? 4. How can we address it?
  • 10. Tyk Keyless APIs - unofficial definition • An unprotected API – open for everyone, public • No need for key/token/password/identifying details • Its consumer is unidentified and unlimited
  • 11. Tyk When do I use keyless APIs • For internal usage (hint: trust model L bad decision) • When I want everyone to access my APIs • When I want barriers-free access to drive adoption of my API • When I don’t need to know who is accessing my APIs • When my APIs provide access to an already freely available data • When I “only” serve data So what is the danger?
  • 12. Tyk What is the danger? è The temptation: You have static website… …just for reading… …only does a simple HTTP GETs… …I don’t need to know who’s using my APIs è Implicit trust è This is an opportunity for an attacker to exploit!
  • 13. Tyk What are the risks of keyless APIs? • Back door - Give the world direct access to your code • In case of a bug - Expose your services to malicious access Worse – expose your clients data ( remember Gartner prediction?) • No rate limit and quota – Degrade API performance for everyone – noisy neighbour (bad code, load test) Results in an overloaded API service and increased cloud consumption • No identity You can’t identify the abuser and block his API calls. Lost business opportunity - can’t to use clients’ details to build your business and it’s hard to segment your API traffic by users So what should I do?
  • 14. Tyk Even Google stopped using keyless API (June 2018) { "error_message" : "Keyless access to Google Maps Platform is deprecated. Please use an API key with all your API calls to avoid service interruption. For details please refer to http://g.co/dev/no-account", "status" : "OVER_QUERY_LIMIT" }
  • 15. Tyk How Do I Drive Innovation While Still Protecting Keyless APIs?
  • 16. Tyk à With An API gateway
  • 17. Tyk Front Keyless APIs with an API gateway (or implement yourself) : if (you do): • Leave only necessary endpoints • Set a global rate limiting and throttling • Use common headers for user identification, rate- limiting, quota capping, tracing and analytics (User-Agent, X-Real-IP, Authorization) then (you will): • Avoid overloading of your API • Avoid cloud consumption • Gather analytics and ability to do user segmentation • Identify and block abusers else – next slide
  • 18. Tyk Let’s summaries the risks we are facing with APIs 1. Data breaches on poorly protected APIs (MITM) 2. Cyber attacks on poorly designed flows (Session Cookie Tampering, DDoS) 3. Leaked information via poorly designed APIs (TLS, API Parameter Tampering) 4. Degrade in all of my services and spike of my cloud consumption (Noisy neighbour) 5. Abusing the trust model (User’s ID can be compromised)
  • 19. Tyk The goal – basically prevention • Prevent the next data breach • Avoid data leaking (which can happen in every new release) • Protect your APIs from abuse by innocent or not so innocent caller • Keep metrices on the users in case of a breach or attack Security approach should be a balance between exposing web APIs in approachable way to ensure adoption with control to prevent abuse or attacks.
  • 20. Tyk à An API gateway can help – Duh #2
  • 21. Tyk How Can Tyk Help? 1. Authentication + Authorization – to identify and approve the caller 2. Throttle, Quota and Rate Limit users, apps and APIs - protect from abuse, brute force attack and noisy neighbours 3. Policies - to enforce tiered, metered and granular user access per path and method 4. Metrices – analytics per key, per API, or per request 5. lots more - versioning, clean leaking data, json validation, help SQL injection, backend protection (mTLS, Certificate pinning, RSA sign RSA request to upstream)…
  • 22. Tyk Apply AuthN and AuthZ To Microservices
  • 23. Tyk Why Microservices – A Quick Touchbase • Reduced coordination • Fast onboarding new joiners • Flexibility in development and deployment • Compatible with modern approaches • Reduced risk with no single point of failure
  • 24. Tyk AuthN and AuthZ Definitions • Authentication is the process through which a client proves their identity to the server • Authorisation is the server controlling what actions a specific identified client is able to perform
  • 25. Tyk Options For Adding AuthN and AuthZ To Microservice 1. Internally within each microservice 2. Externally by a gateway 3. Combination of internal and external 4. Wait-and-see
  • 26. Tyk Microservices - internal approach Pros: • Gives fined grained control • Self-reliance Cons: • More development effort • Complicates the code • Larger microservices • Repeated code - Risk of Copy/paste code • Will probably not cover all aspects or new ones • Not visible to security team Gartner suggest – “Don not code API security policies into the APIs”
  • 27. Tyk Microservices - external approach Pros: • Centrally handled • Enforce AuthN and AuthZ • Less development effort • Smaller microservices • Flexible with configuration Cons: • Vulnerability – circumvent the gateway à sort with mTLS and network set up • Less control – when needs DB to decide AuthZ à use Tyk as TCP proxy
  • 28. Tyk Microservices - combined approach Pros: • Relieves burden of authentication • Gives control of authorisation (for complex decisions) Cons: • More development effort • Larger microservices • Repeated code
  • 29. Tyk Choosing the right AuthN + AuthZ Methods ✔ Regulations industry ✔ Consistency ✔ Scenarios ✔ Users’ directory
  • 30. Tyk Identity providers Central hub for all of your identity needs: - Authentication – standards and protocols - Single Sign-On (SSO) - in the intranet and internet - Multi-factor authentication (MFA) - emails OTP, SMS, USB key etc. - Federation identity and multiple user’s identities
  • 31. Tyk Forth approach – With An Identity Providers You don’t have to on-board all the existing keys just let a the IdP to manage the user identity for you
  • 33. Tyk Conclusion There is no single best solution I’d favour the “external” approach – ü Use an API gateway to offload and simplify and centralise AuthN and AuthZ trivial flows ü Use an IdP to offload identity management and maintenance from your code and your data stores ü You can focus on your core business Mental note for future talk J – discuss AuthN/AuthZ requirement and setup for service mesh "east-west" traffic and not via the Edge API gateway.
  • 34. Tyk
  • 35. Tyk Q & A Yaara Letz @yaarale twitter.com/tyk_io github.com/TykTechnologies facebook.com/Tyk.API.Management