Code Monkey home page Code Monkey logo

www-community's Introduction

OWASP Community Pages

GitHub repo size

OWASP Community Pages is a repository for community contributions for security-related content. The documents here create the website at https://owasp.org/www-community/.

Contributing

We welcome contributions for new content and updates to current pages. This repository uses a fork and pull model. Here are the steps for becoming a contributor:

  1. Fork this repository and clone your fork.
  2. In the pages/ directory, make your changes or additions. For creating new content, please see below.
  3. Push your changes to your fork, then open a pull request against this repository.

If you are making changes that address an existing issue, please make a comment in the issue so we can assign it to you. This helps to prevent accidentally doubling up on work.

Creating New Content

Go into the pages folder and create a new file.

Place the following front matter and include tag at the beginning of your file. Feel free to copy and edit this example:

---

layout: col-sidebar
title: "My Page"
author: "My Name"
contributors: ["Additional Contributor Names", "If Any"]
permalink: /MyPageTitle
tags: ["attack", "XSS"]

---

{% include writers.html %}

Write your content here!

The fields contributors, permalink, and tags are optional. When in doubt, it's okay to leave them blank.

Rules for Contributors

  1. Your contribution must be your own original work. You may not submit copyrighted content you do not own. Please do not plagiarize.
  2. Please ensure that contributions are vendor and product neutral.

Note for Returning Contributors

In July of 2020, the repository's git history was rewritten to reduce its size (over 5GB!). If you forked before this date, please delete your fork and local clones, then re-fork or re-clone this repository.

www-community's People

Contributors

adeyosemanputra avatar adubhlaoich avatar alxndrsn avatar binarymist avatar bkimminich avatar christopherhackett avatar coadaflorin avatar davewichers avatar decidedlygray avatar fcerullo-cycubix avatar fredfalcon avatar fzipi avatar hblankenship avatar itamarlavender avatar j12934 avatar johndileo avatar kingthorin avatar mtesauro avatar nbaars avatar noraj avatar owaspfoundation avatar prakhar-shankar avatar psiinon avatar rewtd avatar sebadele avatar sreenum42 avatar takaharuogasa avatar tghosth avatar wurstbrot avatar zbraiterman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

www-community's Issues

Broken links on XSS page

Broken links can be found on https://owasp.org/www-community/attacks/xss/

Under the Related Security Activities heading, several links are broken

Similarly under the References section, the following links are broken:

Also under References, this link should be updated

Error in the Risk Rating Methodology page

In the "Threat Agent Factors" chapter the "Skill Level" ratings are inverted:

Expected:

No technical skills (9), some technical skills (6), advanced computer user (5), network and programming skills (3), security penetration skills (1)

Presented:

No technical skills (1), some technical skills (3), advanced computer user (5), network and programming skills (6), security penetration skills (9)

SAST Tools listed on 2 pages - Suggest maintaining only on 1

I've been maintaining this page:

https://github.com/OWASP/www-community/blob/master/pages/Source_Code_Analysis_Tools.md

and I notice that this page has a list of SAST tools too:

https://github.com/OWASP/www-community/blob/master/pages/controls/Static_Code_Analysis.md

This seems redundant, hard to maintain. I suggest that the list of tools be maintained on the 1st page above, and the 2nd page simply reference the 1st. To me the 2nd page should simply describe what Static Code Analysis IS.

XSS Filter Evasion Cheat Sheet: Hide malicious attributes to whitelist approach filters using a single slash

I've found a way to bypass certain filters which implement the following behaviour: The filter checks everything between opening and closing or opening and opening brackets. A whitelist is checked against the HTML tag as well as every attribute found within the brackets. Whenever an attribute is not whitelisted the filter will block the input. Closing tags are detected as soon as a slash is found between both brackets. As they aren't considered to contain malicious attributes they are always permitted.

