SlideShare a Scribd company logo
1 of 28
Download to read offline
Setup Min.io and Open Policy Agent for
a multi-purpose scientific platform
D. Ciangottini, INFN
stackconf-2021 $ > whoami
● IT Researcher at Istituto Nazionale di Fisica
Nucleare (INFN)
○ Translated: National Institute of Nuclear Physics
● Involved on R&D activities to deploy cloud-native
solutions for the next-gen of data analysis
infrastructure for the INFN/LHC users
2
INFN community
3
The 5
research lines
and the National
Scientific
Committee
4
One of the main scientific challenges
understand the Universe in the first moments after the Big Ban
5
A community of
over 6,000
people
~ 25% of them have PhD grants,
post-doc scholarships and research
grants
6
INFN
facilities
Computing @INFN
Long tradition supporting experiments
For last 10 years, that was meant for supporting LHC
communities.
Quickly widening to many other use cases recently.
7
On-demand computing resources
for the INFN communities
● Easy access to on-demand solutions for scientific data analysis
● Composable services to extend and customize the environment
● Provide INFN users with a set of core tools centrally managed
○ E.g. JupyterHub-aaS, object storage, sync&share ....
● Federating the resources from several centers at national level
● Becoming the hub of reference for most of the activities and projects @ INFN
8
The INFN-Cloud initiative
The INFN-Cloud infrastructure
A backbone composed by the main
computing centers for central services
+ a federation of smaller sites
providing resources for user deployments
9
Computing challenges
Data storage for multiple communities
Providing a cloud storage hosted on the backbone infrastructure means:
● Geo-distributed storage federation
● Heterogeneous set of requirements
○ Object size (few MBs, to 10s GBs)
○ Workflow (imaging, columnar analysis...) and data access (posix, webdav, s3 etc..)
but it also means providing the tools:
● “F.A.I.R.” data
○ Findable, Accessible, Interoperable, Reusable
○ Make it intuitive or eventually transparent for the end user
● Focus on the “R.”! Allow sustainable reuse of data
10
Wrapping up...
Requirements
● Dynamic user registration/acls integrated with Indigo-IAM/OIDC
● Fine grain authz (ro, rw, per file/per user group )
● Easy and robust ops
○ gitOps eventually
● Accessible via posix
● WebUI access
● Vendor neutral
● Open source
11
Quick look to the solution
The components
● Minio has been chosen as the cloud
storage solution
○ S3 compliance
○ Powerful WebUI
○ Proven scalability
● Native integration with AWS STS
credentials
○ External OIDC IdP’s (e.g. Indigo IAM)
● Support for customizable authZ
policies with OpenPolicyAgent
12
User management
Indigo-IAM
● Authentication via SAML IdPs or identity
federations, OpenID Connect providers
and X.509 certificates
● Enrollment and registration
functionalities
○ so that users can join groups/collaborations
according to well-defined flows
○ provides services to manage group
membership
○ attributes assignment and account linking
functionality
● Integrable as IdP with any OIDC
compliant service
13
Cloud storage AuthN:
AWS STS credentials
● Endpoint service that enables clients to request temporary credentials for MinIO
resources
● AWS AssumeRoleWithWebIdentity flow is supported out of the box
○ Allowing the integration with any OpenID Connect-compatible identity provider ⇒ our IAM service
14
Cloud storage AuthZ:
OpenPolicyAgent integration
● A lightweight general-purpose policy
engine that can be co-located with
Minio server
● OPA HTTP API used to authorize Minio
STS credentials
○ Fine grain ACLs
■ Every token claim from authN can be
selected for policy checking
○ Dynamic config
○ Decoupled from the storage configuration
Example of an e2e AuthZ flow
16
OPA server checks custom
policies for the input
API
Policy example
# Allow users to manage their own data.
allow {
username := split(lower(input.claims.email),"@")[0]
input.bucket == username
input.claims.aud == "minio-auth"
permissions := rl_permissions["user"]
p := permissions[_]
p == {"action": input.action}
}
Authorized
JWT
List of operation permissions defined on OPA
"claims": {
"accessKey": "VP43M6DO1N53U2LUBTZ3",
"aud": "https://wlcg.cern.ch/jwt/v1/any",
"client_id":
"5c38c020-b753-4115-a5f4-3f48595e4c1b",
"exp": "1621714730",
"iat": 1621713801,
"iss": "https://login.cloud.infn.it",
"scope": "openid profile email",
"email": “ciangottini@infn.it”
}
Minio STS auth data
Managing policies with OPA bundles
the gitOps way
● OPA can periodically download bundles
of policy and data from remote HTTP
servers
○ Allowing for a gitOps based policy
management
● The policies and data are loaded on the
fly without requiring a restart of OPA
○ Policies and data are then applied immediately
17
So far so good…
Let’s put the hands on some user tools now!
18
Managing temporary credentials:
OIDC-agent
● A set of tools to manage OpenID Connect access tokens and make them
easily usable from the command line
○ ssh-agent design, so users can handle OIDC tokens in a similar way as they do with ssh keys
● Secure sensible information (long living credentials) while exposing short lived
ones (e.g. access token)
● Integrable via API libraries for: python, go and c++
19
POSIX access:
RClone + OIDC-Agent integration
To provide posix access we make use of RClone mount capability
A small patch has been applied to add a dedicated S3 provider integrated with
OIDC-Agent
Users, once oidc-agent is configured on its VM, can then mount its own bucket as a
folder with no further actions/authentication steps.
Backups via Restic are enabled through the use of this patched version of RClone
20
Make it easier:
STS-wire
21
For cases where the user does not/cannot run oidc-agent:
● a tool has been created to manage both the credential renewal and the rclone
mount in a guided/integrated/opinionated way
We found that to be the preferred solution to mount a bucket content on a laptop
for instance.
What about python?
boto3+STS+OIDC-Agent = boto3STS
Access Minio bucket through the
integration of boto library with
temporary credentials
- AWS STS token via IAM
- IAM access token get via
oidc-agent API
Instantiate an S3 session with a simple
line of code
22
Nice stuff! So, how did you do that?
23
Deployment models
● Generic centrally maintained service for each INFN user
○ HA K8s cluster on infrastructure backbone
○ FluxCD for gitOps operations
○ Central repo for OPA bundles
● On-demand cloud storage
○ Deploy the solution for a dedicated experiment/group of people
○ On prem or public cloud k8s instance as the ONLY requirement
○ Helm chart configurable via WebUI thanks to Kubeapps
24
Central service
FluxCD cluster
management
+
OPA bundles
___________
Full gitOps control
25
Self-managed k8s
- Ansible to bring up Kubeapps pointing to the supported INFN Helm charts
- Catalogue of pre configured apps already included
- Minio-Operator to deploy a Minio Tenant with STS credentials and OPA server
- Specifying custom OPA bundles endpoints and other similar configurations
26
● In production supporting physics and not only
○ (e.g. pandemic related research P.L.A.N.E.T.)
R&D continues toward:
● testing/scaling multi-cloud
● improving tools dedicated to data access and reuse
● try out Minio gateway cache instances to reduce latency
27
Wrapping up:
Summary and plans
Quick demo
28

