SlideShare a Scribd company logo
1 of 29
©2016 Apigee Corp. All Rights Reserved.
Dino Chiesa
Apigee
dchiesa@apigee.com
Vinit Mehta
Apigee
vmehta@apigee.com
Today’s presenters
Slideshare
slideshare.com/apigee
Apigee Community
https://community.apigee.com
YouTube
youtube.com/apigee
4
What do these companies have in common?
All are supporting OpenID Connect
and JWT.
5
Authentication and Authorization is hard.
Many systems do it poorly. (Do YOU provide 2FA ?)
JWT and OpenID Connect will help solve that problem.
You need to get JWT, now.
6
JWT, JWE, JWS
7
JWS, JWE, JWT are all part of JOSE:
“JSON Object Signing and Encryption”
8
JWT Enables Federated Identity
9©2015 Apigee. All Rights Reserved.
Internal Client
Application
Authentication
Server
(aka Identity
Provider, IdP)
API Proxy
User
store
Login Create
JWT (Signed)
JWT
Data
Public Key
Internal
Systems
JWT
Data
JWT
Data
Data
JWT
Validate
Validate
Validate
Validate
JWT Integrates with external Identity Providers
10©2015 Apigee. All Rights Reserved.
Partner
Application’s
Authentication
Server
(aka Identity
Provider, IdP)
API Proxy
User
store
Login
JWT (Signed) JWT
JWT
Data
JWT
Data
Data
Public Key
Validat
e
1 2 3
4
5
6
7
Internal
or Partner
Systems
• JWS – Signature
IETF RFC 7515
https://tools.ietf.org/html
/rfc7515
• JSON representation of
Signed or HMAC’ed
Content
• Payload that is signed
need not be JSON!
• The resulting JWS can be
verified by receivers
• JWE – Encryption
IETF RFC 7516
https://tools.ietf.org/ht
ml/rfc7516
• JSON representation of
Encrypted content
• Payload that is encrypted
need not be JSON
• Resulting JWE Can be
decrypted by receivers
JSON Web Token, Signature, Encryption
11
• JWT – Token
IETF RFC 7519
https://tools.ietf.org/ht
ml/rfc7519
• Signed, or optionally,
Encrypted, set of claims.
• Issuer, Subject,
audience, issue time, not-
before time, expiration.
• Used as a BEARER
token
• “Self-validating”
• Receiving parties can
make decisions based on
the claims and signing
party, or encrypting party.
©2015 Apigee. All Rights Reserved.
• JWS – Signature
IETF RFC 7515
https://tools.ietf.org/html
/rfc7515
• JSON representation of
Signed or HMAC’ed
Content
• Payload that is signed
need not be JSON!
• The resulting JWS can be
verified by receivers
• JWE – Encryption
IETF RFC 7516
https://tools.ietf.org/ht
ml/rfc7516
• JSON representation of
Encrypted content
• Payload that is encrypted
need not be JSON
• Resulting JWE Can be
decrypted by receivers
JSON Web Token, Signature, Encryption
12
• JWT – Token
IETF RFC 7519
https://tools.ietf.org/ht
ml/rfc7519
• Signed, or optionally,
Encrypted, set of claims.
• Issuer, Subject,
audience, issue time, not-
before time, expiration.
• Used as a BEARER
token
• “Self-validating”
• Receiving parties can
make decisions based on
the claims and signing
party, or encrypting party.
©2015 Apigee. All Rights Reserved.
Demo: Azure AD JWT
and JWT.io
13
Apigee Edge includes standard policies for many
security tasks.
Oauth1.0a generation and verification,
Oauth2 generation and verification,
SAML generation and verification…
14
Apigee Edge does not yet include standard policies for
JWT, JWE, JWS
15
But … Code + Configure !
16
• Embed your Java code as a policy in
Apigee Edge
• One Interface, one method, 2
parameters
• Can read policy configuration
• Can read and write context variables
• …anchor anywhere in Edge policy flow
• One of the ways to extend Edge with
custom code. Also JavaScript, Python,
nodejs.
• RTFM:
http://apigee.com/docs/api-
services/reference/java-callout-policy
What are Java Callouts?
17©2015 Apigee. All Rights Reserved.
• Re-usable now in any of
your Proxies
• Configure it with XML as
any other policy
• Make decisions based
on embedded claims
• Can read JWT
generated by third
parties, such as Google
or Windows Azure
Java Callout for JWT Parse/Verification
18©2015 Apigee. All Rights Reserved.
https://github.com/apigee/iloveapis2015-jwt-jwe-jws
• Re-usable now in any
of your Proxies
• Configure it with XML
as any other policy
• Generate JWT for use
by others
• Can be used by
backends or other
systems called by
clients
• Can be consumed by
Edge itself
Java Callout for JWT Generation
19©2015 Apigee. All Rights Reserved.
JWT Code walkthrough
& Demo
20
Some comments
• This JWT policy handles Signed, not Encrypted JWT
• RS256 and HS256 are supported
• We have a different policy that produces Encrypted JWT
(JWE) using RS256
• JWT cannot be “revoked” – so limit your lifetimes
• Exercise for the reader:
–ES256, other algorithms
21©2015 Apigee. All Rights Reserved.
When to use JWT vs Oauth 2.0 tokens?
22
When to use JWT vs Oauth 2.0 tokens?
• Trick Question! JWT are OAuth2.0 tokens
• Better phrased as: When to use JWT vs Opaque Oauth 2.0 tokens?
• Federation
• When you want the client to know everything that is being claimed
• JWT implies minimal impact to client and server apps
• JWT do not work well with revocation
23©2015 Apigee. All Rights Reserved.
• Re-usable now in any of your
Proxies
• Configure it with XML as any
other policy
• Generate JWE for use by
others
• Configurable Key strength and
key derivation
• Can be used by backends or
other systems called by
clients
• Can be consumed by Edge
itself
Java Callout for JWE Generation
24©2015 Apigee. All Rights Reserved.
https://github.com/apigee/iloveapis2015-jwt-jwe-jws
Java Callout for JWE Decryption
25©2015 Apigee. All Rights Reserved.
When to use JWS and JWE?
• Trick Question! Don’t ever use them!
• No, seriously.
• JWS and JWE imply some change to client apps
• More limited scope of usage than JWT
• There are already ways to sign and encrypt arbitrary data
• My opinion: JWE and JWS are mostly interesting in support of JWT
26©2015 Apigee. All Rights Reserved.
What did we learn?
27
APIs
Apps
Users
©2015 Apigee. All Rights Reserved.
• YOU NEED to handle JWT
• You can use JWT, JWS, JWE in
Apigee Edge today via custom policies
• No coding needed !
• These policies complement the
existing built-in policies in Apigee
Edgehttps://github.com/apigee/iloveapis2015-jwt-jwe-jws
©2016 Apigee Corp. All Rights Reserved.
Questions?
28
Thank you

