SlideShare a Scribd company logo
@joachimvda@eliwan_be
Joachim Van der Auwera
ASVS
in a business application
@joachimvda@eliwan_be
ASVS v2
• Application Security Verification Standard
• The primary aim of the OWASP Application Security Verification Standard
(ASVS) is to normalize the range in the coverage and level of rigor available in
the market when it comes to performing web application security verification.
• OWASP
• Why ?
@joachimvda@eliwan_be
Four levels
@joachimvda@eliwan_be
Level for each verification
@joachimvda@eliwan_be
Verify
[ver-uh-fahy]
1. to prove the truth of, as by evidence or testimony; confirm;
substantiate: Events verified his prediction.
2. to ascertain the truth or correctness of, as by examination,
research, or comparison: to verify a spelling.
3. to act as ultimate proof or evidence of; serve to confirm.
4. Law.
to prove or confirm (an allegation).
to state to be true, especially in legal use, formally or upon oath.
@joachimvda@eliwan_be
Authentication
• Verify all pages/resources require authentication except specific
• Verify that all authentication decisions are logged
• Verify all account password are salted – account specific – and use bcrypt, scrypt
or PBKDF2 before storing
• Credentials and identity information should not traverse un/weakly encrypted
links
• No clear text password sent to user
• Username enumeration not possible in login/reset/forgot account
• No default passwords (e.g. “admin/password”)
1 2 3
1
2
2
1
1
1
1
@joachimvda@eliwan_be
Authentication continued
• Verify password entry fields allow or encourage the use of passphrases, and do
not prevent long passphrases or highly complex passwords being entered, and
provide a sufficient minimum strength to protect against the use of commonly
chosen passwords.
• Forget password should not lock account
• No shared knowledge questions/answers (secret questions)
• Allow configuration to disallow x previous passwords
• Require two-factor authentication as per risk profile
1 2 3
2
2
2
2
3
@joachimvda@eliwan_be
Session Management
• Verify that sessions timeout after a certain period of inactivity
• Session timeout after (config) maximum time regardless of activity
• Session id never disclosed other than in cookie headers. No URL rewriting of
session cookies.
• Verify session id is changed upon re-authentication
• Session tokens should be sufficiently long and random to prevent guessing
attacks
• Cookie path should be restrictive, domain not set (unless for business
requirement like SSO)
• HttpOnly should be set on cookie, Secure set when using https
• No duplicate concurrent users originating from different machines
1 2 3
1
2
1
2
2
2
1
2
@joachimvda@eliwan_be
Acces Control
• Users can only access functions or services for which they possess specific
authorization
• Verify directory browsing disabled unless deliberately desired
• All access controls are enforced on the server side
• User, data, policy information used by access controls cannot be manipulated
unless specifically authorized
• Log all access control decisions (success and failure)
• Require use of strong CSRF tokens
• Aggregate access control protection – e.g. throttle requests to prevent the entire
database from being scraped by an individual user.
1 2 3
1
1
1
2
2
1
2
@joachimvda@eliwan_be
RESTEasy interceptor
@Component
@Provider
@ServerInterceptor
public class SecurityPreProcessInterceptor
        implements ContainerRequestFilter {
    @Override
    public void filter(
            ContainerRequestContext requestContext) 
            throws IOException {
        // ....
    }
}
@joachimvda@eliwan_be
Require access annotation
if (requestContext instanceof PostMatchContainerRequestContext) {
    PostMatchContainerRequestContext pmcrc = (PostMatch...) requestContext;
    Annotation[] annotations = pmcrc.getResourceMethod().getMethodAnnotations();
  if (!contains(annotations, PermitAll.class)) {
    if (contains(annotations, RolesAllowed.class)) {
      RolesAllowed ra = get(annotations, RolesAllowed.class);
      checkUserHasRole(requestContext, ra.value());
    } else {
      throw new AuthException("Missing security “ +
        ”constraints on endpoint. " + pmcrc.getResourceMethod().getMethod());
    }
  }
}
@joachimvda@eliwan_be
Malicious Input Handling
• Verify all input validation or encoding done server side
• Log all input validation failures
• No SQL, LDAP, OS command injection
• All untrusted data output as HTML should be escaped
• Verify defenses against HTTP parameter pollution attacks
1 2 3
1
3
1
1
2
@joachimvda@eliwan_be
Cryptography at Rest
• All cryptographic functions to protect secrets done server side
• Cryptographic modules validated agains FIPS 140-2 or an equivalent standard
• Verify there is a policy for managing cryptographic keys. Verify that policy is
properly enforced.
1 2 3
2
3
2
@joachimvda@eliwan_be
Error Handling and Logging
• No sensitive data in error messages or stack traces (including session id or
sensitive information)
• Verify that all authentication decisions are logged
• Each log event should include timestamp, severity, indication if security relevant
(in mixed logs), identity, request IP address, success/failure, description
• Do not log sensitive data that can help an attacker. Presence and length may be
logged.
• Log before executing a transaction, if logging fails the application fails safely.
Important for integrity and non-repudiation.
1 2 3
1
2
2
3
2
@joachimvda@eliwan_be
Data Protection
• Disabled client-side caching and autocomplete for sensitive fields
• Sensitive data in HTTP body (not request parameters)
• Ensure proper caching of sensitive data
• Minimize number of parameters sent to untrusted systems e.g. hidden fields,
cookies, ajax variables, header values
• Alert and detect abnormal number of requests eg for screen scraping
1 2 3
1
1
2
3
3
@joachimvda@eliwan_be
Communications Security
• Valid SSL certificates, path from root CA and validity
• Failed TLS communications should not fallback to HTTP
1 2 3
1
3
@joachimvda@eliwan_be
HTTP Security
• Every HTTP response should include a safe character set (e.g. UTF-8)
• No detailed version information in HTTP headers
1 2 3
1
2
@joachimvda@eliwan_be
Malicious Controls
All checks are level 3
• Verify no malicious code in code developed or modified
• Integrity of interpreted code, libraries, executables, configuration files verified
using checksums or hashes
• Sensitive data rapidly sanitized from memory when no longer needed
1 2 3
3
3
3
@joachimvda@eliwan_be
Business Logic
• No spoofing of high value transactions
• No tampering with high value business logic parameters like price
• Verify defensive measures against repudiation attacks such as verifiable and
protected transaction logs, or real-time monitoring of activities and trransactions
for anomalies
• Detection and governor controls to protect against brute force or denial of
service attacks
• Business limits and enforces them in trusted location, e.g. max $10/day for new
SIM users, or limit patient access to max # patients you can treat in a day, or max
100 new users a day in a forum, or not allowing posts before a users account has
been verified
1 2 3
2
2
2
2
2
@joachimvda@eliwan_be
Files and Resources
• Verify the application does not execute uploaded data from untrusted sources
1 2 3
2
@joachimvda@eliwan_be
Mobile
• Verify that unique device ID (UDID) is not used as security controle
• Don't store sensitive data on shared resources (eg shared folder)
• No sensitive data in SQLite database on device
• No hard-coded secret keys or passwords in executable
• Verify permissions requested and resources authorized (AndriodManifest.xml,
iOS entitlements)
• Obfuscate binary
• No sensitive data logged (crash log, system log or filesystem)
• Use certificate pinning to prevent proxying of app data
• Sensitive data should be cryptographically secured when stored
• Overwrite sensitive data in memory (mitigate damage from memory analysis
attack)
1 2 3
1
1
1
2
2
3
2
3
3
3
@joachimvda@eliwan_be
Think about security in your application
https://www.owasp.org/

More Related Content

PPTX
Data security authorization and access control
PDF
PDF
Key Concepts for Protecting the Privacy of IBM i Data
PPTX
Owasp top ten 2017
PPTX
The Myth of SSH Key Rotation Mythcracker Webcast Series Part 3
PPTX
National Digital ID Platform Technical Forum
PPTX
Entrepreneurship & Commerce in IT - 11 - Security & Encryption
PPTX
Provable Device Cybersecurity in Blockchain Transactions
Data security authorization and access control
Key Concepts for Protecting the Privacy of IBM i Data
Owasp top ten 2017
The Myth of SSH Key Rotation Mythcracker Webcast Series Part 3
National Digital ID Platform Technical Forum
Entrepreneurship & Commerce in IT - 11 - Security & Encryption
Provable Device Cybersecurity in Blockchain Transactions

What's hot (20)

PPTX
See Web Security Trend from OWASP Top 10 - 2017
PPTX
"EL ATAQUE INTERNO"
PDF
Protecting the Keys to the Kingdom - The Case for Adaptive Authentication for...
PDF
CyberArk Cleveland Defend Multi-Factor
PPTX
Authentication
PDF
Building a secure BFF at Postman
PDF
Securing Your Mobile Applications
PDF
CyberArk Cleveland Defend End Point Infection and Lateral Movement
PPTX
5 Möglichkeiten zur Verbesserung Ihrer Security
PDF
Coding Security: Code Mania 101
PPTX
Two factor authentication 2018
PPTX
Physical security-system
PPTX
HIPAA 101 Compliance Threat Landscape & Best Practices
PDF
"Inter- application vulnerabilities. hunting for bugs in secure applications"...
PPTX
Cryptography and system security
PPTX
Cm4 secure code_training_1day_error handling and logging
PPTX
Cyber Security For E-commerce (Infrastructure) development
PPTX
Automation Attacks At Scale
PDF
Cybersecurity Update
PPTX
Two Factor Authentication
See Web Security Trend from OWASP Top 10 - 2017
"EL ATAQUE INTERNO"
Protecting the Keys to the Kingdom - The Case for Adaptive Authentication for...
CyberArk Cleveland Defend Multi-Factor
Authentication
Building a secure BFF at Postman
Securing Your Mobile Applications
CyberArk Cleveland Defend End Point Infection and Lateral Movement
5 Möglichkeiten zur Verbesserung Ihrer Security
Coding Security: Code Mania 101
Two factor authentication 2018
Physical security-system
HIPAA 101 Compliance Threat Landscape & Best Practices
"Inter- application vulnerabilities. hunting for bugs in secure applications"...
Cryptography and system security
Cm4 secure code_training_1day_error handling and logging
Cyber Security For E-commerce (Infrastructure) development
Automation Attacks At Scale
Cybersecurity Update
Two Factor Authentication
Ad

Similar to Java zone ASVS 2015 (20)

PDF
Web security uploadv1
PPTX
A zero Trust Protect Surface Mapping for a Website
PPTX
How to Test for The OWASP Top Ten
PDF
Attachment 1 – mitigation measures for two factor authentication compromise
PDF
CNIT 129S: Securing Web Applications Ch 1-2
PPTX
SQLCAT: Addressing Security and Compliance Issues with SQL Server 2008
PDF
Ch 1: Web Application (In)security & Ch 2: Core Defense Mechanisms
PDF
Track 5 session 2 - st dev con 2016 - security iot best practices
PPTX
Lock it Down: Access Control for IBM i
PPTX
CyberArk
PDF
CNIT 129S: Ch 6: Attacking Authentication
PPTX
Cyber Security # Lec 5
PPTX
Owasp first5 presentation
PPTX
Owasp first5 presentation
PPTX
Secure coding guidelines
PPTX
Owasp security testing methodlogies –part2
PPTX
Security architecture best practices for saas applications
PPTX
Webinar: Beyond Two-Factor: Secure Access Control for Office 365
PPT
HIT 200-400 presentation handout!.ppt
PPTX
Security-Top-10-Penetration-Findings.pptx
Web security uploadv1
A zero Trust Protect Surface Mapping for a Website
How to Test for The OWASP Top Ten
Attachment 1 – mitigation measures for two factor authentication compromise
CNIT 129S: Securing Web Applications Ch 1-2
SQLCAT: Addressing Security and Compliance Issues with SQL Server 2008
Ch 1: Web Application (In)security & Ch 2: Core Defense Mechanisms
Track 5 session 2 - st dev con 2016 - security iot best practices
Lock it Down: Access Control for IBM i
CyberArk
CNIT 129S: Ch 6: Attacking Authentication
Cyber Security # Lec 5
Owasp first5 presentation
Owasp first5 presentation
Secure coding guidelines
Owasp security testing methodlogies –part2
Security architecture best practices for saas applications
Webinar: Beyond Two-Factor: Secure Access Control for Office 365
HIT 200-400 presentation handout!.ppt
Security-Top-10-Penetration-Findings.pptx
Ad

More from Joachim Van der Auwera (9)

ODP
jTransfo quickie at JavaZone 2015
ODP
Simple run-time profiling quickie devoxx14
ODP
jTransfo lightning talk
ODP
Overview of Geomajas plug-ins and faces
ODP
Geomajas introduction, BeJUG, March 2012
ODP
Mapping, GIS and geolocating data in Java @ JAX London
ODP
Securing GIS data
ODP
Mapping, GIS and geolocating data in Java
PPT
Foss4g evolution-gis-data
jTransfo quickie at JavaZone 2015
Simple run-time profiling quickie devoxx14
jTransfo lightning talk
Overview of Geomajas plug-ins and faces
Geomajas introduction, BeJUG, March 2012
Mapping, GIS and geolocating data in Java @ JAX London
Securing GIS data
Mapping, GIS and geolocating data in Java
Foss4g evolution-gis-data

Recently uploaded (20)

PPTX
Internet___Basics___Styled_ presentation
PDF
Introduction to the IoT system, how the IoT system works
PPT
tcp ip networks nd ip layering assotred slides
PDF
Vigrab.top – Online Tool for Downloading and Converting Social Media Videos a...
PDF
SASE Traffic Flow - ZTNA Connector-1.pdf
PPTX
SAP Ariba Sourcing PPT for learning material
PPT
isotopes_sddsadsaadasdasdasdasdsa1213.ppt
PPTX
Job_Card_System_Styled_lorem_ipsum_.pptx
PPTX
E -tech empowerment technologies PowerPoint
PDF
Decoding a Decade: 10 Years of Applied CTI Discipline
PPTX
artificialintelligenceai1-copy-210604123353.pptx
PDF
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
PPTX
innovation process that make everything different.pptx
PPTX
Introduction to Information and Communication Technology
PPT
FIRE PREVENTION AND CONTROL PLAN- LUS.FM.MQ.OM.UTM.PLN.00014.ppt
PDF
Smart Home Technology for Health Monitoring (www.kiu.ac.ug)
PDF
FINAL CALL-6th International Conference on Networks & IOT (NeTIOT 2025)
PPTX
Introduction about ICD -10 and ICD11 on 5.8.25.pptx
PPTX
Module 1 - Cyber Law and Ethics 101.pptx
PDF
Unit-1 introduction to cyber security discuss about how to secure a system
Internet___Basics___Styled_ presentation
Introduction to the IoT system, how the IoT system works
tcp ip networks nd ip layering assotred slides
Vigrab.top – Online Tool for Downloading and Converting Social Media Videos a...
SASE Traffic Flow - ZTNA Connector-1.pdf
SAP Ariba Sourcing PPT for learning material
isotopes_sddsadsaadasdasdasdasdsa1213.ppt
Job_Card_System_Styled_lorem_ipsum_.pptx
E -tech empowerment technologies PowerPoint
Decoding a Decade: 10 Years of Applied CTI Discipline
artificialintelligenceai1-copy-210604123353.pptx
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
innovation process that make everything different.pptx
Introduction to Information and Communication Technology
FIRE PREVENTION AND CONTROL PLAN- LUS.FM.MQ.OM.UTM.PLN.00014.ppt
Smart Home Technology for Health Monitoring (www.kiu.ac.ug)
FINAL CALL-6th International Conference on Networks & IOT (NeTIOT 2025)
Introduction about ICD -10 and ICD11 on 5.8.25.pptx
Module 1 - Cyber Law and Ethics 101.pptx
Unit-1 introduction to cyber security discuss about how to secure a system

Java zone ASVS 2015

Editor's Notes

  • #2: Who am I Disclaimer
  • #3: Who knows OWASP? OWASP -> Open Web Application Security Project Improve security of software Make software security visible -> informed decisions about true software security risks ASVS -> practical reference to think about security Questions -> raise hand – personal opinion - discuss
  • #4: Cursory : optional, “some” kind of verification, custom requirements Opportunitic Requirements can be verified using minimal-to-low effort Protection against simple attacks or easy-to-exploit vulnerabilities Standard Includes OWASP Top 10 and business logic “sensitive applications”, b2b applicatons Advanced Include more difficult to exploit vulnerabilities Protect against determined attackers - also check design, reqs + - security stuff (cross cutting) -> centralized implementation - all validation should use whitelist approach - input validation only second line of defense, parameterization and output encoding is first Critical app, life and safety, substantial damage, sensitive assets Scope + The code for the application or release needs to comply with req Frameworks/libraries/services verification is optional (+) certification when checking those Not all reqs applicable as no code available -
  • #5: 13 security areas Various requirements for each area, each indicates with the levels at which the requirement needs to be met 190 requirements, of which 54 at level 1
  • #6: All requirements use “Verify...” wording. Automated testing is not enough. Trusting your developers is not enough. Trusting the libraries / frameworks / tooling is not enough