More Related Content

What's hot

What's hot (20)

MinIO January 2020 Briefing
MinIO January 2020 BriefingMinIO January 2020 Briefing
MinIO January 2020 Briefing
 
Ceph scale testing with 10 Billion Objects
Ceph scale testing with 10 Billion ObjectsCeph scale testing with 10 Billion Objects
Ceph scale testing with 10 Billion Objects
 
Routed Provider Networks on OpenStack
Routed Provider Networks on OpenStack Routed Provider Networks on OpenStack
Routed Provider Networks on OpenStack
 
Patroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easyPatroni - HA PostgreSQL made easy
Patroni - HA PostgreSQL made easy
 
Apache Arrow: High Performance Columnar Data Framework
Apache Arrow: High Performance Columnar Data FrameworkApache Arrow: High Performance Columnar Data Framework
Apache Arrow: High Performance Columnar Data Framework
 
Oracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and conceptOracle 11g R2 RAC implementation and concept
Oracle 11g R2 RAC implementation and concept
 
Revisiting CephFS MDS and mClock QoS Scheduler
Revisiting CephFS MDS and mClock QoS SchedulerRevisiting CephFS MDS and mClock QoS Scheduler
Revisiting CephFS MDS and mClock QoS Scheduler
 
Securefile LOBs
Securefile LOBsSecurefile LOBs
Securefile LOBs
 