More Related Content

What's hot

What's hot (20)

APISecurity_OWASP_MitigationGuide
APISecurity_OWASP_MitigationGuide APISecurity_OWASP_MitigationGuide
APISecurity_OWASP_MitigationGuide
 
Introduction to Swagger
Introduction to SwaggerIntroduction to Swagger
Introduction to Swagger
 
API Security : Patterns and Practices
API Security : Patterns and PracticesAPI Security : Patterns and Practices
API Security : Patterns and Practices
 
Introduction to Kong API Gateway
Introduction to Kong API GatewayIntroduction to Kong API Gateway
Introduction to Kong API Gateway
 
API
APIAPI
API
 
Swagger
SwaggerSwagger
Swagger
 
Rest API Security - A quick understanding of Rest API Security
Rest API Security - A quick understanding of Rest API SecurityRest API Security - A quick understanding of Rest API Security
Rest API Security - A quick understanding of Rest API Security
 
How to migrate an application in IBM APIc, and preserve its client credential
How to migrate an application in IBM APIc, and preserve its client credentialHow to migrate an application in IBM APIc, and preserve its client credential
How to migrate an application in IBM APIc, and preserve its client credential
 
OAuth2 and Spring Security
OAuth2 and Spring SecurityOAuth2 and Spring Security
OAuth2 and Spring Security
 
APIConnect Security Best Practice
APIConnect Security Best PracticeAPIConnect Security Best Practice
APIConnect Security Best Practice
 
DevOps at Amazon: A Look at Our Tools and Processes
DevOps at Amazon: A Look at Our Tools and ProcessesDevOps at Amazon: A Look at Our Tools and Processes
DevOps at Amazon: A Look at Our Tools and Processes
 
REST API Design & Development
REST API Design & DevelopmentREST API Design & Development
REST API Design & Development
 
Swagger UI
Swagger UISwagger UI
Swagger UI
 
OpenID Connect Explained
OpenID Connect ExplainedOpenID Connect Explained
OpenID Connect Explained
 
