owasp

HTML-Entity escaping to prevent XSS

若如初见. 提交于 2019-12-03 09:14:33
问题 I have some user input. Within my code, I ensure that the following symbols are escaped: & -> & < -> < > -> > OWASP states that there are more chars to be escaped. For attributes, I do another kind of escaping: & -> & " -> " This ensures that all attributes are enclosed by ". This makes me sure about my html-attributes, but not about HTML itself. I wonder if my escaping is sufficient. I've read this post, but I'm still not sure about my concern. (JavaScripts are escaped with the OWASP-Library

Why should I put a CSRF token in a JWT token?

余生长醉 提交于 2019-12-03 03:46:40
I want to bring a doubt about JWT tokens and CSRF from the Stormpath post that explain the advantages and disadvantages of storing the JWT either in localStorage or cookies. [...] if you are reading values out of a cookie using JS, that means you can't set the Httponly flag on the cookie, so now any JS on your site can read it, thus making it the exact same security-level as storing something in localStorage. I'm trying to understand why they recommend adding the xsrfToken to the JWT. Doesn't storing your JWT in the cookie and then extracting it out and placing the JWT in the HTTP header and

Basic Authorization in OWASP ZAP

匿名 (未验证) 提交于 2019-12-03 01:40:02
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: I need to attack endpoints via OWASP ZAP tool (got 2.5.0 version). I tested endpoints via Postman. I`ve got Authorization with Type: Basic Auth, Username:exampleUserName, Password: examplePass. Please could you give me any hints, how to set up Basic Auth in OWASP ZAP please? I set up User for my Context. What esle is needed? Found solution: 1) Control Panel -> Internet Options -> Connections ->LAN Settings -> check "Use a proxy for etc." -> click OK 2) Send request via Postman with Basic Auth 3) The endpoint is visible in OWASP ZAP tool, in

Security: Session Identifier Not Updated in tcl

安稳与你 提交于 2019-12-02 06:34:27
问题 I'm working on open-source application "Project-Open" and during the scanning I got the following vulnerability: [Medium] Session Identifier Not Updated Issue: 13800882 Severity: Medium URL: https://<server_name>/register/ Risk(s): It is possible to steal or manipulate customer session and cookies, which might be used to impersonate a legitimate user,allowing the hacker to view or alter user records, and to perform transactions as that user Fix: Do not accept externally created session

Security: Session Identifier Not Updated in tcl

情到浓时终转凉″ 提交于 2019-12-02 01:31:59
I'm working on open-source application "Project-Open" and during the scanning I got the following vulnerability: [Medium] Session Identifier Not Updated Issue: 13800882 Severity: Medium URL: https://<server_name>/register/ Risk(s): It is possible to steal or manipulate customer session and cookies, which might be used to impersonate a legitimate user,allowing the hacker to view or alter user records, and to perform transactions as that user Fix: Do not accept externally created session identifiers though the fix is mentioned but it is not sufficient for me to understand it completely.please

Passing variables on the command line to a Cucumber test

為{幸葍}努か 提交于 2019-12-01 18:17:38
I'm trying to keep usernames and passwords for a cucumber project out of version control. Is there a way to manually pass variables on the command line like usernames and passwords to a cucumber script? My backup plan was to put them in a YML file and add that file to the gitignore so they aren't put in version control. Parva Thakkar So, I saw your comments with the Tin Man, and answer is Yes. cucumber PASSWORD=my_password PASSWORD is set as an environment variable and you can use its value by referring to it as ENV['PASSWORD'] . For an example, browser.text_field(:id => 'pwd').set ENV[

2019测试指南-测试&测试原理

为君一笑 提交于 2019-12-01 18:10:18
什么是测试? 在Web应用程序的开发生命周期中,需要测试许多东西,但测试实际上意味着什么?Merriam-Webster Dictionary将测试描述为: 进行测试或证明。 进行测试。 根据测试分配站立或评估。 出于本文档的目的,测试是将系统或应用程序的状态与一组标准进行比较的过程。在安全行业中,人们经常根据既不明确也不完整的一套心理标准进行测试。因此,许多外人将安全测试视为黑色艺术。本文档的目的是改变这种看法,并使没有深入安全知识的人更容易在测试中发挥作用。 为何进行测试? 本文档旨在帮助组织了解测试程序的内容,并帮助他们确定在Web应用程序上构建和运行测试程序所需采取的步骤。该指南提供了制作全面的Web应用程序安全程序所需元素的广泛视图。本指南可用作参考指南和方法,以帮助确定现有实践与行业最佳实践之间的差距。本指南允许组织将自己与业界同行进行比较,了解测试和维护软件所需的资源量,或准备审计。本章不涉及如何测试应用程序的技术细节,因为其目的是提供典型的安全组织框架。 什么时候测试? 今天的大多数人都不会测试软件,直到它已经被创建并处于其生命周期的部署阶段(即,代码已经创建并实例化为工作的Web应用程序)。这通常是一种非常无效且成本过高的做法。防止安全漏洞出现在生产应用程序中的最佳方法之一是通过在每个阶段中包含安全性来改进软件开发生命周期(SDLC)

2019测试指南-推导安全测试要求

杀马特。学长 韩版系。学妹 提交于 2019-12-01 18:09:59
获得安全测试要求 要获得成功的测试程序,必须知道测试目标是什么。这些目标由安全要求指定。本节详细讨论了如何通过从适用的标准和法规以及正面和负面的应用程序要求中获取安全测试的要求来记录安全测试的要求。它还讨论了安全要求如何在SDLC期间有效推动安全测试,以及如何使用安全测试数据来有效管理软件安全风险。 测试目标 安全测试的目标之一是验证安全控制是否按预期运行。这通过描述安全控件功能的 安全要求进行 记录。从较高的层面来说,这意味着要证明数据和服务的机密性,完整性和可用性。另一个目标是验证安全控制是在很少或没有漏洞的情况下实现的。这些是常见的漏洞,例如 OWASP Top Ten ,以及之前在SDLC期间通过安全评估确定的漏洞,例如威胁建模,源代码分析和渗透测试。 安全要求文档安全要求文档 的第一步是了解 业务要求 。业务需求文档可以提供有关应用程序的预期功能的初始高级信息。例如,应用程序的主要目的可能是向客户提供金融服务或允许从在线目录中购买商品。业务要求的安全部分应强调保护客户数据以及遵守适用的安全文档(如法规,标准和策略)的必要性。 适用法规,标准和策略的一般清单是Web应用程序的良好初步安全合规性分析。例如,可以通过检查有关业务部门以及应用程序将运行的国家或州的信息来识别合规性法规。其中一些合规性指南和法规可能转化为安全控制的特定技术要求。例如,在财务应用程序的情况下

2019测试指南-web应用程序安全测试(二)识别应用程序入口点

可紊 提交于 2019-12-01 18:09:40
在进行任何全面测试之前,枚举应用程序及其攻击面是一个关键的前提,因为它允许测试人员识别可能的弱点区域。本节旨在帮助识别和绘制应用程序中应在枚举和映射完成后应进行调查的区域。 测试目标 了解请求的形成方式以及应用程序的典型响应 如何测试 在开始任何测试之前,测试人员应该始终充分了解应用程序以及用户和浏览器如何与之通信。当测试人员遍历应用程序时,他们应该特别注意所有HTTP请求(GET和POST方法,也称为Verbs),以及传递给应用程序的每个参数和表单字段。此外,他们应该注意何时使用GET请求以及何时使用POST请求将参数传递给应用程序。使用GET请求是很常见的,但是当传递敏感信息时,它通常在POST请求的主体内完成。 请注意,要查看POST请求中发送的参数,测试人员需要使用拦截代理(例如,OWASP: Zed攻击代理(ZAP) )或浏览器插件等工具。在POST请求中,测试人员还应特别注意传递给应用程序的任何隐藏表单字段,因为这些字段通常包含敏感信息,例如状态信息,项目数量,项目价格,开发人员从不供您查看或更改。 根据作者的经验,在此阶段的测试中使用拦截代理和电子表格非常有用。代理将跟踪测试人员和应用程序之间的每个请求和响应。此外,此时,测试人员通常会捕获每个请求和响应,以便他们可以准确地查看传递给应用程序的每个标头,参数等以及返回的内容。这有时可能非常繁琐,特别是在大型互动网站上

Passing variables on the command line to a Cucumber test

怎甘沉沦 提交于 2019-12-01 17:44:50
问题 I'm trying to keep usernames and passwords for a cucumber project out of version control. Is there a way to manually pass variables on the command line like usernames and passwords to a cucumber script? My backup plan was to put them in a YML file and add that file to the gitignore so they aren't put in version control. 回答1: So, I saw your comments with the Tin Man, and answer is Yes. cucumber PASSWORD=my_password PASSWORD is set as an environment variable and you can use its value by