Most HTML tags are opened and closed like this:
<p style="color:blue;">Text</p>
Normally closing tags don't contain any attributes. I found that some filters skip checking for further attributes as soon as they see a slash as they expect to handle a closing tag. Thus it is possible to inject the following JavaScript:
<img src="fail.jpg" / onerror="alert('XSS')"> while <img src="fail.jpg" onerror="alert('XSS')"> gets blocked. The execution of the injected JavaScript has been verified in Firefox 68.9.0 ESR and Chromium 80.0.3987.162. A demonstration can be found in the following video: https://www.youtube.com/watch?v=KBOYJQ45k00

I think this is something which should be considered to be added to the XSS Filter Evasion Cheat Sheet.

Asset storage needs a plan

Receiving objects: 100% (3022/3022), 4.36 GiB | 25.37 MiB/s, done.

That's going to prevent community contribution in some cases. Even on half-gig service that just took me a few minutes. People with lesser service just won't bother in the future.

Proxy

##Hey. I apologize for my poor English.
I'm trying to intercept the traffic of the system process "SYSTEM (pid 4)", but I can not do this on my computer. Therefore, I use the MITM attack method, redirect the traffic of interest to owasp through my router using the iptables rule:
iptables -t nat -A PREROUTING --dst 10 * .19. ***. 119 -p tcp --dport 443 -j DNAT --to-destination 192.168.1.93
where local 192.168.1.93 is the IP and OWASP zap port, 10*.19.***.119 is the recipient address of the HTTPS packets that I need modify the packets in WASP and forward to 10*.19.***.120: 443
10*.19.***.120:443, 10*.19.***.119:443- is HTTPS ssl server port
11
12
But I get an error in the browser.
PS: owasp certificate was imported into the system.
13

RUS description of trouble
Привет. Прошу прощения за мой плохой английский.
Я пытаюсь перехватить трафик системного процесса "SYSTEM (пид 4)", но не могу этого сделать на своём компьютере. Поэтому я использую метод атаки MITM, перенаправляю в owasp интересующий меня траффик через мой роутер используя iptables правило:
iptables -t nat -A PREROUTING --dst 10*.19.***.119 -p tcp --dport 443 -j DNAT --to-destination 192.168.1.93:443
где локальный 192.168.1.93:443 - IP и порт OWASP zap, 10*.19.***.119 - адрес получателя ХТТПС пакетов, которые мне нужно перехватить и отправить на 10*.19.***.120:443
10*.19.***.120:443, 10*.19.***.119:443 - это HTTPS ssl server port
Но я получаю ошибку в браузере.
ПС: сертификат owasp был импортирован в ситеме.

Posible fake website that accepts payments

www-community/_data/tools.json cites "misterscanner.com" at the top most position of the table.
https://owasp.org/www-community/Vulnerability_Scanning_Tools

This website does not offer free scanning services.
The site redirects to Paypal's sandbox.paypal.com URL when you select the 6USD yearly plan. ( this website is used for development purposes)
All other pricier plans complete the payment process and charge.
After paying for a plan, the website immediately starts a "scan" on the selected domain without any DNS ownership validations. The results of this scan can't be found anywhere on the website and we never receive an email with the attached PDF of the results.
The chat function with "Alex" and email option never respond to our requests for help.
The website and email service are hosted on GoDaddy.

Please review this information and take appropriate action.

Ambiguous DOM-based XSS definition

There seems to be 2 different definitions for DOM-based XSS

DOM Based XSS (or as it is called in some texts, “type-0 XSS”) is an XSS attack wherein the attack payload is executed as a result of modifying the DOM “environment” in the victim’s browser used by the original client side script, so that the client side code runs in an “unexpected” manner. That is, the page itself (the HTTP response that is) does not change, but the client side code contained in the page executes differently due to the malicious modifications that have occurred in the DOM environment.

And the second one

DOM Based XSS is a form of XSS where the entire tainted data flow from source to sink takes place in the browser, i.e., the source of the data is in the DOM, the sink is also in the DOM, and the data flow never leaves the browser.

