SlideShare a Scribd company logo
Patterns and Antipatterns in
Enterprise Security
Johann Nallathamby Malithi Edirisinghe
1
For whom?
● Looking to learn about Identity and Access Management Patterns to
solve real world business problems.
● Some experience with Identity and Access Management
Technologies. E.g. Directories, SAML2, OAuth2 which are some of the
most commonly used data standards / protocols for transporting
Identity and Access Management data.
● Main focus is on Identity and Access Management Patterns.
○ NOT Network Security
○ NOT OS Security
2
1. Identity Integration / Virtual Directory
3
Problem
● Users to the system can come from multiple sources
● A single user’s attributes can come from multiple sources
● User credentials and attributes can come from separate sources
Solution
● Mount multiple user stores for
user management and make the
number and type of user stores
transparent to the application
● Connect the credential stores and
identity stores to the system and
provide a unified view of the
user's’ identity hiding away the
complexity in aggregating those
data
4
2. Identity Broker
5
Problem
Users will work with multiple applications in an enterprise.
They will have to use specific credentials for each.
● Disjointed User Experience
● Complicated user and account management
● Security Threats
Solution
Delegate authentication to a trusted
identity provider - Brokered Identity
6
Benefits
● Single Sign On
● Separate user authentication from application code
● Hides user credentials from applications
● Removes administrative overhead from applications
● Improves user experience
Limitations
● Authentication can be a single point of failure.
● Introduce a single point where the security of the entire system can
be breached
7
3. Identity Federation
8
Problem
Users will use applications across enterprise borders and cloud.
Solution
Multiple trust domains with multiple Identity Providers.
Federated authentication based on the trust relationship
9
Benefits
● Single Sign On
● No need of managing accounts in the on premise userstore
● Reduce administration overhead
Limitations
Security of the system can be compromised if any of the Identity Provider
that your Identity Provider trusts are breached.
10
3.1. Identity Federation Variation -1
Inter-Domain Token Exchange
11
Problem
A consumer who is living in a trust domain needs to interact with a
service that is developed in a federated trust domain
Solution
Establish a trust relationship between the two Identity Providers residing
in each trust domain.
IdP-A IdP-B
Consumer Service
Trust
Trust
Trust
Trust Domain A Trust Domain B
12
Benefits
● Flexible in maintaining trust domains
● Facilitates federated interactions between consumers and services
across trust domains
● Same model can be extended to address more complex federation
scenarios
Limitations
Introduces certain level of dependency between the consumer and the
Identity Provider in the other trust domain
13
3.2. Identity Federation Variation -2
Intra-Domain Token Exchange
14
Problem
A consumer who is living in a trust domain needs to interact with a
service that is developed in a federated trust domain, without any
dependencies to entities in the other trust domain
Solution
Consumer presents the token to the service in the other trust domain.
Service will validate the token with its Identity Provider.
IdP-A IdP-B
Consumer Service
Trust
Trust
Trust
Trust Domain A Trust Domain B
15
Benefits
● Removes dependencies between consumers and service in different
trust domains
● Can handle different token claim representations
Limitations
● Adds complexity to the mechanism used to model the trust
relationship with the Identity Provider in the other trust domain
● Makes the services to accept messages that are not issued by the
Identity Provider that they trusts
16
3.3. Identity Federation Variation -3
Third Party Trust Establisher
17
Problem
Creation of trust between Identity Providers can be complex.
Ex:
Cannot establish direct trust relationship as some identity information
cannot be shared with partner company.
Solution
Establish the trust
relationship with a
third party Identity
Provider, that act as a
bridge between other
Identity Providers
IdP-A IdP-B
Consumer Service
Trust
Trust
Trust
Trust Domain A
Trust Domain BIdP-C
Trust Trust
18
Benefits
Isolates the complexities of the federated environment from different
trust domains
Limitations
Introduces a new component that needs to maintained
19
4. Identity Hub
20
Problem
● Increasing no of Service Providers and Identity Providers
● Each Service Provider has to trust Each Identity Provider
Not scalable
Hard to manage
Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-wso2.
html
Spaghetti
21
Solution
One Identity Broker trusted by relying parties and federated parties
acting as a hub
22
5. Identity Bridge
23
Problem
● Multiple Identity Federation Protocols
SAML, OpenID Connect, WS-Federation etc.
● But federation systems relies on only one protocol
Ex:
Silo of SAML Federation
Silo of OpenID Connect Federation
Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-wso2.
html
Federation
Silos
24
Solution
● Bridge between protocols.
SAML with OpenID Connect
25
Benefits
● Single Sign On across heterogeneous protocols
● Identity federation between Service Providers and Identity Providers
with heterogeneous federation protocols
● Scalability
Limitations
● Authentication can be a single point of failure.
● Introduce a single point where the security of the entire system can
be breached
26
6. Claim/Role Transformer
27
Problem
Service Providers may not be able to understand claims or roles of the
subject, in the format issued by Identity Providers and vise versa.
Solution
Convert incoming claims to the expected format
Benefits
● Process claims in a single point reducing the complexity of enforcing
brokered trust
● Can be used with legacy systems
28
7. Multi-factor Authentication
29
Problem
Digital identity fraud is still on the rise
Needs “strong” user authentication
Solution
Use two or more authentication factors
● Something known to only the user (Knowledge based)
password, shared secret, PIN
● Something held only by the user (Possession based)
security token, smart card, mobile device
● Something inherent only to the user (Biometric)
facial recognition, fingerprint, voice recognition
30
8. Multi-option Authentication
31
Problem
Multiple domains essentially isolated due to lack of mutual inbound or
outbound trust relationships.
Service Providers opt for different login options
Solution
Multiple login options are presented to the user as per the Service
Provider application.
32
9. Adaptive Authentication
33
Problem
Needs “strong” user authentication, if and only if there is an actual risk.
Solution
Provide additional authentication steps, if and only if the risk profile
(derived from a matrix of variables) is high.
Enhance user experience
34
10. Authorization Patterns
35
36
MAC vs. DAC
● Mandatory Access Control (MAC)
○ Centralized security policy
○ Users do not have the ability to override the policy
● Discretionary Access Control (DAC)
○ Governs the ability of subjects to access objects
○ Allows users the ability to make policy decisions and/or assign
security attributes.
○ The traditional Unix system of users, groups, and read-write-
execute permissions is an example of DAC.
37
Access Control Patterns
● Access Matrix / Access Control Table / Access Control List
● Role Based Access Control (RBAC)
● Group Based Access Control
● Claim Based Access Control
● Policy Based
● Hierarchical Authorization
○ Hierarchical Tenants
○ Hierarchical Groups/Roles
○ Hierarchical Resources
● Multilevel Access Control
38
Access Control Patterns
Patterns and Antipatterns in Enterprise Security
Patterns and Antipatterns in Enterprise Security
11. SSO with Delegated Access Control
41
Problem
Consumers need to access back-end APIs on behalf of the logged in user.
42
Solution
Should adhere to some access delegation protocol
Ex: OAuth
Exchange the authentication token to some access token
SAML token, JSON Web Token (JWT)
43
44
12. Outbound Provisioning
45
46
47
48
49
13. JIT Provisioning / Shadow Accounts
50
Requirements
● Transient Name IDs
● Persistent Name IDs
● Identity Protection
● Identity Mapping
● Identity Collision
51
14. Trusted Subsystem
52
53
Problem
Securing a n-tier application
● Securing only the top most layer
● Expansion in the number and kinds of users
● Heterogeneous devices
● Unlimited connections
● Who should be allowed to access the data?
● Cannot protect from an attack originating from the local area
network within the company.
● Who has already accessed the data?
Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-w
html
54
Solution 1
Impersonation and Delegation
● Delegation is the process of allowing another party to act on behalf
of an identity.
● This process bestows upon a party the rights and privileges of
another party to perform a set of tasks.
● Impersonation can be viewed as the most relaxed form of
delegation, such that one identity is assigned the complete set of
permissions of the impersonated identity.
55
Solution 2
Trusted Subsystem
● Trusted subsystem model implies that application services are trusted
to perform a specific set of application tasks.
● Frequently, downstream services need to make application
authorization decisions.
● To do so, the service must know the identity of the end user.
● While the ability to flow the identity of the end user is an inherent
property of the delegation model, it is not so for the trusted subsystem
model and special efforts must be made to include this feature.
Source : https://msdn.microsoft.com/en-us/library/aa905320.
aspx#trstsubsysdes_topic6
56
Solution 2 Contd.
Trusted Subsystem
● Authenticate and verify the identity of the upstream or downstream
service they are communicating with.
● Decide if the identified service is a trusted subsystem for a specific set
of application functions, including propagating identity claims.
● Protect the integrity of the data being communicated between trusted
subsystem and downstream services. Besides application data and
application plumbing data, such as the identity claims of the original
user, must also be protected so that no man-in-the-middle can modify
the identity information that is in transit.
57
Solution 2 Contd.
Trusted Subsystem - Identity Flows
● Trusted subsystem generated identity tokens / Self-issued
○ When downstream services trust the trusted subsystem to assert the
original caller's identity, without requiring additional evidence from
other parties.
● Third party generated identity tokens / Self-contained
○ When the downstream services trust the trusted subsystem to assert
claims regarding the original caller in conjunction with third party
evidence that satisfies an additional set of security requirements.
● User self-signed tokens
○ When the trusted subsystem is authorized to perform a set of
application functions and when there must be evidence from the
original caller that the caller initiated the request.
● Identity/Credential Mapping
○ Special function of the trusted subsystem role, where the goal is to
transform an identity to another related identity for the purpose of
gaining access to downstream resources that only recognize the
transformed identity.
15. Security Gateway
58
59
60
61
Audit Interceptor
Requirement
● Log security incidents to trace system abuse:
○ Failed login attempts
○ Unauthorized access attempts to services
Solution
● All messages flow through the a gateway of the system.
● Necessary auditing is done by the logging at the gateway.
62
Data Origin Authentication
Requirement
● Non-repudiation
Solution
● Digital Signature
Data Confidentiality
Requirement
Protect sensitive personal data during transmission from:
● Tampering
● unauthorized access
Solution
● Digital Encryption
63
Message Screening
Requirement
Mitigate damages to the system from messages with malicious content
● SQL injection
● X-Doc attacks
Solution
● XML Schema validation.
● Regular expression validation to avoid SQL injections contained in
strings.
● An application of Perimeter Security
64
Replay Mitigation/DoS Safety
Requirement
Prevent denial of service attacks caused by replaying valid messages.
Solution
● Apply throttling rules at the entry point.
● Validate message freshness by WS-Security mechanisms
(Timestamp/Nonce).
● An application of Perimeter Security.
65
Exception Shielding
Requirement
Avoid exposing sensitive data through exceptions.
● Legacy application code might throw exceptions containing sensitive
information.
● Need to filter those exceptions when system is exposed to external
parties.
Solution
● Sanitize unsafe exception data by replacing it with non-harmful
exception message and give the right level of detail to the user.
66
References
[1] https://msdn.microsoft.com/en-us/library/
[2] http://soapatterns.org/
[3] https://medium.facilelogin.com/thirty-solution-patterns-with-the-wso2-identity-server-
16f9fd0c0389#.1f3slrjnt
[4] http://wso2.com/library/blog-post/2014/10/blog-post-identity-anti-patterns-federation-silos-
and-spaghetti-identity/
[5] http://wso2.com/library/webinars/identity-server/
[6] M. Schumacher, E. Fernandez-Buglioni and D. Hybertson, Security Patterns: Integrating
Security and Systems Engineering. 2005.
67
Q & A