Logs/Metrics Gathering With OpenShift EFK Stack
Logs/Metrics Gathering With OpenShift EFK StackLogs/Metrics Gathering With OpenShift EFK Stack
Logs/Metrics Gathering With OpenShift EFK Stack
 
How to Use EXAchk Effectively to Manage Exadata Environments
How to Use EXAchk Effectively to Manage Exadata EnvironmentsHow to Use EXAchk Effectively to Manage Exadata Environments
How to Use EXAchk Effectively to Manage Exadata Environments
 
Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.Deep dive into PostgreSQL statistics.
Deep dive into PostgreSQL statistics.
 
Ceph issue 해결 사례
Ceph issue 해결 사례Ceph issue 해결 사례
Ceph issue 해결 사례
 
TripleOの光と闇
TripleOの光と闇TripleOの光と闇
TripleOの光と闇
 
ONIC-Japan-2019-OVN public
ONIC-Japan-2019-OVN publicONIC-Japan-2019-OVN public
ONIC-Japan-2019-OVN public
 
MySQL SQL Tutorial
MySQL SQL TutorialMySQL SQL Tutorial
MySQL SQL Tutorial
 
Performance Wins with BPF: Getting Started
Performance Wins with BPF: Getting StartedPerformance Wins with BPF: Getting Started
Performance Wins with BPF: Getting Started
 
Troubleshooting PostgreSQL Streaming Replication
Troubleshooting PostgreSQL Streaming ReplicationTroubleshooting PostgreSQL Streaming Replication
Troubleshooting PostgreSQL Streaming Replication
 
MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바
 
(BDT303) Running Spark and Presto on the Netflix Big Data Platform
(BDT303) Running Spark and Presto on the Netflix Big Data Platform(BDT303) Running Spark and Presto on the Netflix Big Data Platform
(BDT303) Running Spark and Presto on the Netflix Big Data Platform
 
Deep Dive on ClickHouse Sharding and Replication-2202-09-22.pdf
Deep Dive on ClickHouse Sharding and Replication-2202-09-22.pdfDeep Dive on ClickHouse Sharding and Replication-2202-09-22.pdf
Deep Dive on ClickHouse Sharding and Replication-2202-09-22.pdf
 

Similar to stackconf 2021 | Setup Min.io and Open Policy Agent for a multi purpose scientific platform

Catania Science Gateway Framework
Catania Science Gateway FrameworkCatania Science Gateway Framework
Catania Science Gateway Framework
riround
 

Similar to stackconf 2021 | Setup Min.io and Open Policy Agent for a multi purpose scientific platform (20)

DDDP 2019 - Brown to Green
DDDP 2019  - Brown to GreenDDDP 2019  - Brown to Green
DDDP 2019 - Brown to Green
 
Cloud Services On UI and Ideas for Federated Cloud on idREN
Cloud Services On UI and Ideas for Federated Cloud on idRENCloud Services On UI and Ideas for Federated Cloud on idREN
Cloud Services On UI and Ideas for Federated Cloud on idREN
 
CTE Phase III
CTE Phase IIICTE Phase III
CTE Phase III
 
Catania Science Gateway Framework
Catania Science Gateway FrameworkCatania Science Gateway Framework
Catania Science Gateway Framework
 
All Things Open SDN, NFV and Open Daylight
All Things Open SDN, NFV and Open Daylight All Things Open SDN, NFV and Open Daylight
All Things Open SDN, NFV and Open Daylight
 
