Categories: Application Security

Top 7 Security Attack Questions While Analyzing Every Requirement

Following are top 5 security attack related questions that you could ask while analyzing the each requirement in hand, the answers to which could help you put better design in relation with security:

  • Security threats analysis related with data entering into/coming out of the system:
    1. How could an attacker inject SQL commands? (OWASP SQL Injection). Solution: Use parameterized SQL queries rather than building SQL statements dynamically using string concatenation
    2. How could an attacker perform a cross-site scripting attack? (OWASP Cross-Site Scripting – XSS). Solution: Use OWASP ESAPI to sanitize user input against scripts such as Javascript that could lead to XSS attacks.  This is more about doing input data validation as soon as data lands on to server.
    3. Are there any sensitive data being dealt as part of the requirement? If yes, where and how does your application store sensitive data? And, when and where is sensitive data passed across the network? (OWASP Sensitive Data Exposure). Solution: Design to encrypt sensitive data while storing in the database. Also, plan to use SSL protocol for moving data over the network. This secures data at rest and in transit.
    4. How could an attacker gain useful exception details which reveals information related with server, file paths, components and other configuration related information? (OWASP Security Misconfiguration) Solution: Design to have default error pages which can be displayed instead of raw exception messages (stacktraces). Alternatively, design to respond with exception message rather than the full exception stacktrace.
  • Security threats related with Repudiation
    1. Are the transactions important enough, such that repudiation attempts of which can lead to financial loss or any other kind of critical impact to business? Solution: Plan to store the data related to transactions such that it can be used for audit purpose.
  • Security threats from vulnerabilities found in components/libraries
    1. As part of requirements implementation, one or more third-party libraries can be used. Thus, it is important to make sure that those third-party libraries do not have any known vulnerabilities. This is because the hackers can exploit those known vulnerabilities to attack the system. (OWASP Using component with known vulnerabilities)
  • Security threats in relation with function level access control
    1. Are there any functions getting implemented as part of requirements, which needs an access control mechanism to only allow access to users with particular role? (OWASP Functiona level access control) Solution: Design to perform access control checks for functions having limited access.

 

Ajitesh Kumar

I have been recently working in the area of Data analytics including Data Science and Machine Learning / Deep Learning. I am also passionate about different technologies including programming languages such as Java/JEE, Javascript, Python, R, Julia, etc, and technologies such as Blockchain, mobile computing, cloud-native technologies, application security, cloud computing platforms, big data, etc. I would love to connect with you on Linkedin. Check out my latest book titled as First Principles Thinking: Building winning products using first principles thinking.

Share
Published by
Ajitesh Kumar

Recent Posts

Coefficient of Variation in Regression Modelling: Example

When building a regression model or performing regression analysis to predict a target variable, understanding…

1 day ago

Chunking Strategies for RAG with Examples

If you've built a "Naive" RAG pipeline, you've probably hit a wall. You've indexed your…

1 week ago

RAG Pipeline: 6 Steps for Creating Naive RAG App

If you're starting with large language models, you must have heard of RAG (Retrieval-Augmented Generation).…

1 week ago

Python: List Comprehension Explained with Examples

If you've spent any time with Python, you've likely heard the term "Pythonic." It refers…

2 weeks ago

Large Language Models (LLMs): Four Critical Modeling Stages

Large language models (LLMs) have fundamentally transformed our digital landscape, powering everything from chatbots and…

3 months ago

Agentic Workflow Design Patterns Explained with Examples

As Large Language Models (LLMs) evolve into autonomous agents, understanding agentic workflow design patterns has…

3 months ago