More Related Content

Viewers also liked (20)

PDF
Security Design Patterns
Aung Khant
 
PPT
Web Security Patterns - Jazoon 2010 - Zurich
javagroup2006
 
PPS
Introducing Msd
Aung Khant
 
PDF
How to Secure Your Enterprise Services with WSO2 ESB
WSO2
 
PPT
Security patterns and model driven architecture
bdemchak
 
PDF
DWS16 - Smart city forum - Niels De Schutter, Atos
IDATE DigiWorld
 
PPTX
Trust No One: The New Security Model for Web APIs - SecTor talk by Greg Kliew...
CA API Management
 
PPTX
Web application security: how to start?
Antonio Fontes
 
PDF
IoT And Inevitable Decentralization of The Internet
Paul Brody
 
PDF
Security Patterns with WSO2 ESB
WSO2
 
PDF
The End of the Fortress: The new Approach to Cybersecurity
Marc Nader
 
PDF
SABSA: Key features, advantages & benefits summary
SABSAcourses
 
PPTX
Understand How Machine Learning Defends Against Zero-Day Threats
Rahul Mohandas
 
PPTX
The Zero Trust Model of Information Security
Tripwire
 
PPTX
Modelling Security Architecture
narenvivek
 
PPTX
Improving web application security, part ii
Kangkan Goswami
 