Consider a case where SPA retrieves data from json api, and insecurely inserts the data on the page using innerHTML. It looks like it would fit the first definition of DOM-based XSS, but not the second.

Many sources seem to define DOM-based xss in a way that my example would fall under it. Examples:

DOM-based XSS [16], a vulnerability class subsuming all Cross-site Scripting problems that are caused by insecure handling of untrusted data through JavaScript.

In contrast to the server-side variants of XSS, namely reflected and persistent, the term DOM-based Cross-Site Scripting (or DOM-based XSS) subsumes all classes of vulnerabilities which are caused by insecure client-side code

For readability, the example in Fig. 1 is artificially simple, which may convey a false impression that XSS vulnerabilities are not difficult to detect or mitigate. In reality, the information flow from XSS sources to sinks can be extremely complex and often goes through servers and databases
It is a typical client-side XSS vulnerability, aka. DOM-based XSS.

We do not address DOM-based (Type III) XSS attacks, where trusted client-side JavaScript permits the injection of untrusted content in violation the web application’s security policy

Entropy recomendation for Insufficient Session-ID Length should be explained

The entropy recomendations for the Insufficient Session-ID Length vulnerability state that

Assuming that the session identifiers are being generated using a good source of random numbers, we will estimate the number of bits of entropy in a session identifier to be half the total number of bits in the session identifier.

Since this is a non-obvious claim and the reasoning behind it elludes me, this claim should be backed up by a source link and/or some explanation.

Broken Links

Was going through pages, found plenty of broken references. Ran a broken URL checker against the website, found a lot of broken URLs. Fixed some of them in #290 . Some URLs remain broken:

