SlideShare ist ein Scribd-Unternehmen logo
1 von 83
Downloaden Sie, um offline zu lesen
@CesarHgt @tomitribeJavaDay Ecuador 2018
Seguridad en Microservicios
via Microprofile JWT
César Hernández
Tomitribe
@CesarHgt @tomitribeJavaDay Ecuador 2018
● Senior Software Engineer at Tomitribe
● Java Champion
● Ducke’s Choice Award 2016, 2017
● Oracle Certified Professional
● +10 experience with Java EE
● Eclipse Commiter: Jakarta EE TCK, JAX-WS
and Microprofile.
● Open Source advocate, teacher and public
speaker
César Hernández
@CesarHgt @tomitribeJavaDay Ecuador 2018
Java es Comunidad
@CesarHgt @tomitribeJavaDay Ecuador 2018
https://tribestream.io/javadayec/
Diapositivas y referencias
CONTACTANOS @TOMITRIBE
@CesarHgt @tomitribeJavaDay Ecuador 2018
“Lo mejor de los estándares es que terminas
teniendo muchas opciones por escoger.”
- Andrew S. Tanenbaum
@CesarHgt @tomitribeJavaDay Ecuador 2018
Opciones de seguridad para
Microservicios
● Más allá de Basic Auth
● Teoría de OAuth 2.0
● Introducción a JWT
● Eclipse Microprofile
● Demo
@CesarHgt @tomitribeJavaDay Ecuador 2018
Línea Base
1000 usuarios
x 3 TPS
4 saltos
3000 TPS
frontend
12000
TPS
backend
@CesarHgt @tomitribeJavaDay Ecuador 2018
Basic Auth
(y sus problemas)
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje en Basic Auth
POST /painter/color/object HTTP/1.1
Host: localhost:8443
Authorization: Basic c25vb3B5OnBhc3M=
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 45
{"color":{"b":255,"g":0,"name":"blue","r":0}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Basic Auth
Password Sent
3000 TPS
(HTTP+SSL)
username+password
Base64 (no auth)
(LDAP)
12000
TPS
(HTTP)
3000 TPS
@CesarHgt @tomitribeJavaDay Ecuador 2018
Basic Auth
Password Sent
3000 TPS
(HTTP+SSL)
username+password
Base64
Lista Blanca
de IP
3000 TPS
(LDAP)
12000
TPS
(HTTP)
@CesarHgt @tomitribeJavaDay Ecuador 2018
“Dame toda la
información del
salario de José.” “No se quien
eres,
…
pero por
supuesto!”
@CesarHgt @tomitribeJavaDay Ecuador 2018
Ataque de fuerza bruta: Basic Auth
Password
válidos
3000
TPS
(HTTP+SSL)
Lista
Blanca IP
9000 TPS
(LDAP)
12000
TPS
(HTTP)
Passwords
inválidos
6000
TPS
(HTTP+SSL)
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2.0
(y sus problemas)
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Password Grant
(LDAP)
(Repositorio
de Token)
Verificación de
Password
Generación de
Token
Post /oauth2/token
Host: api.superbliz.io
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/x-www-form-urlencoded
Content-Length: 54
grand_type=password&username=snoopy&password=woodstock
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Password Grant
(LDAP)
Verificación de
Password
Generación de
Token
(Repositorio
de Token)
Post /oauth2/token
Host: api.superbliz.io
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/x-www-form-urlencoded
Content-Length: 54
grand_type=password&username=snoopy&password=woodstock
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/object HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 45
{"color":{"r":0,"g":0,"b":255,"name":"blue"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/palette HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 45
{"color":{"r":0,"g":255,"b":0,"name":"green"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/select HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 44
{"color":{"r":255,"g":0,"b":0,"name":"red"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/fill HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 49
{"color":{"r":0,"g":255,"b":255,"name":"yellow"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/stroke HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 49
{"color":{"r":255,"g":200,"b":255,"name":"orange"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Refresh Grant
(LDAP)
Verificación
Password
Generación
Token
(Repositorio
de Token)
Post /oauth2/token
Host: api.superbliz.io
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/x-www-form-urlencoded
Content-Length: 54
grand_type=password&username=snoopy&password=woodstock
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Refresh Grant
(LDAP)
Verificación
Password
Generación
Token
(Repositorio
de Token)
Post /oauth2/token
Host: api.superbliz.io
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/x-www-form-urlencoded
Content-Length: 54
grand_type=password&username=snoopy&password=woodstock
@CesarHgt @tomitribeJavaDay Ecuador 2018
Par anterior
∙ Access Token 2YotnFZFEjr1zCsicMWpAA
∙ Refresh Token tGzv3JOkF0XG5Qx2TlKWIA
Nuevo Par
∙ Access Token
6Fe4jd7TmdE5yW2q0y6W2w
∙ Refresh Token hyT5rw1QNh5Ttg2hdtR54e
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/palette HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 46
{"color":{"r":0,"g":255,"b":0,"name":"green"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/select HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 44
{"color":{"r":255,"g":0,"b":0,"name":"red"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0
POST /painter/color/fill HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 49
{"color":{"r":0,"g":255,"b":255,"name":"yellow"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
¿Qué hemos logrado?
@CesarHgt @tomitribeJavaDay Ecuador 2018
Ahora tenemos más passwords
(al menos tus dispositivos los tienen)
@CesarHgt @tomitribeJavaDay Ecuador 2018
Terminología de nuevo…
∙ Password Grant???
∙ Logging in
∙ Token?
∙ Un password ligeramente ofuscado
∙ Equivalente a un HTTP session ID mejorado levemente
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2
Request enviados
(Authorization: Bearer …)
3000 TPS
(HTTP+SSL)
3000 TPS
(Verificaciones
de tokens)
Password enviados
(post oauth2/token …)
1000/daily
(HTTP+SSL)
OAuth 2
(LDAP)
4 saldos
12000
TPS
backend
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
“Quién es
6Fe4jd7TmdE5y
W2q0y6W2w
???????”
“No tengo idea.
Pregúntale al
servidor de
tokens.”
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2
Tokens enviados
3000 TPS
(HTTP+SSL)
3000 TPS
(verificación
token)
Password
Envidados
1000/daily
(HTTP+SSL)
OAuth 2
(LDAP)
12000
TPS
(Verificación
token)
8
Saldos
24000 TPS
backend
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2
3000 TPS
(Verificación
token)
(LDAP)
12000
TPS
(Verificación
token)
55%
del tráfico total
Tokens enviados
3000 TPS
(HTTP+SSL)
Password
Envidados
1000/daily
(HTTP+SSL)
OAuth 2
8
Saldos
24000 TPS
backend
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2
Puntero Puntero
Estado
@CesarHgt @tomitribeJavaDay Ecuador 2018
Access Token
Puntero de Acceso?
Llave primaria de Acceso?
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2.0
Algoritmo de intercambio de
passwords de alta frecuencia?
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2.0
+
JSon Web Tokens (JWT)
@CesarHgt @tomitribeJavaDay Ecuador 2018
JSon Web Token
∙ Pronunciado “YOT”
∙ JSON map con data de usuario
∙ Códificado Base64
∙ Firmado digitalmente (RSA-SHA256, HMAC-SHA512, etc)
∙ Mecanismo de expiración
@CesarHgt @tomitribeJavaDay Ecuador 2018
Previamente un Access Token
∙ 6Fe4jd7TmdE5yW2q0y6W2w
@CesarHgt @tomitribeJavaDay Ecuador 2018
Access Token ahora (JWT)
∙ eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ0b2tlbi10eXBlIj
oiYWNjZXNzLXRva2VuIiwidXNlcm5hbWUiOiJzbm9vcHkiLCJ
hbmltYWwiOiJiZWFnbGUiLCJpc3MiOiJodHRwczovL2RlbW8
uc3VwZXJiaXouY29tL29hdXRoMi90b2tlbiIsInNjb3BlcyI6WyJ0
d2l0dGVyIiwibWFucy1iZXN0LWZyaWVuZCJdLCJleHAiOjE0
NzQyODA5NjMsImlhdCI6MTQ3NDI3OTE2MywianRpIjoiNjY4
ODFiMDY4YjI0OWFkOSJ9.DTfSdMzIIsC0j8z3icRdYO1GaM
Gl6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vICc0hb4F0QCD
3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Ocxm1F5IUNZvz
lLJ_ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYN
o
@CesarHgt @tomitribeJavaDay Ecuador 2018
Nuevo Access Token
∙ header (JSON > Base64 URL Encoded)
∙ Describe como la firma (signature) del token puede ser
verificada
∙ payload (JSON > Base64 URL Encoded)
∙ Json map de información que desees incluir
∙ Campo estándar como el de Expiración
∙ signature (Binary > Base64 URL Encoded)
∙ La firma digital
∙ Hecha exclusivamente por el endpoint: /oauth2/token
∙ Si es RSA puede ser verificado por cualquier persona
@CesarHgt @tomitribeJavaDay Ecuador 2018
∙ { "alg": “RS256", "typ": “JWT" }
∙ {
"token-type": "access-token",
"username": "snoopy",
"animal": "beagle",
"iss": "https://demo.superbiz.com/oauth2/token",
"scopes": [
“twitter”, "mans-best-friend"
],
"exp": 1474280963,
"iat": 1474279163,
"jti": "66881b068b249ad9"
}
∙ DTfSdMzIIsC0j8z3icRdYO1GaMGl6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vI
Cc0hb4F0QCD3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Ocxm1F5IUNZvzlLJ
_ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYNo
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
@CesarHgt @tomitribeJavaDay Ecuador 2018
Ligero pero con alto impacto en
la arquitectura
@CesarHgt @tomitribeJavaDay Ecuador 2018
¿Qué tenemos hasta el
momento?
(repaso)
@CesarHgt @tomitribeJavaDay Ecuador 2018
Resultado final
cliente permanece
con el Pointer
Server almacena
State
@CesarHgt @tomitribeJavaDay Ecuador 2018
¿Qué podemos hacer ahora?
(hola JWT!)
@CesarHgt @tomitribeJavaDay Ecuador 2018
LDAP Data completa
del usuario
desde
ldap
@CesarHgt @tomitribeJavaDay Ecuador 2018
LDAP
La data se
representa
en JSON
@CesarHgt @tomitribeJavaDay Ecuador 2018
LDAP
JSON es
firmado
RSA-SHA 256
@CesarHgt @tomitribeJavaDay Ecuador 2018
LDAP
Se inserta
solamente
el
pointer en
DB(para
revocaciones)
@CesarHgt @tomitribeJavaDay Ecuador 2018
LDAP
Envío del Access Token
(estado)
hacia el cliente
@CesarHgt @tomitribeJavaDay Ecuador 2018
Servidor almacena el
Puntero
Cliente permanece con el
Estado
Resultado obtenido
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Password Grant
(LDAP)
(Repositorio
Token ID)
Verifica
Password
Genera
Token
Firmado
(Signed)
Post /oauth2/token
Host: api.superbliz.io
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/x-www-form-urlencoded
Content-Length: 54
grand_type=password&username=snoopy&password=woodstock
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 - Password Grant
(LDAP)
Verifica
Password
(Repositorio
Token ID)
Genera
Token
Firmado
(Signed)
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mensaje OAuth 2.0 con JWT
POST /painter/color/palette HTTP/1.1
Host: api.superbiz.io
Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ0b2tlbi10eXBlIjoiYWNjZXNzLXR
va2VuIiwidXNlcm5hbWUiOiJzbm9vcHkiLCJhbmltYWwiOiJiZWFnbGUiLCJpc3MiOiJodHRwczovL2RlbW8
uc3VwZXJ
iaXouY29tL29hdXRoMi90b2tlbiIsInNjb3BlcyI6WyJ0d2l0dGVyIiwibWFucy1iZXN0LWZyaWVuZCJdLCJleH
AiOjE0NzQy
ODA5NjMsImlhdCI6MTQ3NDI3OTE2MywianRpIjoiNjY4ODFiMDY4YjI0OWFkOSJ9.DTfSdMzIIsC0j8z3icRd
YO1GaMGl
6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vICc0hb4F0QCD3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Oc
xm1F5IUNZ
vzlLJ_ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYNo
User-Agent: curl/7.43.0
Accept: */*
Content-Type: application/json
Content-Length: 46
{"color":{"b":0,"g":255,"r":0,"name":"green"}}
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 + JWT
Tokens enviados
3000 TPS
(HTTP+SSL)
0.55 TPS
(Verificaciones
refresh token)
OAuth
2
(LDAP)
4 saltos
12000 TPS
backend
3000 TPS
(verifica firma)
12000 TPS
(verifica firma)
Password enviados
(post oauth2/token …)
1000/daily
(HTTP+SSL)
@CesarHgt @tomitribeJavaDay Ecuador 2018
“No!”
“Dame toda la
información del
salario de José.”
@CesarHgt @tomitribeJavaDay Ecuador 2018
“Claro!”
“Dame toda la
información del
salario de José.”
@CesarHgt @tomitribeJavaDay Ecuador 2018
OAuth 2 + JWT
Envío de
Tokens válidos
3000 TPS
(HTTP+SSL)
IP
whitelisting
0.55 TPS
(verifica refresh token)
Password enviados
1000/daily
(HTTP+SSL)
(LDAP)
4 saltos
12000 TPS
backend
9000 TPS
(verifica firma)
12000 TPS
(verifica firma)
Token inválidos
6000 TPS
(HTTP+SSL)
@CesarHgt @tomitribeJavaDay Ecuador 2018
https://connect2id.com/products/nimbus-jose-jwt
Librería JWT
https://github.com/jwtk/jjwt
https://github.com/auth0/java-jwt
@CesarHgt @tomitribeJavaDay Ecuador 2018
Eclipse MicroProfile
@CesarHgt @tomitribeJavaDay Ecuador 2018
MicroProfile
∙ Comunidad Open-Source de la fundación Eclipse
∙ Enfocada en Microservicios bajo JavaEE
∙ Generadora de: Specificaciones, API y TCK.
∙ Implementado por diferentes entidades
http://microprofile.io/
@CesarHgt @tomitribeJavaDay Ecuador 2018
MicroProfile JWT
MicroProfile 2.0
JAX-RS 2.1JSON-P 1.1CDI 2.0
Config 1.3
Fault
Tolerance
1.1
JWT
RBAC 1.1
Health
Check 1.0
Metrics 1.1
Open
Tracing 1.1
Open API
1.0
Rest Client
1.1
JSON-B 1.0
JWT
RBAC 1.1
https://microprofile.io/project/eclipse/microprofile-jwt-auth/
Estándares de Seguridad
● OAuth 2.0
● OpenID Connect
● JSON Web Tokens
(JWT)
Tecnologías Java
● JAX-RS
● CDI
● JSON-P.
@CesarHgt @tomitribeJavaDay Ecuador 2018
Moviefun Diagrama de Despliegue
Gateway
@CesarHgt @tomitribeJavaDay Ecuador 2018
Incluyendo Microprofile JWT en
una aplicación JAX-RS
@CesarHgt @tomitribeJavaDay Ecuador 2018
● @LoginConfig
● web.xml login-config
element equivalent
package org.superbiz.moviefun.rest;
import org.eclipse.microprofile.auth.LoginConfig;
import javax.ws.rs.ApplicationPath;
import javax.ws.rs.core.Application;
@ApplicationPath("/rest")
@LoginConfig(authMethod = "MP-JWT")
public class ApplicationConfig extends Application {
// let the server discover the endpoints
}
ApplicationConfig.java
@CesarHgt @tomitribeJavaDay Ecuador 2018
Mapeando MP-JWT Tokens con
Java EE Container APIs
@CesarHgt @tomitribeJavaDay Ecuador 2018
● Injection of the currently
authenticated caller
● Injection of claims
@Path("movies")
@Produces({"application/json"})
@ApplicationScoped
public class MoviesResource {
@Inject
private JsonWebToken jwtPrincipal;
@Inject
@Claim("email")
private ClaimValue<String> email;
MoviesResource.java
@CesarHgt @tomitribeJavaDay Ecuador 2018
Integración con
JAX-RS Container API
@CesarHgt @tomitribeJavaDay Ecuador 2018
● securityContext.isUserInRole
● MP-JWT "groups" claim
● getUserPrincipal()
import javax.ws.rs.core.SecurityContext;
@Path("movies")
@Produces({"application/json"})
@ApplicationScoped
public class MoviesResource {
@Context
private SecurityContext securityContext;
@POST
@Consumes("application/json")
public Movie addMovie(Movie movie) {
if (!securityContext.isUserInRole("create")) {
throw new WebApplicationException("Bad permission.",
Response.Status.FORBIDDEN);
}
service.addMovie(movie);
return movie;
}
MoviesResource.java
@CesarHgt @tomitribeJavaDay Ecuador 2018
● @RolesAllowed
● @PermitAll
● @DenyAll
● 2.9 - 2.12 JSR-250
@PUT
@Path("{id}")
@Consumes("application/json")
@RolesAllowed("update")
public Movie editMovie( @PathParam("id") final long id,
Movie movie) {
....
return movie;
}
@DELETE
@Path("{id}")
@RolesAllowed("delete")
public void deleteMovie(@PathParam("id") long id) {
....
service.deleteMovie(id);
}
MoviesResource.java
@CesarHgt @tomitribeJavaDay Ecuador 2018
Public Key Configuration
@CesarHgt @tomitribeJavaDay Ecuador 2018
@Produces
Optional<JWTAuthContextInfo> getOptionalContextInfo() throws Exception {
JWTAuthContextInfo contextInfo = new JWTAuthContextInfo();
contextInfo.setIssuedBy("/oauth2/token");
byte[] encodedBytes = TokenUtil.readPublicKey("/publicKey.pem").getEncoded();
final X509EncodedKeySpec spec = new X509EncodedKeySpec(encodedBytes);
final KeyFactory kf = KeyFactory.getInstance("RSA");
final RSAPublicKey pk = (RSAPublicKey) kf.generatePublic(spec);
contextInfo.setSignerKey(pk);
contextInfo.setExpGracePeriodSecs(10);
return Optional.of(contextInfo);
}
@Produces
JWTAuthContextInfo getContextInfo() throws Exception { return getOptionalContextInfo().get(); }
}
MoviesMPJWTConfigurationProvider.java
@CesarHgt @tomitribeJavaDay Ecuador 2018
https://tribestream.io/javadayec/
Gracias
CONTACTANOS @TOMITRIBE

Weitere ähnliche Inhalte

Was ist angesagt?

Example Mapping in the Wild
Example Mapping in the WildExample Mapping in the Wild
Example Mapping in the WildCeri Shaw
 
Oracle APEX Performance
Oracle APEX PerformanceOracle APEX Performance
Oracle APEX PerformanceScott Wesley
 
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...Ambassador Labs
 
Code Security with GitHub Advanced Security
Code Security with GitHub Advanced SecurityCode Security with GitHub Advanced Security
Code Security with GitHub Advanced SecurityLuis Fraile
 
Oracle Forms to APEX conversion tool
Oracle Forms to APEX conversion toolOracle Forms to APEX conversion tool
Oracle Forms to APEX conversion toolScott Wesley
 
Infraestructura como codigo
Infraestructura como codigoInfraestructura como codigo
Infraestructura como codigoangelrengifo
 
Introduction to CICD
Introduction to CICDIntroduction to CICD
Introduction to CICDKnoldus Inc.
 
Atlassian Bamboo Feature Overview
Atlassian Bamboo Feature OverviewAtlassian Bamboo Feature Overview
Atlassian Bamboo Feature OverviewJim Bethancourt
 
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021AWSKRUG - AWS한국사용자모임
 
Oracle Application Testing Suite. Competitive Edge
Oracle Application Testing Suite. Competitive EdgeOracle Application Testing Suite. Competitive Edge
Oracle Application Testing Suite. Competitive EdgeMaija Laksa
 
Microservices & API Gateways
Microservices & API Gateways Microservices & API Gateways
Microservices & API Gateways Kong Inc.
 
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.Open Source Consulting
 
Build CICD Pipeline for Container Presentation Slides
Build CICD Pipeline for Container Presentation SlidesBuild CICD Pipeline for Container Presentation Slides
Build CICD Pipeline for Container Presentation SlidesAmazon Web Services
 
Getting started with Jenkins
Getting started with JenkinsGetting started with Jenkins
Getting started with JenkinsEdureka!
 
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항rockplace
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basicsManav Prasad
 

Was ist angesagt? (20)

Example Mapping in the Wild
Example Mapping in the WildExample Mapping in the Wild
Example Mapping in the Wild
 
Oracle APEX Performance
Oracle APEX PerformanceOracle APEX Performance
Oracle APEX Performance
 
Nginx
NginxNginx
Nginx
 
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...
Building Microservice Systems Without Cooking Your Laptop: Going “Remocal” wi...
 
Code Security with GitHub Advanced Security
Code Security with GitHub Advanced SecurityCode Security with GitHub Advanced Security
Code Security with GitHub Advanced Security
 
Oracle Forms to APEX conversion tool
Oracle Forms to APEX conversion toolOracle Forms to APEX conversion tool
Oracle Forms to APEX conversion tool
 
Infraestructura como codigo
Infraestructura como codigoInfraestructura como codigo
Infraestructura como codigo
 
Introduction to CICD
Introduction to CICDIntroduction to CICD
Introduction to CICD
 
Atlassian Bamboo Feature Overview
Atlassian Bamboo Feature OverviewAtlassian Bamboo Feature Overview
Atlassian Bamboo Feature Overview
 
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021
AWS와 함께하는 무중단 배포 파이프라인 개선기 - 황성찬 (AUSG) :: AWS Community Day Online 2021
 
Oracle Application Testing Suite. Competitive Edge
Oracle Application Testing Suite. Competitive EdgeOracle Application Testing Suite. Competitive Edge
Oracle Application Testing Suite. Competitive Edge
 
Microservices & API Gateways
Microservices & API Gateways Microservices & API Gateways
Microservices & API Gateways
 
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.
쿠버네티스 기반 PaaS 솔루션 - Playce Kube를 소개합니다.
 
Build CICD Pipeline for Container Presentation Slides
Build CICD Pipeline for Container Presentation SlidesBuild CICD Pipeline for Container Presentation Slides
Build CICD Pipeline for Container Presentation Slides
 
DevOps on AWS
DevOps on AWSDevOps on AWS
DevOps on AWS
 
Getting started with Jenkins
Getting started with JenkinsGetting started with Jenkins
Getting started with Jenkins
 
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항
왜 컨테이너인가? - OpenShift 구축 사례와 컨테이너로 환경 전환 시 고려사항
 
Feature toggles
Feature togglesFeature toggles
Feature toggles
 
Unix shell scripting basics
Unix shell scripting basicsUnix shell scripting basics
Unix shell scripting basics
 
Laravel overview
Laravel overviewLaravel overview
Laravel overview
 

Ähnlich wie Seguridad en microservicios via micro profile jwt

Stateless Microservice Security via JWT and MicroProfile - Mexico
Stateless Microservice Security via JWT and MicroProfile - MexicoStateless Microservice Security via JWT and MicroProfile - Mexico
Stateless Microservice Security via JWT and MicroProfile - MexicoOtávio Santana
 
Stateless Microservice Security via JWT and MicroProfile - ES
Stateless Microservice Security via JWT and MicroProfile - ES Stateless Microservice Security via JWT and MicroProfile - ES
Stateless Microservice Security via JWT and MicroProfile - ES Otavio Santana
 
Stateless Microservice Security via JWT and MicroProfile - Guatemala
Stateless Microservice Security via JWT and MicroProfile - GuatemalaStateless Microservice Security via JWT and MicroProfile - Guatemala
Stateless Microservice Security via JWT and MicroProfile - GuatemalaOtávio Santana
 
2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest
2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest
2018 colombia deconstruyendo y evolucionando la seguridad en servicios restCésar Hernández
 
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios restCésar Hernández
 
2018 Madrid JUG Deconstructing REST Security
2018 Madrid JUG Deconstructing REST Security2018 Madrid JUG Deconstructing REST Security
2018 Madrid JUG Deconstructing REST SecurityBruno Baptista
 
Deconstructing and Evolving REST security
Deconstructing and Evolving REST securityDeconstructing and Evolving REST security
Deconstructing and Evolving REST securityJonathan Gallimore
 
2018 Denver JUG Deconstructing and Evolving REST Security
2018 Denver JUG Deconstructing and Evolving REST Security2018 Denver JUG Deconstructing and Evolving REST Security
2018 Denver JUG Deconstructing and Evolving REST SecurityDavid Blevins
 
2018 jPrime Deconstructing and Evolving REST Security
2018 jPrime Deconstructing and Evolving REST Security2018 jPrime Deconstructing and Evolving REST Security
2018 jPrime Deconstructing and Evolving REST SecurityDavid Blevins
 
2017 Devoxx MA Deconstructing and Evolving REST Security
2017 Devoxx MA Deconstructing and Evolving REST Security2017 Devoxx MA Deconstructing and Evolving REST Security
2017 Devoxx MA Deconstructing and Evolving REST SecurityDavid Blevins
 
2017 JavaOne Deconstructing and Evolving REST Security
2017 JavaOne Deconstructing and Evolving REST Security2017 JavaOne Deconstructing and Evolving REST Security
2017 JavaOne Deconstructing and Evolving REST SecurityDavid Blevins
 
2018 SDJUG Deconstructing and Evolving REST Security
2018 SDJUG Deconstructing and Evolving REST Security2018 SDJUG Deconstructing and Evolving REST Security
2018 SDJUG Deconstructing and Evolving REST SecurityDavid Blevins
 
2019 ITkonekt Stateless REST Security with MicroProfile JWT
2019 ITkonekt Stateless REST Security with MicroProfile JWT2019 ITkonekt Stateless REST Security with MicroProfile JWT
2019 ITkonekt Stateless REST Security with MicroProfile JWTJean-Louis MONTEIRO
 
2018 Boulder JUG Deconstructing and Evolving REST Security
2018 Boulder JUG Deconstructing and Evolving REST Security2018 Boulder JUG Deconstructing and Evolving REST Security
2018 Boulder JUG Deconstructing and Evolving REST SecurityDavid Blevins
 
2018 IterateConf Deconstructing and Evolving REST Security
2018 IterateConf Deconstructing and Evolving REST Security2018 IterateConf Deconstructing and Evolving REST Security
2018 IterateConf Deconstructing and Evolving REST SecurityDavid Blevins
 
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfile
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfileDublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfile
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfileJean-Louis MONTEIRO
 
2018 JavaLand Deconstructing and Evolving REST Security
2018 JavaLand Deconstructing and Evolving REST Security2018 JavaLand Deconstructing and Evolving REST Security
2018 JavaLand Deconstructing and Evolving REST SecurityDavid Blevins
 
2016 JavaOne Deconstructing REST Security
2016 JavaOne Deconstructing REST Security2016 JavaOne Deconstructing REST Security
2016 JavaOne Deconstructing REST SecurityDavid Blevins
 
How OAuth and portable data can revolutionize your web app - Chris Messina
How OAuth and portable data can revolutionize your web app - Chris MessinaHow OAuth and portable data can revolutionize your web app - Chris Messina
How OAuth and portable data can revolutionize your web app - Chris MessinaCarsonified Team
 

Ähnlich wie Seguridad en microservicios via micro profile jwt (20)

Stateless Microservice Security via JWT and MicroProfile - Mexico
Stateless Microservice Security via JWT and MicroProfile - MexicoStateless Microservice Security via JWT and MicroProfile - Mexico
Stateless Microservice Security via JWT and MicroProfile - Mexico
 
Stateless Microservice Security via JWT and MicroProfile - ES
Stateless Microservice Security via JWT and MicroProfile - ES Stateless Microservice Security via JWT and MicroProfile - ES
Stateless Microservice Security via JWT and MicroProfile - ES
 
Stateless Microservice Security via JWT and MicroProfile - Guatemala
Stateless Microservice Security via JWT and MicroProfile - GuatemalaStateless Microservice Security via JWT and MicroProfile - Guatemala
Stateless Microservice Security via JWT and MicroProfile - Guatemala
 
2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest
2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest
2018 colombia deconstruyendo y evolucionando la seguridad en servicios rest
 
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest
2018 ecuador deconstruyendo y evolucionando la seguridad en servicios rest
 
2018 Madrid JUG Deconstructing REST Security
2018 Madrid JUG Deconstructing REST Security2018 Madrid JUG Deconstructing REST Security
2018 Madrid JUG Deconstructing REST Security
 
Deconstructing and Evolving REST security
Deconstructing and Evolving REST securityDeconstructing and Evolving REST security
Deconstructing and Evolving REST security
 
2018 Denver JUG Deconstructing and Evolving REST Security
2018 Denver JUG Deconstructing and Evolving REST Security2018 Denver JUG Deconstructing and Evolving REST Security
2018 Denver JUG Deconstructing and Evolving REST Security
 
2018 jPrime Deconstructing and Evolving REST Security
2018 jPrime Deconstructing and Evolving REST Security2018 jPrime Deconstructing and Evolving REST Security
2018 jPrime Deconstructing and Evolving REST Security
 
2017 Devoxx MA Deconstructing and Evolving REST Security
2017 Devoxx MA Deconstructing and Evolving REST Security2017 Devoxx MA Deconstructing and Evolving REST Security
2017 Devoxx MA Deconstructing and Evolving REST Security
 
2017 JavaOne Deconstructing and Evolving REST Security
2017 JavaOne Deconstructing and Evolving REST Security2017 JavaOne Deconstructing and Evolving REST Security
2017 JavaOne Deconstructing and Evolving REST Security
 
2018 SDJUG Deconstructing and Evolving REST Security
2018 SDJUG Deconstructing and Evolving REST Security2018 SDJUG Deconstructing and Evolving REST Security
2018 SDJUG Deconstructing and Evolving REST Security
 
2019 ITkonekt Stateless REST Security with MicroProfile JWT
2019 ITkonekt Stateless REST Security with MicroProfile JWT2019 ITkonekt Stateless REST Security with MicroProfile JWT
2019 ITkonekt Stateless REST Security with MicroProfile JWT
 
2018 Boulder JUG Deconstructing and Evolving REST Security
2018 Boulder JUG Deconstructing and Evolving REST Security2018 Boulder JUG Deconstructing and Evolving REST Security
2018 Boulder JUG Deconstructing and Evolving REST Security
 
2018 IterateConf Deconstructing and Evolving REST Security
2018 IterateConf Deconstructing and Evolving REST Security2018 IterateConf Deconstructing and Evolving REST Security
2018 IterateConf Deconstructing and Evolving REST Security
 
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfile
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfileDublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfile
Dublin JUG Stateless Microservice Security via JWT, TomEE and MicroProfile
 
2018 JavaLand Deconstructing and Evolving REST Security
2018 JavaLand Deconstructing and Evolving REST Security2018 JavaLand Deconstructing and Evolving REST Security
2018 JavaLand Deconstructing and Evolving REST Security
 
2016 JavaOne Deconstructing REST Security
2016 JavaOne Deconstructing REST Security2016 JavaOne Deconstructing REST Security
2016 JavaOne Deconstructing REST Security
 
OAuth FTW
OAuth FTWOAuth FTW
OAuth FTW
 
How OAuth and portable data can revolutionize your web app - Chris Messina
How OAuth and portable data can revolutionize your web app - Chris MessinaHow OAuth and portable data can revolutionize your web app - Chris Messina
How OAuth and portable data can revolutionize your web app - Chris Messina
 

Mehr von César Hernández

7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...César Hernández
 
Paving the road with Jakarta EE and Apache TomEE - JCON 2021
Paving the road with Jakarta EE  and Apache TomEE - JCON 2021Paving the road with Jakarta EE  and Apache TomEE - JCON 2021
Paving the road with Jakarta EE and Apache TomEE - JCON 2021César Hernández
 
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...César Hernández
 
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]Keeping brazil's medical industry safe with Micro Profile [TDC 2021]
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]César Hernández
 
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021César Hernández
 
Paving the way with Jakarta EE and Apache TomEE - JCConf
Paving the way with Jakarta EE  and Apache TomEE - JCConfPaving the way with Jakarta EE  and Apache TomEE - JCConf
Paving the way with Jakarta EE and Apache TomEE - JCConfCésar Hernández
 
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...César Hernández
 
Pavimentando el camino con Jakarta EE 9 y Apache TomEE
Pavimentando el camino con Jakarta EE 9 y Apache TomEE Pavimentando el camino con Jakarta EE 9 y Apache TomEE
Pavimentando el camino con Jakarta EE 9 y Apache TomEE César Hernández
 
It is easy contributing to open source - JCON 2020
It is easy contributing to open source - JCON 2020It is easy contributing to open source - JCON 2020
It is easy contributing to open source - JCON 2020César Hernández
 
It is easy contributing to Open Source - ECLIPSE CON 2020
It is easy contributing to Open Source - ECLIPSE CON 2020It is easy contributing to Open Source - ECLIPSE CON 2020
It is easy contributing to Open Source - ECLIPSE CON 2020César Hernández
 
Paving the way with Jakarta EE and apache TomEE at cloudconferenceday
Paving the way with Jakarta EE and apache TomEE at cloudconferencedayPaving the way with Jakarta EE and apache TomEE at cloudconferenceday
Paving the way with Jakarta EE and apache TomEE at cloudconferencedayCésar Hernández
 
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0César Hernández
 
Creando microservicios con java micro profile y tomee - CUNORI 2020
Creando microservicios con java micro profile y tomee - CUNORI 2020Creando microservicios con java micro profile y tomee - CUNORI 2020
Creando microservicios con java micro profile y tomee - CUNORI 2020César Hernández
 
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020César Hernández
 
Creando microservicios con Java MicroProfile y TomEE - OGBT
Creando microservicios con Java MicroProfile y TomEE  - OGBTCreando microservicios con Java MicroProfile y TomEE  - OGBT
Creando microservicios con Java MicroProfile y TomEE - OGBTCésar Hernández
 
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUG
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUGCreando microservicios con Java, Microprofile y TomEE - Baranquilla JUG
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUGCésar Hernández
 
Creando microservicios con Java y Microprofile - Nicaragua JUG
Creando microservicios con Java y Microprofile - Nicaragua JUGCreando microservicios con Java y Microprofile - Nicaragua JUG
Creando microservicios con Java y Microprofile - Nicaragua JUGCésar Hernández
 
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...César Hernández
 
Es fácil contribuir al open source - Bolivia JUG 2020
Es fácil contribuir al open source - Bolivia JUG 2020Es fácil contribuir al open source - Bolivia JUG 2020
Es fácil contribuir al open source - Bolivia JUG 2020César Hernández
 
Its easy! contributing to open source - Devnexus 2020
Its easy! contributing to open source - Devnexus 2020Its easy! contributing to open source - Devnexus 2020
Its easy! contributing to open source - Devnexus 2020César Hernández
 

Mehr von César Hernández (20)

7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 Recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
 
Paving the road with Jakarta EE and Apache TomEE - JCON 2021
Paving the road with Jakarta EE  and Apache TomEE - JCON 2021Paving the road with Jakarta EE  and Apache TomEE - JCON 2021
Paving the road with Jakarta EE and Apache TomEE - JCON 2021
 
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
7 recomendaciones para migrar tus aplicaciones a Jakarta EE utilizando Apache...
 
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]Keeping brazil's medical industry safe with Micro Profile [TDC 2021]
Keeping brazil's medical industry safe with Micro Profile [TDC 2021]
 
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021
Aprende, contribuye, y surfea Cloud Native Java - GuateJUG 2021
 
Paving the way with Jakarta EE and Apache TomEE - JCConf
Paving the way with Jakarta EE  and Apache TomEE - JCConfPaving the way with Jakarta EE  and Apache TomEE - JCConf
Paving the way with Jakarta EE and Apache TomEE - JCConf
 
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
 
Pavimentando el camino con Jakarta EE 9 y Apache TomEE
Pavimentando el camino con Jakarta EE 9 y Apache TomEE Pavimentando el camino con Jakarta EE 9 y Apache TomEE
Pavimentando el camino con Jakarta EE 9 y Apache TomEE
 
It is easy contributing to open source - JCON 2020
It is easy contributing to open source - JCON 2020It is easy contributing to open source - JCON 2020
It is easy contributing to open source - JCON 2020
 
It is easy contributing to Open Source - ECLIPSE CON 2020
It is easy contributing to Open Source - ECLIPSE CON 2020It is easy contributing to Open Source - ECLIPSE CON 2020
It is easy contributing to Open Source - ECLIPSE CON 2020
 
Paving the way with Jakarta EE and apache TomEE at cloudconferenceday
Paving the way with Jakarta EE and apache TomEE at cloudconferencedayPaving the way with Jakarta EE and apache TomEE at cloudconferenceday
Paving the way with Jakarta EE and apache TomEE at cloudconferenceday
 
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0
Pavimentando el Camino con Jakarta EE 9 y Apache TomEE 9.0.0
 
Creando microservicios con java micro profile y tomee - CUNORI 2020
Creando microservicios con java micro profile y tomee - CUNORI 2020Creando microservicios con java micro profile y tomee - CUNORI 2020
Creando microservicios con java micro profile y tomee - CUNORI 2020
 
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020
Paving the way with Jakarta EE and Apache TomEE - itkonekt 2020
 
Creando microservicios con Java MicroProfile y TomEE - OGBT
Creando microservicios con Java MicroProfile y TomEE  - OGBTCreando microservicios con Java MicroProfile y TomEE  - OGBT
Creando microservicios con Java MicroProfile y TomEE - OGBT
 
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUG
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUGCreando microservicios con Java, Microprofile y TomEE - Baranquilla JUG
Creando microservicios con Java, Microprofile y TomEE - Baranquilla JUG
 
Creando microservicios con Java y Microprofile - Nicaragua JUG
Creando microservicios con Java y Microprofile - Nicaragua JUGCreando microservicios con Java y Microprofile - Nicaragua JUG
Creando microservicios con Java y Microprofile - Nicaragua JUG
 
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
Keeping brazil's medical industry safe with Micro Profile and JakartaEE - Jak...
 
Es fácil contribuir al open source - Bolivia JUG 2020
Es fácil contribuir al open source - Bolivia JUG 2020Es fácil contribuir al open source - Bolivia JUG 2020
Es fácil contribuir al open source - Bolivia JUG 2020
 
Its easy! contributing to open source - Devnexus 2020
Its easy! contributing to open source - Devnexus 2020Its easy! contributing to open source - Devnexus 2020
Its easy! contributing to open source - Devnexus 2020
 

Kürzlich hochgeladen

ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty SecureFemke de Vroome
 
Intro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераIntro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераMark Opanasiuk
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsStefano
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?Mark Billinghurst
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe中 央社
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomCzechDreamin
 
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlPeter Udo Diehl
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfFIDO Alliance
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessUXDXConf
 
WebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceWebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceSamy Fodil
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGDSC PJATK
 
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...CzechDreamin
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaCzechDreamin
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireExakis Nelite
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastUXDXConf
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Julian Hyde
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...FIDO Alliance
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...CzechDreamin
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...panagenda
 

Kürzlich hochgeladen (20)

ECS 2024 Teams Premium - Pretty Secure
ECS 2024   Teams Premium - Pretty SecureECS 2024   Teams Premium - Pretty Secure
ECS 2024 Teams Premium - Pretty Secure
 
Intro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераIntro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджера
 
PLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. StartupsPLAI - Acceleration Program for Generative A.I. Startups
PLAI - Acceleration Program for Generative A.I. Startups
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
Portal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russePortal Kombat : extension du réseau de propagande russe
Portal Kombat : extension du réseau de propagande russe
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo DiehlFuture Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
Future Visions: Predictions to Guide and Time Tech Innovation, Peter Udo Diehl
 
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdfWhere to Learn More About FDO _ Richard at FIDO Alliance.pdf
Where to Learn More About FDO _ Richard at FIDO Alliance.pdf
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
 
Overview of Hyperledger Foundation
Overview of Hyperledger FoundationOverview of Hyperledger Foundation
Overview of Hyperledger Foundation
 
WebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM PerformanceWebAssembly is Key to Better LLM Performance
WebAssembly is Key to Better LLM Performance
 
Google I/O Extended 2024 Warsaw
Google I/O Extended 2024 WarsawGoogle I/O Extended 2024 Warsaw
Google I/O Extended 2024 Warsaw
 
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara Laskowska
 
Microsoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - QuestionnaireMicrosoft CSP Briefing Pre-Engagement - Questionnaire
Microsoft CSP Briefing Pre-Engagement - Questionnaire
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at Comcast
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
 
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
Choosing the Right FDO Deployment Model for Your Application _ Geoffrey at In...
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
Easier, Faster, and More Powerful – Alles Neu macht der Mai -Wir durchleuchte...
 

Seguridad en microservicios via micro profile jwt

  • 1. @CesarHgt @tomitribeJavaDay Ecuador 2018 Seguridad en Microservicios via Microprofile JWT César Hernández Tomitribe
  • 2. @CesarHgt @tomitribeJavaDay Ecuador 2018 ● Senior Software Engineer at Tomitribe ● Java Champion ● Ducke’s Choice Award 2016, 2017 ● Oracle Certified Professional ● +10 experience with Java EE ● Eclipse Commiter: Jakarta EE TCK, JAX-WS and Microprofile. ● Open Source advocate, teacher and public speaker César Hernández
  • 3. @CesarHgt @tomitribeJavaDay Ecuador 2018 Java es Comunidad
  • 4. @CesarHgt @tomitribeJavaDay Ecuador 2018 https://tribestream.io/javadayec/ Diapositivas y referencias CONTACTANOS @TOMITRIBE
  • 5. @CesarHgt @tomitribeJavaDay Ecuador 2018 “Lo mejor de los estándares es que terminas teniendo muchas opciones por escoger.” - Andrew S. Tanenbaum
  • 6. @CesarHgt @tomitribeJavaDay Ecuador 2018 Opciones de seguridad para Microservicios ● Más allá de Basic Auth ● Teoría de OAuth 2.0 ● Introducción a JWT ● Eclipse Microprofile ● Demo
  • 7. @CesarHgt @tomitribeJavaDay Ecuador 2018 Línea Base 1000 usuarios x 3 TPS 4 saltos 3000 TPS frontend 12000 TPS backend
  • 8. @CesarHgt @tomitribeJavaDay Ecuador 2018 Basic Auth (y sus problemas)
  • 9. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje en Basic Auth POST /painter/color/object HTTP/1.1 Host: localhost:8443 Authorization: Basic c25vb3B5OnBhc3M= User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 45 {"color":{"b":255,"g":0,"name":"blue","r":0}}
  • 10. @CesarHgt @tomitribeJavaDay Ecuador 2018 Basic Auth Password Sent 3000 TPS (HTTP+SSL) username+password Base64 (no auth) (LDAP) 12000 TPS (HTTP) 3000 TPS
  • 11. @CesarHgt @tomitribeJavaDay Ecuador 2018 Basic Auth Password Sent 3000 TPS (HTTP+SSL) username+password Base64 Lista Blanca de IP 3000 TPS (LDAP) 12000 TPS (HTTP)
  • 12. @CesarHgt @tomitribeJavaDay Ecuador 2018 “Dame toda la información del salario de José.” “No se quien eres, … pero por supuesto!”
  • 13. @CesarHgt @tomitribeJavaDay Ecuador 2018 Ataque de fuerza bruta: Basic Auth Password válidos 3000 TPS (HTTP+SSL) Lista Blanca IP 9000 TPS (LDAP) 12000 TPS (HTTP) Passwords inválidos 6000 TPS (HTTP+SSL)
  • 14. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2.0 (y sus problemas)
  • 19. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Password Grant (LDAP) (Repositorio de Token) Verificación de Password Generación de Token Post /oauth2/token Host: api.superbliz.io User-Agent: curl/7.43.0 Accept: */* Content-Type: application/x-www-form-urlencoded Content-Length: 54 grand_type=password&username=snoopy&password=woodstock
  • 20. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Password Grant (LDAP) Verificación de Password Generación de Token (Repositorio de Token) Post /oauth2/token Host: api.superbliz.io User-Agent: curl/7.43.0 Accept: */* Content-Type: application/x-www-form-urlencoded Content-Length: 54 grand_type=password&username=snoopy&password=woodstock
  • 21. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/object HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 45 {"color":{"r":0,"g":0,"b":255,"name":"blue"}}
  • 22. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/palette HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 45 {"color":{"r":0,"g":255,"b":0,"name":"green"}}
  • 23. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/select HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 44 {"color":{"r":255,"g":0,"b":0,"name":"red"}}
  • 24. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/fill HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 49 {"color":{"r":0,"g":255,"b":255,"name":"yellow"}}
  • 25. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/stroke HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 49 {"color":{"r":255,"g":200,"b":255,"name":"orange"}}
  • 27. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Refresh Grant (LDAP) Verificación Password Generación Token (Repositorio de Token) Post /oauth2/token Host: api.superbliz.io User-Agent: curl/7.43.0 Accept: */* Content-Type: application/x-www-form-urlencoded Content-Length: 54 grand_type=password&username=snoopy&password=woodstock
  • 28. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Refresh Grant (LDAP) Verificación Password Generación Token (Repositorio de Token) Post /oauth2/token Host: api.superbliz.io User-Agent: curl/7.43.0 Accept: */* Content-Type: application/x-www-form-urlencoded Content-Length: 54 grand_type=password&username=snoopy&password=woodstock
  • 29. @CesarHgt @tomitribeJavaDay Ecuador 2018 Par anterior ∙ Access Token 2YotnFZFEjr1zCsicMWpAA ∙ Refresh Token tGzv3JOkF0XG5Qx2TlKWIA Nuevo Par ∙ Access Token 6Fe4jd7TmdE5yW2q0y6W2w ∙ Refresh Token hyT5rw1QNh5Ttg2hdtR54e
  • 30. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/palette HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 46 {"color":{"r":0,"g":255,"b":0,"name":"green"}}
  • 31. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/select HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 44 {"color":{"r":255,"g":0,"b":0,"name":"red"}}
  • 32. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 POST /painter/color/fill HTTP/1.1 Host: api.superbiz.io Authorization: Bearer 6Fe4jd7TmdE5yW2q0y6W2w User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 49 {"color":{"r":0,"g":255,"b":255,"name":"yellow"}}
  • 33. @CesarHgt @tomitribeJavaDay Ecuador 2018 ¿Qué hemos logrado?
  • 34. @CesarHgt @tomitribeJavaDay Ecuador 2018 Ahora tenemos más passwords (al menos tus dispositivos los tienen)
  • 35. @CesarHgt @tomitribeJavaDay Ecuador 2018 Terminología de nuevo… ∙ Password Grant??? ∙ Logging in ∙ Token? ∙ Un password ligeramente ofuscado ∙ Equivalente a un HTTP session ID mejorado levemente
  • 36. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 Request enviados (Authorization: Bearer …) 3000 TPS (HTTP+SSL) 3000 TPS (Verificaciones de tokens) Password enviados (post oauth2/token …) 1000/daily (HTTP+SSL) OAuth 2 (LDAP) 4 saldos 12000 TPS backend
  • 38. @CesarHgt @tomitribeJavaDay Ecuador 2018 “Quién es 6Fe4jd7TmdE5y W2q0y6W2w ???????” “No tengo idea. Pregúntale al servidor de tokens.”
  • 39. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 Tokens enviados 3000 TPS (HTTP+SSL) 3000 TPS (verificación token) Password Envidados 1000/daily (HTTP+SSL) OAuth 2 (LDAP) 12000 TPS (Verificación token) 8 Saldos 24000 TPS backend
  • 40. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 3000 TPS (Verificación token) (LDAP) 12000 TPS (Verificación token) 55% del tráfico total Tokens enviados 3000 TPS (HTTP+SSL) Password Envidados 1000/daily (HTTP+SSL) OAuth 2 8 Saldos 24000 TPS backend
  • 41. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 Puntero Puntero Estado
  • 42. @CesarHgt @tomitribeJavaDay Ecuador 2018 Access Token Puntero de Acceso? Llave primaria de Acceso?
  • 43. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2.0 Algoritmo de intercambio de passwords de alta frecuencia?
  • 44. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2.0 + JSon Web Tokens (JWT)
  • 45. @CesarHgt @tomitribeJavaDay Ecuador 2018 JSon Web Token ∙ Pronunciado “YOT” ∙ JSON map con data de usuario ∙ Códificado Base64 ∙ Firmado digitalmente (RSA-SHA256, HMAC-SHA512, etc) ∙ Mecanismo de expiración
  • 46. @CesarHgt @tomitribeJavaDay Ecuador 2018 Previamente un Access Token ∙ 6Fe4jd7TmdE5yW2q0y6W2w
  • 47. @CesarHgt @tomitribeJavaDay Ecuador 2018 Access Token ahora (JWT) ∙ eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ0b2tlbi10eXBlIj oiYWNjZXNzLXRva2VuIiwidXNlcm5hbWUiOiJzbm9vcHkiLCJ hbmltYWwiOiJiZWFnbGUiLCJpc3MiOiJodHRwczovL2RlbW8 uc3VwZXJiaXouY29tL29hdXRoMi90b2tlbiIsInNjb3BlcyI6WyJ0 d2l0dGVyIiwibWFucy1iZXN0LWZyaWVuZCJdLCJleHAiOjE0 NzQyODA5NjMsImlhdCI6MTQ3NDI3OTE2MywianRpIjoiNjY4 ODFiMDY4YjI0OWFkOSJ9.DTfSdMzIIsC0j8z3icRdYO1GaM Gl6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vICc0hb4F0QCD 3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Ocxm1F5IUNZvz lLJ_ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYN o
  • 48. @CesarHgt @tomitribeJavaDay Ecuador 2018 Nuevo Access Token ∙ header (JSON > Base64 URL Encoded) ∙ Describe como la firma (signature) del token puede ser verificada ∙ payload (JSON > Base64 URL Encoded) ∙ Json map de información que desees incluir ∙ Campo estándar como el de Expiración ∙ signature (Binary > Base64 URL Encoded) ∙ La firma digital ∙ Hecha exclusivamente por el endpoint: /oauth2/token ∙ Si es RSA puede ser verificado por cualquier persona
  • 49. @CesarHgt @tomitribeJavaDay Ecuador 2018 ∙ { "alg": “RS256", "typ": “JWT" } ∙ { "token-type": "access-token", "username": "snoopy", "animal": "beagle", "iss": "https://demo.superbiz.com/oauth2/token", "scopes": [ “twitter”, "mans-best-friend" ], "exp": 1474280963, "iat": 1474279163, "jti": "66881b068b249ad9" } ∙ DTfSdMzIIsC0j8z3icRdYO1GaMGl6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vI Cc0hb4F0QCD3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Ocxm1F5IUNZvzlLJ _ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYNo
  • 52. @CesarHgt @tomitribeJavaDay Ecuador 2018 Ligero pero con alto impacto en la arquitectura
  • 53. @CesarHgt @tomitribeJavaDay Ecuador 2018 ¿Qué tenemos hasta el momento? (repaso)
  • 54. @CesarHgt @tomitribeJavaDay Ecuador 2018 Resultado final cliente permanece con el Pointer Server almacena State
  • 55. @CesarHgt @tomitribeJavaDay Ecuador 2018 ¿Qué podemos hacer ahora? (hola JWT!)
  • 56. @CesarHgt @tomitribeJavaDay Ecuador 2018 LDAP Data completa del usuario desde ldap
  • 57. @CesarHgt @tomitribeJavaDay Ecuador 2018 LDAP La data se representa en JSON
  • 58. @CesarHgt @tomitribeJavaDay Ecuador 2018 LDAP JSON es firmado RSA-SHA 256
  • 59. @CesarHgt @tomitribeJavaDay Ecuador 2018 LDAP Se inserta solamente el pointer en DB(para revocaciones)
  • 60. @CesarHgt @tomitribeJavaDay Ecuador 2018 LDAP Envío del Access Token (estado) hacia el cliente
  • 61. @CesarHgt @tomitribeJavaDay Ecuador 2018 Servidor almacena el Puntero Cliente permanece con el Estado Resultado obtenido
  • 62. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Password Grant (LDAP) (Repositorio Token ID) Verifica Password Genera Token Firmado (Signed) Post /oauth2/token Host: api.superbliz.io User-Agent: curl/7.43.0 Accept: */* Content-Type: application/x-www-form-urlencoded Content-Length: 54 grand_type=password&username=snoopy&password=woodstock
  • 63. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 - Password Grant (LDAP) Verifica Password (Repositorio Token ID) Genera Token Firmado (Signed)
  • 64. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mensaje OAuth 2.0 con JWT POST /painter/color/palette HTTP/1.1 Host: api.superbiz.io Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJ0b2tlbi10eXBlIjoiYWNjZXNzLXR va2VuIiwidXNlcm5hbWUiOiJzbm9vcHkiLCJhbmltYWwiOiJiZWFnbGUiLCJpc3MiOiJodHRwczovL2RlbW8 uc3VwZXJ iaXouY29tL29hdXRoMi90b2tlbiIsInNjb3BlcyI6WyJ0d2l0dGVyIiwibWFucy1iZXN0LWZyaWVuZCJdLCJleH AiOjE0NzQy ODA5NjMsImlhdCI6MTQ3NDI3OTE2MywianRpIjoiNjY4ODFiMDY4YjI0OWFkOSJ9.DTfSdMzIIsC0j8z3icRd YO1GaMGl 6j1I_2DBjiiHW9vmDz8OAw8Jh8DpO32fv0vICc0hb4F0QCD3KQnv8GVM73kSYaOEUwlW0k1TaElxc43_Oc xm1F5IUNZ vzlLJ_ksFXGDL_cuadhVDaiqmhct098ocefuv08TdzRxqYoEqYNo User-Agent: curl/7.43.0 Accept: */* Content-Type: application/json Content-Length: 46 {"color":{"b":0,"g":255,"r":0,"name":"green"}}
  • 65. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 + JWT Tokens enviados 3000 TPS (HTTP+SSL) 0.55 TPS (Verificaciones refresh token) OAuth 2 (LDAP) 4 saltos 12000 TPS backend 3000 TPS (verifica firma) 12000 TPS (verifica firma) Password enviados (post oauth2/token …) 1000/daily (HTTP+SSL)
  • 66. @CesarHgt @tomitribeJavaDay Ecuador 2018 “No!” “Dame toda la información del salario de José.”
  • 67. @CesarHgt @tomitribeJavaDay Ecuador 2018 “Claro!” “Dame toda la información del salario de José.”
  • 68. @CesarHgt @tomitribeJavaDay Ecuador 2018 OAuth 2 + JWT Envío de Tokens válidos 3000 TPS (HTTP+SSL) IP whitelisting 0.55 TPS (verifica refresh token) Password enviados 1000/daily (HTTP+SSL) (LDAP) 4 saltos 12000 TPS backend 9000 TPS (verifica firma) 12000 TPS (verifica firma) Token inválidos 6000 TPS (HTTP+SSL)
  • 69. @CesarHgt @tomitribeJavaDay Ecuador 2018 https://connect2id.com/products/nimbus-jose-jwt Librería JWT https://github.com/jwtk/jjwt https://github.com/auth0/java-jwt
  • 70. @CesarHgt @tomitribeJavaDay Ecuador 2018 Eclipse MicroProfile
  • 71. @CesarHgt @tomitribeJavaDay Ecuador 2018 MicroProfile ∙ Comunidad Open-Source de la fundación Eclipse ∙ Enfocada en Microservicios bajo JavaEE ∙ Generadora de: Specificaciones, API y TCK. ∙ Implementado por diferentes entidades http://microprofile.io/
  • 72. @CesarHgt @tomitribeJavaDay Ecuador 2018 MicroProfile JWT MicroProfile 2.0 JAX-RS 2.1JSON-P 1.1CDI 2.0 Config 1.3 Fault Tolerance 1.1 JWT RBAC 1.1 Health Check 1.0 Metrics 1.1 Open Tracing 1.1 Open API 1.0 Rest Client 1.1 JSON-B 1.0 JWT RBAC 1.1 https://microprofile.io/project/eclipse/microprofile-jwt-auth/ Estándares de Seguridad ● OAuth 2.0 ● OpenID Connect ● JSON Web Tokens (JWT) Tecnologías Java ● JAX-RS ● CDI ● JSON-P.
  • 73. @CesarHgt @tomitribeJavaDay Ecuador 2018 Moviefun Diagrama de Despliegue Gateway
  • 74. @CesarHgt @tomitribeJavaDay Ecuador 2018 Incluyendo Microprofile JWT en una aplicación JAX-RS
  • 75. @CesarHgt @tomitribeJavaDay Ecuador 2018 ● @LoginConfig ● web.xml login-config element equivalent package org.superbiz.moviefun.rest; import org.eclipse.microprofile.auth.LoginConfig; import javax.ws.rs.ApplicationPath; import javax.ws.rs.core.Application; @ApplicationPath("/rest") @LoginConfig(authMethod = "MP-JWT") public class ApplicationConfig extends Application { // let the server discover the endpoints } ApplicationConfig.java
  • 76. @CesarHgt @tomitribeJavaDay Ecuador 2018 Mapeando MP-JWT Tokens con Java EE Container APIs
  • 77. @CesarHgt @tomitribeJavaDay Ecuador 2018 ● Injection of the currently authenticated caller ● Injection of claims @Path("movies") @Produces({"application/json"}) @ApplicationScoped public class MoviesResource { @Inject private JsonWebToken jwtPrincipal; @Inject @Claim("email") private ClaimValue<String> email; MoviesResource.java
  • 78. @CesarHgt @tomitribeJavaDay Ecuador 2018 Integración con JAX-RS Container API
  • 79. @CesarHgt @tomitribeJavaDay Ecuador 2018 ● securityContext.isUserInRole ● MP-JWT "groups" claim ● getUserPrincipal() import javax.ws.rs.core.SecurityContext; @Path("movies") @Produces({"application/json"}) @ApplicationScoped public class MoviesResource { @Context private SecurityContext securityContext; @POST @Consumes("application/json") public Movie addMovie(Movie movie) { if (!securityContext.isUserInRole("create")) { throw new WebApplicationException("Bad permission.", Response.Status.FORBIDDEN); } service.addMovie(movie); return movie; } MoviesResource.java
  • 80. @CesarHgt @tomitribeJavaDay Ecuador 2018 ● @RolesAllowed ● @PermitAll ● @DenyAll ● 2.9 - 2.12 JSR-250 @PUT @Path("{id}") @Consumes("application/json") @RolesAllowed("update") public Movie editMovie( @PathParam("id") final long id, Movie movie) { .... return movie; } @DELETE @Path("{id}") @RolesAllowed("delete") public void deleteMovie(@PathParam("id") long id) { .... service.deleteMovie(id); } MoviesResource.java
  • 81. @CesarHgt @tomitribeJavaDay Ecuador 2018 Public Key Configuration
  • 82. @CesarHgt @tomitribeJavaDay Ecuador 2018 @Produces Optional<JWTAuthContextInfo> getOptionalContextInfo() throws Exception { JWTAuthContextInfo contextInfo = new JWTAuthContextInfo(); contextInfo.setIssuedBy("/oauth2/token"); byte[] encodedBytes = TokenUtil.readPublicKey("/publicKey.pem").getEncoded(); final X509EncodedKeySpec spec = new X509EncodedKeySpec(encodedBytes); final KeyFactory kf = KeyFactory.getInstance("RSA"); final RSAPublicKey pk = (RSAPublicKey) kf.generatePublic(spec); contextInfo.setSignerKey(pk); contextInfo.setExpGracePeriodSecs(10); return Optional.of(contextInfo); } @Produces JWTAuthContextInfo getContextInfo() throws Exception { return getOptionalContextInfo().get(); } } MoviesMPJWTConfigurationProvider.java
  • 83. @CesarHgt @tomitribeJavaDay Ecuador 2018 https://tribestream.io/javadayec/ Gracias CONTACTANOS @TOMITRIBE