PDF
Blockchain_ver0.5_MIT_security_and Privacy_am_final_upload
Anish Mohammed
 
PDF
Application Security: Last Line of Defense
Narudom Roongsiriwong, CISSP
 
PPTX
SABSA overview
SABSAcourses
 
PPTX
Adaptive Enterprise Security Architecture
SABSAcourses
 
Security Design Patterns
Aung Khant
 
Web Security Patterns - Jazoon 2010 - Zurich
javagroup2006
 
Introducing Msd
Aung Khant
 
How to Secure Your Enterprise Services with WSO2 ESB
WSO2
 
Security patterns and model driven architecture
bdemchak
 
DWS16 - Smart city forum - Niels De Schutter, Atos
IDATE DigiWorld
 
Trust No One: The New Security Model for Web APIs - SecTor talk by Greg Kliew...
CA API Management
 
Web application security: how to start?
Antonio Fontes
 
IoT And Inevitable Decentralization of The Internet
Paul Brody
 
Security Patterns with WSO2 ESB
WSO2
 
The End of the Fortress: The new Approach to Cybersecurity
Marc Nader
 
SABSA: Key features, advantages & benefits summary
SABSAcourses
 
Understand How Machine Learning Defends Against Zero-Day Threats
Rahul Mohandas
 
The Zero Trust Model of Information Security
Tripwire
 