https://support.google.com/mail/forum/AAAAK7un8RU3J3r2JqFNTw/discussion/?hl=en&gpf=d/topic/gmail/3J3r2JqFNTw/discussion
https://www.javaworld.com/javaworld/javaqa/2003-05/01-qa-0509-jcrypt.html?page=2
http://www.php-security.org/downloads/rips.pdf
http://www.seclab.tuwien.ac.at/papers/pixy.pdf
http://w2spconf.com/2010/papers/p27.pdf
https://www.codemagi.com/blog/post/194
https://www.itu.int/rec/T-REC-X.690-200811-I/en
https://www.ietf.org/id/draft-ietf-websec-key-pinning-09.txt
https://github.com/andresriancho/w3af/blob/master/plugins/grep/csp.py
http://blog.php-security.org/archives/76-Holes-in-most-preg_match-filters.html
http://www.webapptest.org/ms-access-sql-injection-cheat-sheet-EN.html
http://labs.idefense.com/intelligence/vulnerabilities/display.php?id=77
http://www.ruxcon.org.au/files/2008/Attacking_Rich_Internet_Applications.pdf
http://yehg.net/lab/pr0js/files.php/inspath.zip
http://yehg.net/lab/pr0js/files.php/php_brute_force_detect.zip
http://www.comptechdoc.org/independent/web/cgi/ssimanual/ssiexamples.html
http://www.iss.net/security_center/advice/Exploits/TCP/session_hijacking/default.htm
http://www.derkeiler.com/pdf/Mailing-Lists/Securiteam/2002-12/0099.pdf
http://archives.neohapsis.com/archives/bugtraq/2002-05/0118.html
http://hacker-eliminator.com/trojansymptoms.html
http://www.microsoft.com/technet/security/bulletin/MS00-078.mspx
https://www.checkmarx.com/Demo/XSHM.aspx
https://blog.watchfire.com/wfblog/2008/06/javascript-code.html
http://shlang.com/netkill/netkill.html
https://cirt.net/code/nikto.shtml
https://addons.mozilla.org/en-US/firefox/addon/heartbleed-checker/
https://www.ecrimelabs.com/tools/webroot/WebRoot.txt
https://www.cs.rice.edu/~scrosby/hash/slides/USENIX-RegexpWIP.2.ppt
https://www.checkmarx.com/NewsDetails.aspx?id=23&cat=3
https://owasp.org/index.php/Dhiraj_Mishra
http://puzzlemall.googlecode.com/files/Session
https://owasp.org/index.php/Image:RequestRodeo-MartinJohns.pdf
http://windows.stanford.edu/docs/IISsecchecklist.htm
http://www.net-security.org/dl/articles/php-file-upload.pdf
http://www.windowsitpro.com/Files/18/27072/Webtable_01.pdf
https://www.imperva.com/404?aspxerrorpath=/application_defense_center/glossary/forceful_browsing.html
http://info.sen.ca.gov/pub/01-02/bill/sen/sb_1351-1400/sb_1386_bill_20020926_chaptered.html
https://blog.shapesecurity.com/heartbleed-bug-places-encrypted-user-data-and-webservers-at-risk
https://www.mitre.org/sites/default/files/publications/pr-18-2417-deliver-uncompromised-MITRE-study-8AUG2018.pdf
http://www.microsoft.com/technet/security/bulletin/ms04-028.mspx
http://www.digitaldwarf.be/products/mangle.c
http://projects.info-pull.com/mokb/
http://www.bonsai-sec.com/en/research/untidy-xml-fuzzer.php
https://support.snyk.io/snyk-cli/how-can-i-set-a-snyk-cli-project-as-open-source
http://www.rubcast.rub.de/index2.php?id=1009
http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf
http://aeditor.rubyforge.org/ruby_cplusplus/index.html
https://owasp-skf.gitbook.io/asvs-write-ups/filename-injection
http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
https://blog.48bits.com/2010/09/28/iis6-asp-file-upload-for-fun-and-profit/
http://palisade.plynt.com/issues/2006Jun/injection-stored-procedures/
http://www.bindshell.net/tools/odysseus
http://www.ntobjectives.com/products/firewater/
http://home.intekom.com/rdawes/exodus.html
http://www.wastelands.gen.nz/odysseus/index.php
http://www.webcohort.com/web_application_security/research/tools.html
http://www.rsasecurity.com/standards/ssl/basics.html
http://palisade.plynt.com/issues/2005Aug/page-tokens/
http://www.microsoft.com/mspress/books/toc/5612.asp
http://www.seczone.cn/2018/06/27/codesec源代码安全检测平台/

If anyone wants to go through these, grep --color=always -nr -Ff broken_urls_left.txt|grep --color=always -v "broken_"|sort will show where those URLs are specifically (might miss some of these, though). Could probably also find a lot of broken internal references by looking for "wikilink".

Retire CSRF attacks

Since browsers stop sending cookies across origins, is this a time to retire the CSRF chapter? Or put a big IF condition for the attack narrowing it down to request handlers whose authentication handlers issued a SameSite=None attribute with their session cookie?

https://web.dev/samesite-cookies-explained/