API Security Best Practices & Guidelines
API Security Best Practices & GuidelinesAPI Security Best Practices & Guidelines
API Security Best Practices & Guidelines
 
API as-a-Product with Azure API Management (APIM)
API as-a-Product with Azure API Management (APIM)API as-a-Product with Azure API Management (APIM)
API as-a-Product with Azure API Management (APIM)
 
APIsecure 2023 - Security Considerations for API Gateway Aggregation, Yoshiyu...
APIsecure 2023 - Security Considerations for API Gateway Aggregation, Yoshiyu...APIsecure 2023 - Security Considerations for API Gateway Aggregation, Yoshiyu...
APIsecure 2023 - Security Considerations for API Gateway Aggregation, Yoshiyu...
 
Deep-Dive: Secure API Management
Deep-Dive: Secure API ManagementDeep-Dive: Secure API Management
Deep-Dive: Secure API Management
 
How to create a User Defined Policy with IBM APIc (v10)
How to create a User Defined Policy with IBM APIc (v10)How to create a User Defined Policy with IBM APIc (v10)
How to create a User Defined Policy with IBM APIc (v10)
 
API Gateway How-To: The Many Ways to Apply the Gateway Pattern
API Gateway How-To: The Many Ways to Apply the Gateway PatternAPI Gateway How-To: The Many Ways to Apply the Gateway Pattern
API Gateway How-To: The Many Ways to Apply the Gateway Pattern
 

Similar to Advanced Security Extensions in Apigee Edge: JWT, JWE, JWS

Similar to Advanced Security Extensions in Apigee Edge: JWT, JWE, JWS (20)

I Love APIs 2015: Advanced Security Extensions in Apigee Edge - JWT, JWE, JWS
I Love APIs 2015: Advanced Security Extensions in Apigee Edge - JWT, JWE, JWSI Love APIs 2015: Advanced Security Extensions in Apigee Edge - JWT, JWE, JWS
I Love APIs 2015: Advanced Security Extensions in Apigee Edge - JWT, JWE, JWS
 
Webcast: Deep-Dive Apigee Edge Microgateway
Webcast: Deep-Dive Apigee Edge MicrogatewayWebcast: Deep-Dive Apigee Edge Microgateway
Webcast: Deep-Dive Apigee Edge Microgateway
 
APIdays London 2020: Toward certifying Financial-grade API security profile w...
APIdays London 2020: Toward certifying Financial-grade API security profile w...APIdays London 2020: Toward certifying Financial-grade API security profile w...
APIdays London 2020: Toward certifying Financial-grade API security profile w...
 
Using containerization to enable your microservice architecture
Using containerization to enable your microservice architecture Using containerization to enable your microservice architecture
Using containerization to enable your microservice architecture
 
Modernizing an Existing SOA-based Architecture with APIs
Modernizing an Existing SOA-based Architecture with APIsModernizing an Existing SOA-based Architecture with APIs
Modernizing an Existing SOA-based Architecture with APIs
 
[WSO2 API Manager Community Call] Mastering JWTs with WSO2 API Manager
[WSO2 API Manager Community Call] Mastering JWTs with WSO2 API Manager[WSO2 API Manager Community Call] Mastering JWTs with WSO2 API Manager
[WSO2 API Manager Community Call] Mastering JWTs with WSO2 API Manager
 
apidays LIVE LONDON - Toward certifying Financial-grade API profile with Keyc...
apidays LIVE LONDON - Toward certifying Financial-grade API profile with Keyc...apidays LIVE LONDON - Toward certifying Financial-grade API profile with Keyc...
apidays LIVE LONDON - Toward certifying Financial-grade API profile with Keyc...
 
Moving the Guidewire platform to OSGi - Paul D'Albora
Moving the Guidewire platform to OSGi - Paul D'AlboraMoving the Guidewire platform to OSGi - Paul D'Albora
Moving the Guidewire platform to OSGi - Paul D'Albora
 
Implementing security requirements for banking API system using Open Source ...
 Implementing security requirements for banking API system using Open Source ... Implementing security requirements for banking API system using Open Source ...
Implementing security requirements for banking API system using Open Source ...
 
CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...
CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...
CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...
 
Webinar: ForgeRock Identity Platform Preview (Dec 2015)
Webinar: ForgeRock Identity Platform Preview (Dec 2015)Webinar: ForgeRock Identity Platform Preview (Dec 2015)
Webinar: ForgeRock Identity Platform Preview (Dec 2015)
 
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
 