Modelling Security Architecture
narenvivek
 
Improving web application security, part ii
Kangkan Goswami
 
Blockchain_ver0.5_MIT_security_and Privacy_am_final_upload
Anish Mohammed
 
Application Security: Last Line of Defense
Narudom Roongsiriwong, CISSP
 
SABSA overview
SABSAcourses
 
Adaptive Enterprise Security Architecture
SABSAcourses
 

Similar to Patterns and Antipatterns in Enterprise Security (20)

PDF
Identity Federation Patterns with WSO2 Identity Server​
WSO2
 
PDF
Architecting a cloud scale identity fabric
Mário Almeida
 
PDF
Digital ID Protocol - Presentation 2015-12-04
Synacts
 
PPTX
Securing the Power Platform - What are my options
Juan Carlos Gonzalez
 
PPTX
Security in microservices architectures
inovia
 
PPT
Cloud computing-security-issues
Aleem Mohammed
 
PDF
Cloud Security
Pyingkodi Maran
 
PDF
International Journal of Engineering Inventions (IJEI)
International Journal of Engineering Inventions www.ijeijournal.com
 
PPTX
Troubles with Large Identity Providers.pptx
Yury Leonychev
 
PPTX
Decentralized access control with anonymous authentication of data stored in ...
LeMeniz Infotech
 
PPTX
Security Management in the Cloud
GaryArdito
 
PDF
Advanced mechanism for single sign on for distributed computer networks
eSAT Journals
 
PPT
Cloud security
Adeel Javaid
 
PDF
Federated identity management is mainly used by security leaders. It.pdf
apexjaipur
 
PPTX
NAC_p3.pptx
Saurabh846965
 
PPT
ppt
Videoguy
 
PDF
Keycloak SSO basics
Juan Vicente Herrera Ruiz de Alejo
 
PDF
Benefits of Using Open Source IAM
WSO2
 
PPTX
Real world blockchain solutions - DevDays Asia 2018 - Taipei
Michael Chi
 
PDF
FIWARE Identity Management and Access Control
Fernando Lopez Aguilar
 
Identity Federation Patterns with WSO2 Identity Server​
WSO2
 
Architecting a cloud scale identity fabric
Mário Almeida
 
Digital ID Protocol - Presentation 2015-12-04
Synacts
 
Securing the Power Platform - What are my options
Juan Carlos Gonzalez
 
Security in microservices architectures
inovia
 
Cloud computing-security-issues
Aleem Mohammed
 