(I guess every vulnerability, not just CSRF could benefit from formalizing the conditions on their context. E.g., overly permissive CORS would be conditional on the presence of the respective ACAO response AND exposing sensitive data with a browser's platform authentication. The missing HTTPOnly attribute in cookies is dangerous in a context of a malicious script such as a third-party tracker).

404 for all XSS testing resources

See the latest OWASP Testing Guide article on how to test for the various kinds of XSS vulnerabilities.

Testing_for_Reflected_Cross_site_scripting_(OWASP-DV-001)
Testing_for_Stored_Cross_site_scripting_(OWASP-DV-002)
Testing_for_DOM-based_Cross_site_scripting_(OWASP-DV-003)

all of those links go to 404s.

HttpOnly needs updates

I just finished dealing with auto-migrated issues for this article, it could definitely use some content updates:
https://github.com/OWASP/www-community/blob/master/pages/HttpOnly.md it still talks about old versions of IE and Opera.

This article includes an extensive table that needs re-working after the auto-migration as well (which I did not tackle).

Is Opera even relevant in 2020? Do we still care about IE with Edge/Edge Chrome?

DOM Based XSS attack example no longer viable due to Browser encoding

The example code


Select your language:

<select><script>

document.write("<OPTION value=1>"+document.location.href.substring(document.location.href.indexOf("default=")+8)+"</OPTION>");

document.write("<OPTION value=2>English</OPTION>");

</script></select>

Is no longer vulnerable on most modern browsers since document.location.href is URL encoded by default. The example should be updated to reflect that decoding is required for the attack to work as described.

Incorrect Format_string_attack example

In the page:

https://github.com/OWASP/www-community/blob/master/pages/attacks/Format_string_attack.md

There is an example of a format string attack.
The example is:

int main (int argc, char **argv) {
char buf [100]; int x = 1 ;
snprintf ( buf, sizeof buf, argv [1] ) ;
buf [ sizeof buf -1 ] = 0;
printf ( “Buffer size is: (%d) \nData input: %s \n” , strlen (buf) , buf ) ;
printf ( “X equals: %d/ in hex: %#x\nMemory address for x: (%p) \n” , x, x, &x) ;
return 0 ; }

And the explanation is that the %x or %s gets expanded in the printf function.
This is completely wrong.
The crash happens in the line of snprintf , NOT in the printf line.

The line printf ( “Buffer size is: (%d) \nData input: %s \n” , strlen (buf) , buf ) ; is safe!
And printf("my string is %s", "%s%s%s%s%s%s%s") will NOT cause a crash

Migrated assets with quotes?

I just did a git pull and git attempted to create the following files, I don't actually see them in the repo (GitHub web view) or my file system, but it seems likely there's an issue somewhere (git knows/believes they are there):

 create mode 100644 "assets/files/migrated/02_INGENIER\303\215A_SOCIAL.pdf"
 create mode 100644 "assets/files/migrated/04_OWASP_LatamTur2012_M.Mart\303\255nez.pdf"
 create mode 100644 "assets/files/migrated/04_OWASP_TOP10_como_base_para_Inspecci\303\263n_de_C\303\263digo.pdf"
 create mode 100644 "assets/files/migrated/1st_URUGUAY_OWASP_DAY_-_Mateo_Mart\303\255nez.pdf"
 create mode 100644 "assets/files/migrated/2011\353\205\2046\354\233\224_OWASP_\354\213\234\355\201\220\354\226\264\354\275\224\353\224\251\352\267\234\354\271\231_v2_KOR.pdf"
 create mode 100644 "assets/files/migrated/2013-1_C\303\263mo_construir_un_modelo_de_desarrollo_seguro_-_Mateo_Martinez_-_URUGUAY_-.pdf"
 create mode 100644 "assets/files/migrated/2013-3_ZAP_OWASP_-_A_Real_ZAP_Story_-_Mateo_Mart\303\255nez_v0.1.pdf"
 create mode 100644 "assets/files/migrated/2013-4_CAPTCHA_Hacking_T\303\251cnicas_y_herramientas_que_vulneran_sitios_de_la_banca_y_comercio_electr\303\263nico_-_Ricardo_Supo_-_PERU_-.pdf"
 create mode 100644 "assets/files/migrated/2013-5_OWASP-BWA_Hacking_the_Web,_como_aprender_y_practicar_sin_terminar_en_la_c\303\241rcel._-_Felipe_Sanchez_-_CHILE_-.pdf"
 create mode 100644 "assets/files/migrated/2014-abril-3_Innovaci\303\263n_y_emprendimiento.pdf"
 create mode 100644 "assets/files/migrated/5-OWASP-LatamTour2013_(Mateo_Mart\303\255nez).pdf"
 create mode 100644 "assets/files/migrated/\302\277C\303\263mo_lo_Lograron_.pdf"

Edit: To be clear the pull successfully added 100s of other assets and changes without issue, those above just stuck out as strange/problematic.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.