Open Source & What It Means For Self-Sovereign Identity (SSI)
Open Source & What It Means For Self-Sovereign Identity (SSI)Open Source & What It Means For Self-Sovereign Identity (SSI)
Open Source & What It Means For Self-Sovereign Identity (SSI)
 
Finally, EE Security API JSR 375
Finally, EE Security API JSR 375Finally, EE Security API JSR 375
Finally, EE Security API JSR 375
 
Java SE Subscription Workshop
Java SE Subscription WorkshopJava SE Subscription Workshop
Java SE Subscription Workshop
 
I Love APIs 2015: Crash Course Foundational Topics in Apigee Edge Workshop
I Love APIs 2015: Crash Course Foundational Topics in Apigee Edge WorkshopI Love APIs 2015: Crash Course Foundational Topics in Apigee Edge Workshop
I Love APIs 2015: Crash Course Foundational Topics in Apigee Edge Workshop
 
026 Neo4j Data Loading (ETL_ELT) Best Practices - NODES2022 AMERICAS Advanced...
026 Neo4j Data Loading (ETL_ELT) Best Practices - NODES2022 AMERICAS Advanced...026 Neo4j Data Loading (ETL_ELT) Best Practices - NODES2022 AMERICAS Advanced...
026 Neo4j Data Loading (ETL_ELT) Best Practices - NODES2022 AMERICAS Advanced...
 
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
 
Microsoft power point automation-opensourcetestingtools_matrix-1
Microsoft power point   automation-opensourcetestingtools_matrix-1Microsoft power point   automation-opensourcetestingtools_matrix-1
Microsoft power point automation-opensourcetestingtools_matrix-1
 
Microsoft power point automation-opensourcetestingtools_matrix-1
Microsoft power point   automation-opensourcetestingtools_matrix-1Microsoft power point   automation-opensourcetestingtools_matrix-1
Microsoft power point automation-opensourcetestingtools_matrix-1
 

More from Apigee | Google Cloud

More from Apigee | Google Cloud (20)

How Secure Are Your APIs?
How Secure Are Your APIs?How Secure Are Your APIs?
How Secure Are Your APIs?
 
Magazine Luiza at a glance (1)
Magazine Luiza at a glance (1)Magazine Luiza at a glance (1)
Magazine Luiza at a glance (1)
 
Monetization: Unlock More Value from Your APIs
Monetization: Unlock More Value from Your APIs Monetization: Unlock More Value from Your APIs
Monetization: Unlock More Value from Your APIs
 
Ticketmaster at a glance
Ticketmaster at a glanceTicketmaster at a glance
Ticketmaster at a glance
 
AccuWeather: Recasting API Experiences in a Developer-First World
AccuWeather: Recasting API Experiences in a Developer-First WorldAccuWeather: Recasting API Experiences in a Developer-First World
AccuWeather: Recasting API Experiences in a Developer-First World
 
Which Application Modernization Pattern Is Right For You?
Which Application Modernization Pattern Is Right For You?Which Application Modernization Pattern Is Right For You?
Which Application Modernization Pattern Is Right For You?
 
Apigee Product Roadmap Part 2
Apigee Product Roadmap Part 2Apigee Product Roadmap Part 2
Apigee Product Roadmap Part 2
 
The Four Transformative Forces of the API Management Market
The Four Transformative Forces of the API Management MarketThe Four Transformative Forces of the API Management Market
The Four Transformative Forces of the API Management Market
 
Walgreens at a glance
Walgreens at a glanceWalgreens at a glance
Walgreens at a glance
 
Apigee Edge: Intro to Microgateway
Apigee Edge: Intro to MicrogatewayApigee Edge: Intro to Microgateway
Apigee Edge: Intro to Microgateway
 
Managing the Complexity of Microservices Deployments
Managing the Complexity of Microservices DeploymentsManaging the Complexity of Microservices Deployments
Managing the Complexity of Microservices Deployments
 
Pitney Bowes at a glance
Pitney Bowes at a glancePitney Bowes at a glance
Pitney Bowes at a glance
 
Microservices Done Right: Key Ingredients for Microservices Success
Microservices Done Right: Key Ingredients for Microservices SuccessMicroservices Done Right: Key Ingredients for Microservices Success
Microservices Done Right: Key Ingredients for Microservices Success
 