Cloud Security
Pyingkodi Maran
 
International Journal of Engineering Inventions (IJEI)
International Journal of Engineering Inventions www.ijeijournal.com
 
Troubles with Large Identity Providers.pptx
Yury Leonychev
 
Decentralized access control with anonymous authentication of data stored in ...
LeMeniz Infotech
 
Security Management in the Cloud
GaryArdito
 
Advanced mechanism for single sign on for distributed computer networks
eSAT Journals
 
Cloud security
Adeel Javaid
 
Federated identity management is mainly used by security leaders. It.pdf
apexjaipur
 
NAC_p3.pptx
Saurabh846965
 
Benefits of Using Open Source IAM
WSO2
 
Real world blockchain solutions - DevDays Asia 2018 - Taipei
Michael Chi
 
FIWARE Identity Management and Access Control
Fernando Lopez Aguilar
 
Ad

More from WSO2 (20)

PDF
Quantum Threats Are Closer Than You Think – Act Now to Stay Secure
WSO2
 
PDF
Modern Platform Engineering with Choreo - The AI-Native Internal Developer Pl...
WSO2
 
PDF
Application Modernization with Choreo - The AI-Native Internal Developer Plat...
WSO2
 
PDF
Build Smarter, Deliver Faster with Choreo - An AI Native Internal Developer P...
WSO2
 
PDF
Platformless Modernization with Choreo.pdf
WSO2
 
PDF
Application Modernization with Choreo for the BFSI Sector
WSO2
 
PDF
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
WSO2
 
PDF
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
WSO2
 
PPTX
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2
 
PPTX
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2
 
PPTX
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2
 
PPTX
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
PPTX
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
PPTX
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2
 
PPTX
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2
 
PPTX
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2
 
PDF
Mastering Intelligent Digital Experiences with Platformless Modernization
WSO2
 
PDF
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
PDF
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2
 
PDF
architecting-ai-in-the-enterprise-apis-and-applications.pdf
WSO2
 
Quantum Threats Are Closer Than You Think – Act Now to Stay Secure
WSO2
 
Modern Platform Engineering with Choreo - The AI-Native Internal Developer Pl...
WSO2
 
Application Modernization with Choreo - The AI-Native Internal Developer Plat...
WSO2
 
Build Smarter, Deliver Faster with Choreo - An AI Native Internal Developer P...
WSO2
 
Platformless Modernization with Choreo.pdf
WSO2
 
Application Modernization with Choreo for the BFSI Sector
WSO2
 
Choreo - The AI-Native Internal Developer Platform as a Service: Overview
WSO2
 
[Roundtable] Choreo - The AI-Native Internal Developer Platform as a Service
WSO2
 
WSO2Con 2025 - Building AI Applications in the Enterprise (Part 1)
WSO2
 
WSO2Con 2025 - Building Secure Business Customer and Partner Experience (B2B)...
WSO2
 
WSO2Con 2025 - Building Secure Customer Experience Apps
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - AI-Driven API Design, Development, and Consumption with Enhanc...
WSO2
 
WSO2Con 2025 - Unified Management of Ingress and Egress Across Multiple API G...
WSO2
 
WSO2Con 2025 - How an Internal Developer Platform Lets Developers Focus on Code
WSO2
 
WSO2Con 2025 - Architecting Cloud-Native Applications
WSO2
 
Mastering Intelligent Digital Experiences with Platformless Modernization
WSO2
 
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
WSO2
 
Ad

Recently uploaded (20)

PPTX
✨Unleashing Collaboration: Salesforce Channels & Community Power in Patna!✨
SanjeetMishra29
 
PDF
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
PDF
SWEBOK Guide and Software Services Engineering Education
Hironori Washizaki
 
PDF
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
PPTX
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
PPTX
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
PPTX
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
PDF
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
PDF
Windsurf Meetup Ottawa 2025-07-12 - Planning Mode at Reliza.pdf
Pavel Shukhman
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
PDF
Transcript: New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
PDF
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
PDF
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
PDF
July Patch Tuesday
Ivanti
 
PDF
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
PDF
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PDF
Blockchain Transactions Explained For Everyone
CIFDAQ
 
PPT
Interview paper part 3, It is based on Interview Prep
SoumyadeepGhosh39
 