The Enterprise Guide to Building a Data Mesh - Introducing SpecMesh
The Enterprise Guide to Building a Data Mesh - Introducing SpecMeshThe Enterprise Guide to Building a Data Mesh - Introducing SpecMesh
The Enterprise Guide to Building a Data Mesh - Introducing SpecMesh
 
Finalpresentation
FinalpresentationFinalpresentation
Finalpresentation
 
Framework for IoT Interoperability
Framework for IoT InteroperabilityFramework for IoT Interoperability
Framework for IoT Interoperability
 
Using IO Visor to Secure Microservices Running on CloudFoundry [OpenStack Sum...
Using IO Visor to Secure Microservices Running on CloudFoundry [OpenStack Sum...Using IO Visor to Secure Microservices Running on CloudFoundry [OpenStack Sum...
Using IO Visor to Secure Microservices Running on CloudFoundry [OpenStack Sum...
 
Building Open Source Identity Infrastructures
Building Open Source Identity InfrastructuresBuilding Open Source Identity Infrastructures
Building Open Source Identity Infrastructures
 
Google's Infrastructure and Specific IoT Services
Google's Infrastructure and Specific IoT ServicesGoogle's Infrastructure and Specific IoT Services
Google's Infrastructure and Specific IoT Services
 
OpenDaylight nluug_november
OpenDaylight nluug_novemberOpenDaylight nluug_november
OpenDaylight nluug_november
 
Cisco project ideas
Cisco   project ideasCisco   project ideas
Cisco project ideas
 
Day 13 - Creating Data Processing Services | Train the Trainers Program
Day 13 - Creating Data Processing Services | Train the Trainers ProgramDay 13 - Creating Data Processing Services | Train the Trainers Program
Day 13 - Creating Data Processing Services | Train the Trainers Program
 
Federated Cloud Computing
Federated Cloud ComputingFederated Cloud Computing
Federated Cloud Computing
 
Building IAM for OpenStack
Building IAM for OpenStackBuilding IAM for OpenStack
Building IAM for OpenStack
 
Red Hat Summit 2017 - LT107508 - Better Managing your Red Hat footprint with ...
Red Hat Summit 2017 - LT107508 - Better Managing your Red Hat footprint with ...Red Hat Summit 2017 - LT107508 - Better Managing your Red Hat footprint with ...
Red Hat Summit 2017 - LT107508 - Better Managing your Red Hat footprint with ...
 
Cloud as a GIFT: Exploiting Personal Cloud Free Accounts via Rest APIs
Cloud as a GIFT: Exploiting Personal Cloud Free Accounts via Rest APIsCloud as a GIFT: Exploiting Personal Cloud Free Accounts via Rest APIs
Cloud as a GIFT: Exploiting Personal Cloud Free Accounts via Rest APIs
 
Opensource tools for OpenStack IAAS
Opensource tools for OpenStack IAASOpensource tools for OpenStack IAAS
Opensource tools for OpenStack IAAS
 
DSD-INT 2016 Calibration and scenario generation of hydrodynamics and water -...
DSD-INT 2016 Calibration and scenario generation of hydrodynamics and water -...DSD-INT 2016 Calibration and scenario generation of hydrodynamics and water -...
DSD-INT 2016 Calibration and scenario generation of hydrodynamics and water -...
 

Recently uploaded

CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
shinachiaurasa2
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
mohitmore19
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
masabamasaba
 

Recently uploaded (20)

CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
%in Bahrain+277-882-255-28 abortion pills for sale in Bahrain
 
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdfThe Top App Development Trends Shaping the Industry in 2024-25 .pdf
The Top App Development Trends Shaping the Industry in 2024-25 .pdf
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
%in Lydenburg+277-882-255-28 abortion pills for sale in Lydenburg
%in Lydenburg+277-882-255-28 abortion pills for sale in Lydenburg%in Lydenburg+277-882-255-28 abortion pills for sale in Lydenburg
%in Lydenburg+277-882-255-28 abortion pills for sale in Lydenburg
 
Announcing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareAnnouncing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK Software
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
%+27788225528 love spells in Vancouver Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Vancouver Psychic Readings, Attraction spells,Br...%+27788225528 love spells in Vancouver Psychic Readings, Attraction spells,Br...
%+27788225528 love spells in Vancouver Psychic Readings, Attraction spells,Br...
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
 
10 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 202410 Trends Likely to Shape Enterprise Technology in 2024
10 Trends Likely to Shape Enterprise Technology in 2024
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisions
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
%in Stilfontein+277-882-255-28 abortion pills for sale in Stilfontein
 
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
%+27788225528 love spells in Colorado Springs Psychic Readings, Attraction sp...
 
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
%in Hazyview+277-882-255-28 abortion pills for sale in Hazyview
 

stackconf 2021 | Setup Min.io and Open Policy Agent for a multi purpose scientific platform

  • 1. Setup Min.io and Open Policy Agent for a multi-purpose scientific platform D. Ciangottini, INFN
  • 2. stackconf-2021 $ > whoami ● IT Researcher at Istituto Nazionale di Fisica Nucleare (INFN) ○ Translated: National Institute of Nuclear Physics ● Involved on R&D activities to deploy cloud-native solutions for the next-gen of data analysis infrastructure for the INFN/LHC users 2
  • 3. INFN community 3 The 5 research lines and the National Scientific Committee
  • 4. 4 One of the main scientific challenges understand the Universe in the first moments after the Big Ban
  • 5. 5 A community of over 6,000 people ~ 25% of them have PhD grants, post-doc scholarships and research grants
  • 7. Computing @INFN Long tradition supporting experiments For last 10 years, that was meant for supporting LHC communities. Quickly widening to many other use cases recently. 7
  • 8. On-demand computing resources for the INFN communities ● Easy access to on-demand solutions for scientific data analysis ● Composable services to extend and customize the environment ● Provide INFN users with a set of core tools centrally managed ○ E.g. JupyterHub-aaS, object storage, sync&share .... ● Federating the resources from several centers at national level ● Becoming the hub of reference for most of the activities and projects @ INFN 8 The INFN-Cloud initiative
  • 9. The INFN-Cloud infrastructure A backbone composed by the main computing centers for central services + a federation of smaller sites providing resources for user deployments 9
  • 10. Computing challenges Data storage for multiple communities Providing a cloud storage hosted on the backbone infrastructure means: ● Geo-distributed storage federation ● Heterogeneous set of requirements ○ Object size (few MBs, to 10s GBs) ○ Workflow (imaging, columnar analysis...) and data access (posix, webdav, s3 etc..) but it also means providing the tools: ● “F.A.I.R.” data ○ Findable, Accessible, Interoperable, Reusable ○ Make it intuitive or eventually transparent for the end user ● Focus on the “R.”! Allow sustainable reuse of data 10
  • 11. Wrapping up... Requirements ● Dynamic user registration/acls integrated with Indigo-IAM/OIDC ● Fine grain authz (ro, rw, per file/per user group ) ● Easy and robust ops ○ gitOps eventually ● Accessible via posix ● WebUI access ● Vendor neutral ● Open source 11
  • 12. Quick look to the solution The components ● Minio has been chosen as the cloud storage solution ○ S3 compliance ○ Powerful WebUI ○ Proven scalability ● Native integration with AWS STS credentials ○ External OIDC IdP’s (e.g. Indigo IAM) ● Support for customizable authZ policies with OpenPolicyAgent 12
  • 13. User management Indigo-IAM ● Authentication via SAML IdPs or identity federations, OpenID Connect providers and X.509 certificates ● Enrollment and registration functionalities ○ so that users can join groups/collaborations according to well-defined flows ○ provides services to manage group membership ○ attributes assignment and account linking functionality ● Integrable as IdP with any OIDC compliant service 13
  • 14. Cloud storage AuthN: AWS STS credentials ● Endpoint service that enables clients to request temporary credentials for MinIO resources ● AWS AssumeRoleWithWebIdentity flow is supported out of the box ○ Allowing the integration with any OpenID Connect-compatible identity provider ⇒ our IAM service 14
  • 15. Cloud storage AuthZ: OpenPolicyAgent integration ● A lightweight general-purpose policy engine that can be co-located with Minio server ● OPA HTTP API used to authorize Minio STS credentials ○ Fine grain ACLs ■ Every token claim from authN can be selected for policy checking ○ Dynamic config ○ Decoupled from the storage configuration
  • 16. Example of an e2e AuthZ flow 16 OPA server checks custom policies for the input API Policy example # Allow users to manage their own data. allow { username := split(lower(input.claims.email),"@")[0] input.bucket == username input.claims.aud == "minio-auth" permissions := rl_permissions["user"] p := permissions[_] p == {"action": input.action} } Authorized JWT List of operation permissions defined on OPA "claims": { "accessKey": "VP43M6DO1N53U2LUBTZ3", "aud": "https://wlcg.cern.ch/jwt/v1/any", "client_id": "5c38c020-b753-4115-a5f4-3f48595e4c1b", "exp": "1621714730", "iat": 1621713801, "iss": "https://login.cloud.infn.it", "scope": "openid profile email", "email": “ciangottini@infn.it” } Minio STS auth data
  • 17. Managing policies with OPA bundles the gitOps way ● OPA can periodically download bundles of policy and data from remote HTTP servers ○ Allowing for a gitOps based policy management ● The policies and data are loaded on the fly without requiring a restart of OPA ○ Policies and data are then applied immediately 17
  • 18. So far so good… Let’s put the hands on some user tools now! 18
  • 19. Managing temporary credentials: OIDC-agent ● A set of tools to manage OpenID Connect access tokens and make them easily usable from the command line ○ ssh-agent design, so users can handle OIDC tokens in a similar way as they do with ssh keys ● Secure sensible information (long living credentials) while exposing short lived ones (e.g. access token) ● Integrable via API libraries for: python, go and c++ 19
  • 20. POSIX access: RClone + OIDC-Agent integration To provide posix access we make use of RClone mount capability A small patch has been applied to add a dedicated S3 provider integrated with OIDC-Agent Users, once oidc-agent is configured on its VM, can then mount its own bucket as a folder with no further actions/authentication steps. Backups via Restic are enabled through the use of this patched version of RClone 20
  • 21. Make it easier: STS-wire 21 For cases where the user does not/cannot run oidc-agent: ● a tool has been created to manage both the credential renewal and the rclone mount in a guided/integrated/opinionated way We found that to be the preferred solution to mount a bucket content on a laptop for instance.
  • 22. What about python? boto3+STS+OIDC-Agent = boto3STS Access Minio bucket through the integration of boto library with temporary credentials - AWS STS token via IAM - IAM access token get via oidc-agent API Instantiate an S3 session with a simple line of code 22
  • 23. Nice stuff! So, how did you do that? 23
  • 24. Deployment models ● Generic centrally maintained service for each INFN user ○ HA K8s cluster on infrastructure backbone ○ FluxCD for gitOps operations ○ Central repo for OPA bundles ● On-demand cloud storage ○ Deploy the solution for a dedicated experiment/group of people ○ On prem or public cloud k8s instance as the ONLY requirement ○ Helm chart configurable via WebUI thanks to Kubeapps 24
  • 25. Central service FluxCD cluster management + OPA bundles ___________ Full gitOps control 25
  • 26. Self-managed k8s - Ansible to bring up Kubeapps pointing to the supported INFN Helm charts - Catalogue of pre configured apps already included - Minio-Operator to deploy a Minio Tenant with STS credentials and OPA server - Specifying custom OPA bundles endpoints and other similar configurations 26
  • 27. ● In production supporting physics and not only ○ (e.g. pandemic related research P.L.A.N.E.T.) R&D continues toward: ● testing/scaling multi-cloud ● improving tools dedicated to data access and reuse ● try out Minio gateway cache instances to reduce latency 27 Wrapping up: Summary and plans