Adapt or Die: Opening Keynote with Chet Kapoor
Adapt or Die: Opening Keynote with Chet KapoorAdapt or Die: Opening Keynote with Chet Kapoor
Adapt or Die: Opening Keynote with Chet Kapoor
 
Adapt or Die: Keynote with Greg Brail
Adapt or Die: Keynote with Greg BrailAdapt or Die: Keynote with Greg Brail
Adapt or Die: Keynote with Greg Brail
 
Adapt or Die: Keynote with Anant Jhingran
Adapt or Die: Keynote with Anant JhingranAdapt or Die: Keynote with Anant Jhingran
Adapt or Die: Keynote with Anant Jhingran
 
London Adapt or Die: Opening Keynot
London Adapt or Die: Opening KeynotLondon Adapt or Die: Opening Keynot
London Adapt or Die: Opening Keynot
 
London Adapt or Die: Lunch keynote
London Adapt or Die: Lunch keynoteLondon Adapt or Die: Lunch keynote
London Adapt or Die: Lunch keynote
 
London Adapt or Die: Closing Keynote — Adapt Now!
London Adapt or Die: Closing Keynote — Adapt Now!London Adapt or Die: Closing Keynote — Adapt Now!
London Adapt or Die: Closing Keynote — Adapt Now!
 
London adapt or-die opening keynote chet kapoor
London adapt or-die opening keynote chet kapoorLondon adapt or-die opening keynote chet kapoor
London adapt or-die opening keynote chet kapoor
 

Recently uploaded

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Recently uploaded (20)

Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
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...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 