✨Unleashing Collaboration: Salesforce Channels & Community Power in Patna!✨
SanjeetMishra29
 
LLMs.txt: Easily Control How AI Crawls Your Site
Keploy
 
SWEBOK Guide and Software Services Engineering Education
Hironori Washizaki
 
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
Top iOS App Development Company in the USA for Innovative Apps
SynapseIndia
 
UiPath Academic Alliance Educator Panels: Session 2 - Business Analyst Content
DianaGray10
 
Q2 FY26 Tableau User Group Leader Quarterly Call
lward7
 
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
Windsurf Meetup Ottawa 2025-07-12 - Planning Mode at Reliza.pdf
Pavel Shukhman
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
Transcript: New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
July Patch Tuesday
Ivanti
 
The Builder’s Playbook - 2025 State of AI Report.pdf
jeroen339954
 
Smart Trailers 2025 Update with History and Overview
Paul Menig
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
Blockchain Transactions Explained For Everyone
CIFDAQ
 
Interview paper part 3, It is based on Interview Prep
SoumyadeepGhosh39
 

Patterns and Antipatterns in Enterprise Security

  • 1. Patterns and Antipatterns in Enterprise Security Johann Nallathamby Malithi Edirisinghe 1
  • 2. For whom? ● Looking to learn about Identity and Access Management Patterns to solve real world business problems. ● Some experience with Identity and Access Management Technologies. E.g. Directories, SAML2, OAuth2 which are some of the most commonly used data standards / protocols for transporting Identity and Access Management data. ● Main focus is on Identity and Access Management Patterns. ○ NOT Network Security ○ NOT OS Security 2
  • 3. 1. Identity Integration / Virtual Directory 3
  • 4. Problem ● Users to the system can come from multiple sources ● A single user’s attributes can come from multiple sources ● User credentials and attributes can come from separate sources Solution ● Mount multiple user stores for user management and make the number and type of user stores transparent to the application ● Connect the credential stores and identity stores to the system and provide a unified view of the user's’ identity hiding away the complexity in aggregating those data 4
  • 6. Problem Users will work with multiple applications in an enterprise. They will have to use specific credentials for each. ● Disjointed User Experience ● Complicated user and account management ● Security Threats Solution Delegate authentication to a trusted identity provider - Brokered Identity 6
  • 7. Benefits ● Single Sign On ● Separate user authentication from application code ● Hides user credentials from applications ● Removes administrative overhead from applications ● Improves user experience Limitations ● Authentication can be a single point of failure. ● Introduce a single point where the security of the entire system can be breached 7
  • 9. Problem Users will use applications across enterprise borders and cloud. Solution Multiple trust domains with multiple Identity Providers. Federated authentication based on the trust relationship 9
  • 10. Benefits ● Single Sign On ● No need of managing accounts in the on premise userstore ● Reduce administration overhead Limitations Security of the system can be compromised if any of the Identity Provider that your Identity Provider trusts are breached. 10
  • 11. 3.1. Identity Federation Variation -1 Inter-Domain Token Exchange 11
  • 12. Problem A consumer who is living in a trust domain needs to interact with a service that is developed in a federated trust domain Solution Establish a trust relationship between the two Identity Providers residing in each trust domain. IdP-A IdP-B Consumer Service Trust Trust Trust Trust Domain A Trust Domain B 12
  • 13. Benefits ● Flexible in maintaining trust domains ● Facilitates federated interactions between consumers and services across trust domains ● Same model can be extended to address more complex federation scenarios Limitations Introduces certain level of dependency between the consumer and the Identity Provider in the other trust domain 13
  • 14. 3.2. Identity Federation Variation -2 Intra-Domain Token Exchange 14
  • 15. Problem A consumer who is living in a trust domain needs to interact with a service that is developed in a federated trust domain, without any dependencies to entities in the other trust domain Solution Consumer presents the token to the service in the other trust domain. Service will validate the token with its Identity Provider. IdP-A IdP-B Consumer Service Trust Trust Trust Trust Domain A Trust Domain B 15
  • 16. Benefits ● Removes dependencies between consumers and service in different trust domains ● Can handle different token claim representations Limitations ● Adds complexity to the mechanism used to model the trust relationship with the Identity Provider in the other trust domain ● Makes the services to accept messages that are not issued by the Identity Provider that they trusts 16
  • 17. 3.3. Identity Federation Variation -3 Third Party Trust Establisher 17
  • 18. Problem Creation of trust between Identity Providers can be complex. Ex: Cannot establish direct trust relationship as some identity information cannot be shared with partner company. Solution Establish the trust relationship with a third party Identity Provider, that act as a bridge between other Identity Providers IdP-A IdP-B Consumer Service Trust Trust Trust Trust Domain A Trust Domain BIdP-C Trust Trust 18
  • 19. Benefits Isolates the complexities of the federated environment from different trust domains Limitations Introduces a new component that needs to maintained 19
  • 21. Problem ● Increasing no of Service Providers and Identity Providers ● Each Service Provider has to trust Each Identity Provider Not scalable Hard to manage Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-wso2. html Spaghetti 21
  • 22. Solution One Identity Broker trusted by relying parties and federated parties acting as a hub 22
  • 24. Problem ● Multiple Identity Federation Protocols SAML, OpenID Connect, WS-Federation etc. ● But federation systems relies on only one protocol Ex: Silo of SAML Federation Silo of OpenID Connect Federation Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-wso2. html Federation Silos 24
  • 25. Solution ● Bridge between protocols. SAML with OpenID Connect 25
  • 26. Benefits ● Single Sign On across heterogeneous protocols ● Identity federation between Service Providers and Identity Providers with heterogeneous federation protocols ● Scalability Limitations ● Authentication can be a single point of failure. ● Introduce a single point where the security of the entire system can be breached 26
  • 28. Problem Service Providers may not be able to understand claims or roles of the subject, in the format issued by Identity Providers and vise versa. Solution Convert incoming claims to the expected format Benefits ● Process claims in a single point reducing the complexity of enforcing brokered trust ● Can be used with legacy systems 28
  • 30. Problem Digital identity fraud is still on the rise Needs “strong” user authentication Solution Use two or more authentication factors ● Something known to only the user (Knowledge based) password, shared secret, PIN ● Something held only by the user (Possession based) security token, smart card, mobile device ● Something inherent only to the user (Biometric) facial recognition, fingerprint, voice recognition 30
  • 32. Problem Multiple domains essentially isolated due to lack of mutual inbound or outbound trust relationships. Service Providers opt for different login options Solution Multiple login options are presented to the user as per the Service Provider application. 32
  • 34. Problem Needs “strong” user authentication, if and only if there is an actual risk. Solution Provide additional authentication steps, if and only if the risk profile (derived from a matrix of variables) is high. Enhance user experience 34
  • 36. 36 MAC vs. DAC ● Mandatory Access Control (MAC) ○ Centralized security policy ○ Users do not have the ability to override the policy ● Discretionary Access Control (DAC) ○ Governs the ability of subjects to access objects ○ Allows users the ability to make policy decisions and/or assign security attributes. ○ The traditional Unix system of users, groups, and read-write- execute permissions is an example of DAC.
  • 37. 37 Access Control Patterns ● Access Matrix / Access Control Table / Access Control List ● Role Based Access Control (RBAC) ● Group Based Access Control ● Claim Based Access Control ● Policy Based ● Hierarchical Authorization ○ Hierarchical Tenants ○ Hierarchical Groups/Roles ○ Hierarchical Resources ● Multilevel Access Control
  • 41. 11. SSO with Delegated Access Control 41
  • 42. Problem Consumers need to access back-end APIs on behalf of the logged in user. 42 Solution Should adhere to some access delegation protocol Ex: OAuth Exchange the authentication token to some access token SAML token, JSON Web Token (JWT)
  • 43. 43
  • 44. 44
  • 46. 46
  • 47. 47
  • 48. 48
  • 49. 49
  • 50. 13. JIT Provisioning / Shadow Accounts 50
  • 51. Requirements ● Transient Name IDs ● Persistent Name IDs ● Identity Protection ● Identity Mapping ● Identity Collision 51
  • 53. 53 Problem Securing a n-tier application ● Securing only the top most layer ● Expansion in the number and kinds of users ● Heterogeneous devices ● Unlimited connections ● Who should be allowed to access the data? ● Cannot protect from an attack originating from the local area network within the company. ● Who has already accessed the data? Source : http://blog.facilelogin.com/2014/10/identity-federation-patterns-with-w html
  • 54. 54 Solution 1 Impersonation and Delegation ● Delegation is the process of allowing another party to act on behalf of an identity. ● This process bestows upon a party the rights and privileges of another party to perform a set of tasks. ● Impersonation can be viewed as the most relaxed form of delegation, such that one identity is assigned the complete set of permissions of the impersonated identity.
  • 55. 55 Solution 2 Trusted Subsystem ● Trusted subsystem model implies that application services are trusted to perform a specific set of application tasks. ● Frequently, downstream services need to make application authorization decisions. ● To do so, the service must know the identity of the end user. ● While the ability to flow the identity of the end user is an inherent property of the delegation model, it is not so for the trusted subsystem model and special efforts must be made to include this feature. Source : https://msdn.microsoft.com/en-us/library/aa905320. aspx#trstsubsysdes_topic6
  • 56. 56 Solution 2 Contd. Trusted Subsystem ● Authenticate and verify the identity of the upstream or downstream service they are communicating with. ● Decide if the identified service is a trusted subsystem for a specific set of application functions, including propagating identity claims. ● Protect the integrity of the data being communicated between trusted subsystem and downstream services. Besides application data and application plumbing data, such as the identity claims of the original user, must also be protected so that no man-in-the-middle can modify the identity information that is in transit.
  • 57. 57 Solution 2 Contd. Trusted Subsystem - Identity Flows ● Trusted subsystem generated identity tokens / Self-issued ○ When downstream services trust the trusted subsystem to assert the original caller's identity, without requiring additional evidence from other parties. ● Third party generated identity tokens / Self-contained ○ When the downstream services trust the trusted subsystem to assert claims regarding the original caller in conjunction with third party evidence that satisfies an additional set of security requirements. ● User self-signed tokens ○ When the trusted subsystem is authorized to perform a set of application functions and when there must be evidence from the original caller that the caller initiated the request. ● Identity/Credential Mapping ○ Special function of the trusted subsystem role, where the goal is to transform an identity to another related identity for the purpose of gaining access to downstream resources that only recognize the transformed identity.
  • 59. 59
  • 60. 60
  • 61. 61 Audit Interceptor Requirement ● Log security incidents to trace system abuse: ○ Failed login attempts ○ Unauthorized access attempts to services Solution ● All messages flow through the a gateway of the system. ● Necessary auditing is done by the logging at the gateway.
  • 62. 62 Data Origin Authentication Requirement ● Non-repudiation Solution ● Digital Signature Data Confidentiality Requirement Protect sensitive personal data during transmission from: ● Tampering ● unauthorized access Solution ● Digital Encryption
  • 63. 63 Message Screening Requirement Mitigate damages to the system from messages with malicious content ● SQL injection ● X-Doc attacks Solution ● XML Schema validation. ● Regular expression validation to avoid SQL injections contained in strings. ● An application of Perimeter Security
  • 64. 64 Replay Mitigation/DoS Safety Requirement Prevent denial of service attacks caused by replaying valid messages. Solution ● Apply throttling rules at the entry point. ● Validate message freshness by WS-Security mechanisms (Timestamp/Nonce). ● An application of Perimeter Security.
  • 65. 65 Exception Shielding Requirement Avoid exposing sensitive data through exceptions. ● Legacy application code might throw exceptions containing sensitive information. ● Need to filter those exceptions when system is exposed to external parties. Solution ● Sanitize unsafe exception data by replacing it with non-harmful exception message and give the right level of detail to the user.
  • 66. 66 References [1] https://msdn.microsoft.com/en-us/library/ [2] http://soapatterns.org/ [3] https://medium.facilelogin.com/thirty-solution-patterns-with-the-wso2-identity-server- 16f9fd0c0389#.1f3slrjnt [4] http://wso2.com/library/blog-post/2014/10/blog-post-identity-anti-patterns-federation-silos- and-spaghetti-identity/ [5] http://wso2.com/library/webinars/identity-server/ [6] M. Schumacher, E. Fernandez-Buglioni and D. Hybertson, Security Patterns: Integrating Security and Systems Engineering. 2005.