Advanced Security Extensions in Apigee Edge: JWT, JWE, JWS

  • 1. ©2016 Apigee Corp. All Rights Reserved.
  • 4. 4 What do these companies have in common?
  • 5. All are supporting OpenID Connect and JWT. 5
  • 6. Authentication and Authorization is hard. Many systems do it poorly. (Do YOU provide 2FA ?) JWT and OpenID Connect will help solve that problem. You need to get JWT, now. 6
  • 8. JWS, JWE, JWT are all part of JOSE: “JSON Object Signing and Encryption” 8
  • 9. JWT Enables Federated Identity 9©2015 Apigee. All Rights Reserved. Internal Client Application Authentication Server (aka Identity Provider, IdP) API Proxy User store Login Create JWT (Signed) JWT Data Public Key Internal Systems JWT Data JWT Data Data JWT Validate Validate Validate Validate
  • 10. JWT Integrates with external Identity Providers 10©2015 Apigee. All Rights Reserved. Partner Application’s Authentication Server (aka Identity Provider, IdP) API Proxy User store Login JWT (Signed) JWT JWT Data JWT Data Data Public Key Validat e 1 2 3 4 5 6 7 Internal or Partner Systems
  • 11. • JWS – Signature IETF RFC 7515 https://tools.ietf.org/html /rfc7515 • JSON representation of Signed or HMAC’ed Content • Payload that is signed need not be JSON! • The resulting JWS can be verified by receivers • JWE – Encryption IETF RFC 7516 https://tools.ietf.org/ht ml/rfc7516 • JSON representation of Encrypted content • Payload that is encrypted need not be JSON • Resulting JWE Can be decrypted by receivers JSON Web Token, Signature, Encryption 11 • JWT – Token IETF RFC 7519 https://tools.ietf.org/ht ml/rfc7519 • Signed, or optionally, Encrypted, set of claims. • Issuer, Subject, audience, issue time, not- before time, expiration. • Used as a BEARER token • “Self-validating” • Receiving parties can make decisions based on the claims and signing party, or encrypting party. ©2015 Apigee. All Rights Reserved.
  • 12. • JWS – Signature IETF RFC 7515 https://tools.ietf.org/html /rfc7515 • JSON representation of Signed or HMAC’ed Content • Payload that is signed need not be JSON! • The resulting JWS can be verified by receivers • JWE – Encryption IETF RFC 7516 https://tools.ietf.org/ht ml/rfc7516 • JSON representation of Encrypted content • Payload that is encrypted need not be JSON • Resulting JWE Can be decrypted by receivers JSON Web Token, Signature, Encryption 12 • JWT – Token IETF RFC 7519 https://tools.ietf.org/ht ml/rfc7519 • Signed, or optionally, Encrypted, set of claims. • Issuer, Subject, audience, issue time, not- before time, expiration. • Used as a BEARER token • “Self-validating” • Receiving parties can make decisions based on the claims and signing party, or encrypting party. ©2015 Apigee. All Rights Reserved.
  • 13. Demo: Azure AD JWT and JWT.io 13
  • 14. Apigee Edge includes standard policies for many security tasks. Oauth1.0a generation and verification, Oauth2 generation and verification, SAML generation and verification… 14
  • 15. Apigee Edge does not yet include standard policies for JWT, JWE, JWS 15
  • 16. But … Code + Configure ! 16
  • 17. • Embed your Java code as a policy in Apigee Edge • One Interface, one method, 2 parameters • Can read policy configuration • Can read and write context variables • …anchor anywhere in Edge policy flow • One of the ways to extend Edge with custom code. Also JavaScript, Python, nodejs. • RTFM: http://apigee.com/docs/api- services/reference/java-callout-policy What are Java Callouts? 17©2015 Apigee. All Rights Reserved.
  • 18. • Re-usable now in any of your Proxies • Configure it with XML as any other policy • Make decisions based on embedded claims • Can read JWT generated by third parties, such as Google or Windows Azure Java Callout for JWT Parse/Verification 18©2015 Apigee. All Rights Reserved. https://github.com/apigee/iloveapis2015-jwt-jwe-jws
  • 19. • Re-usable now in any of your Proxies • Configure it with XML as any other policy • Generate JWT for use by others • Can be used by backends or other systems called by clients • Can be consumed by Edge itself Java Callout for JWT Generation 19©2015 Apigee. All Rights Reserved.
  • 21. Some comments • This JWT policy handles Signed, not Encrypted JWT • RS256 and HS256 are supported • We have a different policy that produces Encrypted JWT (JWE) using RS256 • JWT cannot be “revoked” – so limit your lifetimes • Exercise for the reader: –ES256, other algorithms 21©2015 Apigee. All Rights Reserved.
  • 22. When to use JWT vs Oauth 2.0 tokens? 22
  • 23. When to use JWT vs Oauth 2.0 tokens? • Trick Question! JWT are OAuth2.0 tokens • Better phrased as: When to use JWT vs Opaque Oauth 2.0 tokens? • Federation • When you want the client to know everything that is being claimed • JWT implies minimal impact to client and server apps • JWT do not work well with revocation 23©2015 Apigee. All Rights Reserved.
  • 24. • Re-usable now in any of your Proxies • Configure it with XML as any other policy • Generate JWE for use by others • Configurable Key strength and key derivation • Can be used by backends or other systems called by clients • Can be consumed by Edge itself Java Callout for JWE Generation 24©2015 Apigee. All Rights Reserved. https://github.com/apigee/iloveapis2015-jwt-jwe-jws
  • 25. Java Callout for JWE Decryption 25©2015 Apigee. All Rights Reserved.
  • 26. When to use JWS and JWE? • Trick Question! Don’t ever use them! • No, seriously. • JWS and JWE imply some change to client apps • More limited scope of usage than JWT • There are already ways to sign and encrypt arbitrary data • My opinion: JWE and JWS are mostly interesting in support of JWT 26©2015 Apigee. All Rights Reserved.
  • 27. What did we learn? 27 APIs Apps Users ©2015 Apigee. All Rights Reserved. • YOU NEED to handle JWT • You can use JWT, JWS, JWE in Apigee Edge today via custom policies • No coding needed ! • These policies complement the existing built-in policies in Apigee Edgehttps://github.com/apigee/iloveapis2015-jwt-jwe-jws
  • 28. ©2016 Apigee Corp. All Rights Reserved. Questions? 28

Editor's Notes

  1. With that , it is time for introductions, This is Aashima Gupta , I lead the healthcare vertical for Apigee with focus on API and Analytics. In this role ,I closely working with marque clients inclding payers , providers and pharmas in helping them with digital health strategy acceleratio and also n in identifying transformative opportunities ( FHIR being one of them) Prior to joining the firm ,I was leading the Digital Health Incubations at Kaiser and drove innovation around multitude of digital channels including launch of the Lifestyle integration platform and first public API for kaiser.
  2. Vinit will talk to this slide. Move blocks around to fit. Which big vendors are supporting this? Facebook, Azure, Salesforce… (Verify)
  3. Vinit will talk to this slide. Move blocks around to fit. Which big vendors are supporting this? Facebook, Azure, Salesforce… (Verify)
  4. JWK – JSON Web Key - RFC 7517 JWA – JSON Web Algorithms – RFC 7518
  5. JWK – JSON Web Key - RFC 7517 JWA – JSON Web Algorithms – RFC 7518