Compare commits
14 Commits
Author | SHA1 | Date | |
---|---|---|---|
27f23fea19 | |||
9bd7a81435 | |||
08ccb069df | |||
2357651570 | |||
b25caa5c2f | |||
9c354d5699 | |||
84029345b4 | |||
a0ca199cdc | |||
2058298e2d | |||
17acef57b4 | |||
d913967ec5 | |||
87edc7d1db | |||
ac7a9c7863 | |||
2803ef45e4 |
1
.github/dependabot.yml
vendored
1
.github/dependabot.yml
vendored
@ -12,4 +12,3 @@ updates:
|
|||||||
directory: "/"
|
directory: "/"
|
||||||
schedule:
|
schedule:
|
||||||
interval: "weekly"
|
interval: "weekly"
|
||||||
|
|
||||||
|
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@ -1,4 +1,4 @@
|
|||||||
name: "Pull requests build"
|
name: "Main / Pull requests build"
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
|
29
.github/workflows/pre-commit.yaml
vendored
Normal file
29
.github/workflows/pre-commit.yaml
vendored
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
name: Pre-commit check
|
||||||
|
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
branches: [main]
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
jobs:
|
||||||
|
pre-commit:
|
||||||
|
name: Pre-commit check
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout git repository
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
- name: Setup python
|
||||||
|
uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: "3.9"
|
||||||
|
- uses: actions/setup-java@v4
|
||||||
|
with:
|
||||||
|
distribution: 'temurin'
|
||||||
|
java-version: '17'
|
||||||
|
- name: Pre-commit checks
|
||||||
|
uses: pre-commit/action@v3.0.0
|
||||||
|
- name: pre-commit-ci-lite
|
||||||
|
uses: pre-commit-ci/lite-action@v1.0.1
|
||||||
|
if: always()
|
1
.github/workflows/release.yml
vendored
1
.github/workflows/release.yml
vendored
@ -147,4 +147,3 @@ jobs:
|
|||||||
github_token: "${{ secrets.GITHUB_TOKEN }}"
|
github_token: "${{ secrets.GITHUB_TOKEN }}"
|
||||||
title: ${{ github.event.commits[0].message }}
|
title: ${{ github.event.commits[0].message }}
|
||||||
target_branch: main
|
target_branch: main
|
||||||
|
|
||||||
|
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
@ -24,7 +24,7 @@ jobs:
|
|||||||
- uses: actions/checkout@v3
|
- uses: actions/checkout@v3
|
||||||
# Uses an action to add Python to the VM
|
# Uses an action to add Python to the VM
|
||||||
- name: Setup Python
|
- name: Setup Python
|
||||||
uses: actions/setup-python@v4
|
uses: actions/setup-python@v5
|
||||||
with:
|
with:
|
||||||
python-version: '3.7'
|
python-version: '3.7'
|
||||||
architecture: x64
|
architecture: x64
|
||||||
|
28
.pre-commit-config.yaml
Normal file
28
.pre-commit-config.yaml
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
ci:
|
||||||
|
autofix_commit_msg: |
|
||||||
|
[pre-commit.ci] auto fixes from pre-commit.com hooks
|
||||||
|
autofix_prs: false # managed in the action step
|
||||||
|
autoupdate_branch: ""
|
||||||
|
autoupdate_commit_msg: "[pre-commit.ci] pre-commit autoupdate"
|
||||||
|
autoupdate_schedule: weekly
|
||||||
|
skip: []
|
||||||
|
submodules: false
|
||||||
|
repos:
|
||||||
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
|
rev: v4.4.0
|
||||||
|
hooks:
|
||||||
|
- id: check-yaml
|
||||||
|
- id: end-of-file-fixer
|
||||||
|
exclude: ^(README.md|CREATE_RELEASE.md)
|
||||||
|
- id: trailing-whitespace
|
||||||
|
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
|
||||||
|
rev: v9.5.0
|
||||||
|
hooks:
|
||||||
|
- id: commitlint
|
||||||
|
stages: [commit-msg]
|
||||||
|
- repo: https://github.com/ejba/pre-commit-maven
|
||||||
|
rev: v0.3.4
|
||||||
|
hooks:
|
||||||
|
- id: maven
|
||||||
|
args: [ 'clean compile' ]
|
||||||
|
- id: maven-spotless-apply
|
1
FAQ.md
1
FAQ.md
@ -5,4 +5,3 @@
|
|||||||
### Integration tests fail
|
### Integration tests fail
|
||||||
|
|
||||||
Try to run the command in the console `java -jar ...` and remove `-Dlogging.pattern.console=` from the command line.
|
Try to run the command in the console `java -jar ...` and remove `-Dlogging.pattern.console=` from the command line.
|
||||||
|
|
||||||
|
@ -17,18 +17,18 @@ The following steps are required when you want to add a new language
|
|||||||
1. Update [main_new.html](src/main/resources/webgoat/static/main_new.html)
|
1. Update [main_new.html](src/main/resources/webgoat/static/main_new.html)
|
||||||
1. Add the parts for showing the flag and providing the correct value for the flag= parameter
|
1. Add the parts for showing the flag and providing the correct value for the flag= parameter
|
||||||
2.
|
2.
|
||||||
3. Add a flag image to src/main/resources/webgoat/static/css/img
|
2. Add a flag image to src/main/resources/webgoat/static/css/img
|
||||||
1. See the main_new.html for a link to download flag resources
|
1. See the main_new.html for a link to download flag resources
|
||||||
4. Add a welcome page to the introduction lesson
|
3. Add a welcome page to the introduction lesson
|
||||||
1. Copy Introduction_.adoc to Introduction_es.adoc (if in this case you want to add Spanish)
|
1. Copy Introduction_.adoc to Introduction_es.adoc (if in this case you want to add Spanish)
|
||||||
2. Add a highlighted section that explains that most parts of WebGoat will still be in English and invite people to translate parts where it would be valuable
|
2. Add a highlighted section that explains that most parts of WebGoat will still be in English and invite people to translate parts where it would be valuable
|
||||||
5. Translate the main labels
|
4. Translate the main labels
|
||||||
1. Copy messages.properties to messages_es.properties (if in this case you want to add Spanish)
|
1. Copy messages.properties to messages_es.properties (if in this case you want to add Spanish)
|
||||||
2. Translate the label values
|
2. Translate the label values
|
||||||
6. Optionally translate lessons by
|
5. Optionally translate lessons by
|
||||||
1. Adding lang specifc adoc files in documentation folder of the lesson
|
1. Adding lang specifc adoc files in documentation folder of the lesson
|
||||||
2. Adding WebGoatLabels.properties of a specific language if you want to
|
2. Adding WebGoatLabels.properties of a specific language if you want to
|
||||||
7. Run mvn clean to see if the LabelAndHintIntegration test passes
|
6. Run mvn clean to see if the LabelAndHintIntegration test passes
|
||||||
8. Run WebGoat and verify that your own language and the other languages work as expected
|
7. Run WebGoat and verify that your own language and the other languages work as expected
|
||||||
|
|
||||||
If you only want to translate more for a certain language, you only need to do step 4-8
|
If you only want to translate more for a certain language, you only need to do step 4-8
|
||||||
|
@ -215,4 +215,3 @@ Special thanks to the following contributors providing us with a pull request:
|
|||||||
And everyone who provided feedback through Github.
|
And everyone who provided feedback through Github.
|
||||||
|
|
||||||
Team WebGoat
|
Team WebGoat
|
||||||
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
# WebGoat landing page
|
# WebGoat landing page
|
||||||
|
|
||||||
Old GitHub page which now redirects to OWASP website.
|
Old GitHub page which now redirects to OWASP website.
|
||||||
|
|
||||||
|
4
pom.xml
4
pom.xml
@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
<groupId>org.owasp.webgoat</groupId>
|
<groupId>org.owasp.webgoat</groupId>
|
||||||
<artifactId>webgoat</artifactId>
|
<artifactId>webgoat</artifactId>
|
||||||
<version>2023.8</version>
|
<version>2023.9-SNAPSHOT</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>WebGoat</name>
|
<name>WebGoat</name>
|
||||||
@ -110,7 +110,7 @@
|
|||||||
<properties>
|
<properties>
|
||||||
<!-- Shared properties with plugins and version numbers across submodules-->
|
<!-- Shared properties with plugins and version numbers across submodules-->
|
||||||
<asciidoctorj.version>2.5.10</asciidoctorj.version>
|
<asciidoctorj.version>2.5.10</asciidoctorj.version>
|
||||||
<bootstrap.version>5.3.1</bootstrap.version>
|
<bootstrap.version>5.3.2</bootstrap.version>
|
||||||
<cglib.version>3.3.0</cglib.version>
|
<cglib.version>3.3.0</cglib.version>
|
||||||
<!-- do not update necessary for lesson -->
|
<!-- do not update necessary for lesson -->
|
||||||
<checkstyle.version>3.3.1</checkstyle.version>
|
<checkstyle.version>3.3.1</checkstyle.version>
|
||||||
|
@ -29,8 +29,7 @@ import java.util.Random;
|
|||||||
import org.owasp.webgoat.container.i18n.PluginMessages;
|
import org.owasp.webgoat.container.i18n.PluginMessages;
|
||||||
import org.owasp.webgoat.container.session.UserSessionData;
|
import org.owasp.webgoat.container.session.UserSessionData;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
@ -41,10 +40,9 @@ public class CSRFGetFlag {
|
|||||||
@Autowired UserSessionData userSessionData;
|
@Autowired UserSessionData userSessionData;
|
||||||
@Autowired private PluginMessages pluginMessages;
|
@Autowired private PluginMessages pluginMessages;
|
||||||
|
|
||||||
@RequestMapping(
|
@PostMapping(
|
||||||
path = "/csrf/basic-get-flag",
|
path = "/csrf/basic-get-flag",
|
||||||
produces = {"application/json"},
|
produces = {"application/json"})
|
||||||
method = RequestMethod.POST)
|
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public Map<String, Object> invoke(HttpServletRequest req) {
|
public Map<String, Object> invoke(HttpServletRequest req) {
|
||||||
|
|
||||||
|
@ -29,9 +29,8 @@ import lombok.extern.slf4j.Slf4j;
|
|||||||
import org.owasp.webgoat.container.session.WebSession;
|
import org.owasp.webgoat.container.session.WebSession;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestHeader;
|
import org.springframework.web.bind.annotation.RequestHeader;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
|
||||||
import org.springframework.web.bind.annotation.RequestParam;
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
import org.springframework.web.bind.annotation.ResponseBody;
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
|
||||||
@ -43,7 +42,7 @@ public class Ping {
|
|||||||
|
|
||||||
@Autowired private WebSession webSession;
|
@Autowired private WebSession webSession;
|
||||||
|
|
||||||
@RequestMapping(method = RequestMethod.GET)
|
@GetMapping
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public String logRequest(
|
public String logRequest(
|
||||||
@RequestHeader("User-Agent") String userAgent, @RequestParam(required = false) String text) {
|
@RequestHeader("User-Agent") String userAgent, @RequestParam(required = false) String text) {
|
||||||
|
@ -70,4 +70,3 @@ management.endpoints.web.exposure.include=env, health,configprops
|
|||||||
|
|
||||||
spring.security.oauth2.client.registration.github.client-id=${WEBGOAT_OAUTH_CLIENTID:dummy}
|
spring.security.oauth2.client.registration.github.client-id=${WEBGOAT_OAUTH_CLIENTID:dummy}
|
||||||
spring.security.oauth2.client.registration.github.client-secret=${WEBGOAT_OAUTH_CLIENTSECRET:dummy}
|
spring.security.oauth2.client.registration.github.client-secret=${WEBGOAT_OAUTH_CLIENTSECRET:dummy}
|
||||||
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
ALTER TABLE CONTAINER.ASSIGNMENT ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
ALTER TABLE CONTAINER.ASSIGNMENT ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
||||||
ALTER TABLE CONTAINER.LESSON_TRACKER ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
ALTER TABLE CONTAINER.LESSON_TRACKER ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
||||||
ALTER TABLE CONTAINER.USER_TRACKER ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
ALTER TABLE CONTAINER.USER_TRACKER ALTER COLUMN ID SET GENERATED BY DEFAULT AS IDENTITY(START WITH 1);
|
||||||
|
|
||||||
|
@ -38,4 +38,3 @@ password=Passwort
|
|||||||
password.confirm=Wiederhohl Passwort
|
password.confirm=Wiederhohl Passwort
|
||||||
sign.up=Anmelden
|
sign.up=Anmelden
|
||||||
register.title=Registrieren
|
register.title=Registrieren
|
||||||
|
|
||||||
|
50
src/main/resources/i18n/messages_es.properties
Normal file
50
src/main/resources/i18n/messages_es.properties
Normal file
@ -0,0 +1,50 @@
|
|||||||
|
lesson.completed=Felicidades. Has completado con éxito esta lección.
|
||||||
|
assignment.solved=Felicidades. Has completado con éxito la tarea.
|
||||||
|
assignment.not.solved=Lo siento, la solución no es correcta. Por favor, inténtalo de nuevo.
|
||||||
|
RestartLesson=Reiniciar esta lección
|
||||||
|
SolutionVideos=Videos de la solución
|
||||||
|
ErrorGenerating=Error generando
|
||||||
|
InvalidData=Datos inválidos
|
||||||
|
Go!=!Vamos!
|
||||||
|
password=Contraseña
|
||||||
|
password.confirm=Confirmar contraseña
|
||||||
|
username=Nombre de usuario
|
||||||
|
logged_out=Has cerrado sesión correctamente.
|
||||||
|
invalid_username_password=Nombre de usuario y contraseña inválidos.
|
||||||
|
login.page.title=Página de inicio de sesión
|
||||||
|
accounts.build.in=Las siguientes cuentas están integradas en WebGoat
|
||||||
|
accounts.table.account=Cuenta
|
||||||
|
accounts.table.user=Usuario
|
||||||
|
accounts.table.password=Contraseña
|
||||||
|
logout=Cerrar sesión
|
||||||
|
version=Versión
|
||||||
|
build=Compilación
|
||||||
|
report.card=Informe
|
||||||
|
about=Acerca de WebGoat
|
||||||
|
contact=Contáctanos
|
||||||
|
show.hints=Mostrar pistas
|
||||||
|
lesson.overview=Descripción de la lección
|
||||||
|
reset.lesson=Restablecer lección
|
||||||
|
sign.in=Iniciar sesión
|
||||||
|
register.new=o regístrate como un nuevo usuario
|
||||||
|
sign.up=Registrarse
|
||||||
|
register.title=Registro
|
||||||
|
searchmenu=Búsqueda de lecciones
|
||||||
|
|
||||||
|
|
||||||
|
not.empty=Este campo es obligatorio.
|
||||||
|
username.size=Por favor, utiliza entre 6 y 10 caracteres.
|
||||||
|
username.duplicate=El usuario ya existe.
|
||||||
|
password.size=La contraseña debe contener al menos 6 caracteres.
|
||||||
|
password.diff=Las contraseñas no coinciden.
|
||||||
|
security.enabled=Seguridad habilitada, puedes probar los desafíos anteriores y ver el efecto.
|
||||||
|
security.disabled=Seguridad deshabilitada, puedes probar los desafíos anteriores y ver el efecto.
|
||||||
|
termsofuse=Términos de uso
|
||||||
|
register.condition.1=Mientras ejecutas este programa, tu máquina será extremadamente vulnerable a ataques.\
|
||||||
|
Deberías desconectarte de Internet mientras usas este programa. La configuración predeterminada de WebGoat se une a localhost para minimizar la exposición.
|
||||||
|
register.condition.2=Este programa es solo con fines educativos. Si intentas \
|
||||||
|
estas técnicas sin autorización, es muy probable que te descubran. Si \
|
||||||
|
te descubren participando en hacking no autorizado, la mayoría de las empresas te despedirán. \
|
||||||
|
Alegar que estabas realizando investigación de seguridad no funcionará, ya que eso es lo \
|
||||||
|
primero que afirman todos los hackers.
|
||||||
|
terms.agree=Aceptar los términos y condiciones
|
@ -0,0 +1,11 @@
|
|||||||
|
== Restablecimiento de contraseña con autenticación de dos factores (2FA)
|
||||||
|
|
||||||
|
Un excelente ejemplo de elusión de autenticación es (https://henryhoggard.co.uk/blog/Paypal-2FA-Bypass). El usuario no pudo recibir un SMS con un código, así que optó por un método alternativo que implicaba preguntas de seguridad. Utilizando un proxy, eliminó por completo los parámetros y tuvo éxito.
|
||||||
|
|
||||||
|
image::images/paypal-2fa-bypass.png[Paypal 2FA bypass,1397,645,style="lesson-image"]
|
||||||
|
|
||||||
|
=== El escenario
|
||||||
|
|
||||||
|
Cuando restableces tu contraseña desde un lugar o dispositivo no reconocido por tu proveedor, te solicitarán responder a las preguntas de seguridad que configuraste. El inconveniente adicional es que estas preguntas de seguridad también están almacenadas en otro dispositivo, que no tienes contigo y del cual no recuerdas las respuestas.
|
||||||
|
|
||||||
|
Ya has proporcionado tu nombre de usuario/correo electrónico y has optado por el método de verificación alternativo.
|
@ -0,0 +1,15 @@
|
|||||||
|
== Elusion de Autenticación
|
||||||
|
|
||||||
|
En el contexto de elusiones de autenticación, los atacantes realizan manipulaciones en el sistema con el objetivo de crear las condiciones necesarias para evadir los mecanismos de autenticación. Estas manipulaciones pueden implicar cambios en la configuración o la lógica del sistema, con el fin de aprovechar posibles fallos y eludir las medidas de seguridad establecidas.
|
||||||
|
|
||||||
|
=== Entradas Ocultas
|
||||||
|
|
||||||
|
Una estrategia básica implica confiar en una entrada que se encuentra oculta en la página web o en el Modelo de Objetos del Documento (DOM).
|
||||||
|
|
||||||
|
=== Eliminación de Parámetros
|
||||||
|
|
||||||
|
A veces, si un atacante no conoce el valor correcto de un parámetro en la solicitud web, puede optar por eliminarlo por completo para observar las consecuencias.
|
||||||
|
|
||||||
|
=== Navegación Forzada
|
||||||
|
|
||||||
|
Si una sección de un sitio no está adecuadamente protegida por la configuración, esa sección del sitio puede ser accedida mediante adivinanzas/fuerza bruta.
|
@ -0,0 +1,7 @@
|
|||||||
|
=== Más Contenido, También Videos ...
|
||||||
|
|
||||||
|
Puedes estructurar y dar formato al contenido como prefieras. Incluso puedes incluir videos si lo deseas (aunque puede depender del soporte del navegador). Tal vez prefieras que esté más relacionado con la seguridad de las aplicaciones web que el contenido de este.
|
||||||
|
|
||||||
|
video::video/sample-video.m4v[width=480,start=5]
|
||||||
|
|
||||||
|
see http://asciidoctor.org/docs/asciidoc-syntax-quick-reference/#videos for more detail on video syntax
|
@ -8,4 +8,3 @@ auth-bypass.hints.verify.1=The attack on this is similar to the story referenced
|
|||||||
auth-bypass.hints.verify.2=You do want to tamper the security question parameters, but not delete them
|
auth-bypass.hints.verify.2=You do want to tamper the security question parameters, but not delete them
|
||||||
auth-bypass.hints.verify.3=The logic to verify the account does expect 2 security questions to be answered, but there is a flaw in the implementation
|
auth-bypass.hints.verify.3=The logic to verify the account does expect 2 security questions to be answered, but there is a flaw in the implementation
|
||||||
auth-bypass.hints.verify.4=Have you tried renaming the secQuestion0 and secQuestion1 parameters?
|
auth-bypass.hints.verify.4=Have you tried renaming the secQuestion0 and secQuestion1 parameters?
|
||||||
|
|
||||||
|
@ -0,0 +1,5 @@
|
|||||||
|
== Restricciones de Campo
|
||||||
|
En la mayoría de los navegadores, el cliente tiene control total o casi total sobre la parte HTML de la página web. Pueden modificar valores o restricciones según sus preferencias.
|
||||||
|
|
||||||
|
=== Tarea
|
||||||
|
Envía una solicitud que eluda las restricciones de los cuatro campos mencionados.
|
@ -0,0 +1,6 @@
|
|||||||
|
== Validación
|
||||||
|
|
||||||
|
A menudo, hay algún mecanismo para evitar que los usuarios envíen valores de campo alterados al servidor, como la validación antes del envío. La mayoría de los navegadores populares, como Chrome, no permiten editar scripts durante la ejecución. Tendremos que eludir la validación de alguna otra manera.
|
||||||
|
|
||||||
|
=== Tarea
|
||||||
|
Envía una solicitud que no cumpla con la expresión regular ubicada encima del campo en todos los campos.
|
@ -0,0 +1,9 @@
|
|||||||
|
== Concepto
|
||||||
|
|
||||||
|
Los usuarios tienen un gran control sobre la interfaz del usuario de la aplicación web. Pueden modificar el código HTML, y a veces también los scripts. Las aplicaciones que requieren un formato de entrada específico deben validar también los datos en el lado del servidor.
|
||||||
|
|
||||||
|
== Objetivos
|
||||||
|
|
||||||
|
* El usuario debe tener conocimientos básicos de HTML.
|
||||||
|
* El usuario debe poder manipular una solicitud antes de enviarla (con un proxy u otras herramientas).
|
||||||
|
* El usuario tiene que manipular las restricciones de campo y eludir la validación del lado del cliente.
|
@ -0,0 +1 @@
|
|||||||
|
El administrador olvidó dónde se guarda la contraseña, ¿puedes ayudar?
|
@ -0,0 +1 @@
|
|||||||
|
¿Puedes iniciar sesión como Larry?
|
@ -0,0 +1 @@
|
|||||||
|
¿Puedes iniciar sesión como Tom? Puede ser un poco más difícil que cuando lo hiciste con Larry.
|
@ -0,0 +1 @@
|
|||||||
|
Intenta restablecer la contraseña de admin.
|
@ -0,0 +1 @@
|
|||||||
|
¿Todavía puedes votar?
|
@ -0,0 +1,24 @@
|
|||||||
|
=== Bienvenido al desafío WebGoat (CTF)
|
||||||
|
|
||||||
|
==== Introducción
|
||||||
|
|
||||||
|
Los desafíos contienen lecciones más parecidas a un CTF, donde no proporcionamos explicaciones sobre lo que debes hacer y no se darán pistas. Puedes utilizar estos desafíos en un estilo CTF, donde puedes ejecutar WebGoat en un servidor y todos los participantes pueden unirse y hackear los desafíos. Hay un marcador disponible en el link:scoreboard["scoreboard",window=_blank]
|
||||||
|
|
||||||
|
:hardbreaks:
|
||||||
|
En este CTF, deberás resolver varios desafíos; cada uno te proporcionará una bandera que deberás enviar para obtener puntos.
|
||||||
|
|
||||||
|
Las banderas tienen el siguiente formato: `a7179f89-906b-4fec-9d99-f15b796e7208`
|
||||||
|
|
||||||
|
==== Reglas
|
||||||
|
|
||||||
|
- No intentes hackear la infraestructura de la competición. Si descubres algún error o vulnerabilidad, por favor, envíanos un correo electrónico.
|
||||||
|
|
||||||
|
- Juega limpio, no intentes sabotear a otros equipos competidores ni obstaculizar de ninguna manera el progreso de otro equipo.
|
||||||
|
|
||||||
|
- No se permite el uso de fuerza bruta en desafíos/flags.
|
||||||
|
|
||||||
|
:hardbreaks:
|
||||||
|
*¡Diviértete!*
|
||||||
|
El equipo WebGoat
|
||||||
|
|
||||||
|
image::images/boss.jpg[]
|
@ -0,0 +1,6 @@
|
|||||||
|
== ¡Pruébalo! Trabajando con la pestaña de Red
|
||||||
|
|
||||||
|
En esta tarea, debes encontrar una solicitud HTTP específica y leer un número aleatorio.
|
||||||
|
Para comenzar, haz clic en el primer botón. Esto generará una solicitud HTTP. Intenta encontrar la solicitud HTTP específica.
|
||||||
|
La solicitud debería contener un campo: `networkNum:`
|
||||||
|
Copia el número que se muestra después en el campo de entrada a continuación y haz clic en el botón de verificación.
|
@ -0,0 +1,8 @@
|
|||||||
|
== ¡Pruébalo! Utilizando la consola
|
||||||
|
|
||||||
|
Vamos a intentarlo. Utiliza la consola en las herramientas de desarrollo y llama a la función de JavaScript *webgoat.customjs.phoneHome()*.
|
||||||
|
Deberías recibir una respuesta en la consola. Tu resultado debería lucir algo así:
|
||||||
|
`phone home dijo
|
||||||
|
{"lessonCompleted:true, ... ,"output":"la respuesta de phone home es..."`
|
||||||
|
Después de eso, pega el número aleatorio en el campo de texto a continuación.
|
||||||
|
(Asegúrate de tener el número más reciente, ya que se genera aleatoriamente cada vez que llamas a la función)
|
@ -0,0 +1,15 @@
|
|||||||
|
== La pestaña de la Consola
|
||||||
|
|
||||||
|
En la pestaña de la consola, puedes ver cualquier cosa que un archivo JavaScript cargado haya impreso.
|
||||||
|
No te preocupes si ves algo en rojo. Aunque sea un error, probablemente se haya resuelto por sí mismo.
|
||||||
|
A través de la pestaña de la consola, también puedes ejecutar tu línea de código JavaScript.
|
||||||
|
|
||||||
|
Comienza limpiando la consola con el atajo `CTRL+L`.
|
||||||
|
|
||||||
|
Para ejecutar tu JavaScript, haz clic dentro de la consola y escribe algo como:
|
||||||
|
`console.log("¡Hola WebGoat!");` Presiona Enter. `¡Hola WebGoat!` debería aparecer ahora en tu consola.
|
||||||
|
La consola también te permite hacer algunas operaciones aritméticas básicas. Si escribes, por ejemplo, `1+3` y presionas Enter, la consola debería mostrar 4.
|
||||||
|
|
||||||
|
Nota: Puede que veas un `undefined` en la consola. Puedes ignorar esta declaración de manera segura, solo significa que la función de JavaScript que has llamado no devolvió nada.
|
||||||
|
|
||||||
|
image::images/ChromeDev_Console_Ex.jpg[DeveloperToolsConsoleExample,500,500,style="lesson-image"]
|
@ -0,0 +1,19 @@
|
|||||||
|
== La Pestaña de Elementos
|
||||||
|
|
||||||
|
La pestaña de Elementos te permite examinar el código HTML y CSS utilizado para definir y estilizar el sitio web.
|
||||||
|
|
||||||
|
=== Fuente HTML
|
||||||
|
|
||||||
|
Si pasas el ratón sobre una línea, verás que una parte del sitio web se vuelve azul. Eso significa que
|
||||||
|
esta línea HTML en particular define esta sección del sitio web.
|
||||||
|
La pestaña de Elementos te permite realizar cambios en cada elemento HTML individual. Por ejemplo, si haces clic dentro de una etiqueta de párrafo (<p>...</p>), puedes editar el contenido del sitio web. Si has realizado cambios y luego haces clic en Enter,
|
||||||
|
Chrome actualizará el sitio web para mostrar tus ediciones. También puedes cambiar la etiqueta HTML utilizada, las clases y los identificadores (id) que una etiqueta tiene, y mucho más.
|
||||||
|
|
||||||
|
image::images/ChromeDev_Elements.jpg[DeveloperToolsElements,500,350,style="lesson-image"]
|
||||||
|
|
||||||
|
=== Fuente CSS
|
||||||
|
|
||||||
|
Puedes encontrar información sobre el CSS utilizado para estilizar el sitio web debajo de la fuente HTML. Al igual que con el HTML, también puedes editar el CSS y, por lo tanto, ajustar el estilo del sitio web.
|
||||||
|
Puedes editar valores específicos o desactivar el estilo individual.
|
||||||
|
|
||||||
|
image::images/ChromeDev_Elements_CSS.jpg[DeveloperToolsElementsCSS,500,350,style="lesson-image"]
|
@ -0,0 +1,17 @@
|
|||||||
|
== Herramientas de Desarrollo de Google Chrome
|
||||||
|
|
||||||
|
Para completar ciertas tareas, a veces es necesario examinar el código fuente de JavaScript o ejecutar un comando de JavaScript por tu cuenta.
|
||||||
|
Para hacer eso, Google Chrome tiene un conjunto de herramientas que te permiten hacer eso y mucho más.
|
||||||
|
Aunque estas herramientas no son exclusivas de Google Chrome, casi todos los navegadores modernos tienen un conjunto propio.
|
||||||
|
Nuestra introducción se centrará en las que se encuentran en Google Chrome.
|
||||||
|
Sin embargo, aún puedes utilizar el navegador que prefieras, como Firefox o Safari, aunque algunos pasos de este tutorial pueden ser diferentes para ti.
|
||||||
|
|
||||||
|
Ten en cuenta que este tutorial no está diseñado para enseñar todo sobre estas herramientas.
|
||||||
|
Se centrará únicamente en los conocimientos esenciales para completar tareas específicas.
|
||||||
|
Además, si ya estás familiarizado con estas herramientas, puedes saltar estas lecciones sin problema.
|
||||||
|
|
||||||
|
Para comenzar: *abre las herramientas de desarrollo*. Hay varias formas de abrirlas:
|
||||||
|
|
||||||
|
1. Haz clic derecho en cualquier parte de la ventana del navegador y selecciona la opción _"Inspeccionar"_.
|
||||||
|
2. Ve al menú del navegador (tres puntos en la esquina superior derecha), luego ve a _"Más herramientas"_ y selecciona la opción _"Herramientas de desarrollo"_.
|
||||||
|
3. Utiliza el atajo de teclado _Ctrl + Shift + I_.
|
@ -0,0 +1,15 @@
|
|||||||
|
== La pestaña de Fuentes
|
||||||
|
|
||||||
|
En la pestaña de Fuentes, puedes examinar el sistema de archivos y ver todos los archivos HTML, CSS y JavaScript utilizados para
|
||||||
|
crear el sitio web. Haz clic en un archivo para ver su contenido.
|
||||||
|
|
||||||
|
image::images/ChromeDev_Sources.jpg[DeveloperToolsSources,400,500,style="lesson-image"]
|
||||||
|
|
||||||
|
== La pestaña de Red
|
||||||
|
|
||||||
|
En la pestaña de Red, puedes ver las solicitudes HTTP y las respuestas que ha realizado el sitio web.
|
||||||
|
Simplemente haz clic en una si deseas obtener información más detallada sobre una solicitud específica.
|
||||||
|
La "Línea de tiempo" sobre los puntos azules representa cuándo se realizaron estas solicitudes y respuestas.
|
||||||
|
También puedes ver las solicitudes realizadas en un marco de tiempo específico simplemente haciendo clic y arrastrando en la línea de tiempo. La ventana inferior solo mostrará las solicitudes y respuestas realizadas en ese marco de tiempo.
|
||||||
|
|
||||||
|
image::images/ChromeDev_Network.jpg[DeveloperToolsNetwork,400,500,style="lesson-image"]
|
@ -164,6 +164,3 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
</html>
|
</html>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -31,5 +31,3 @@ The goal is to get familiar with the following forms of techniques:
|
|||||||
=== Assignments
|
=== Assignments
|
||||||
|
|
||||||
After the explanation of an item there will be several assignments.
|
After the explanation of an item there will be several assignments.
|
||||||
|
|
||||||
|
|
||||||
|
@ -28,6 +28,3 @@ You can find the secret in the following docker image, which you can start as:
|
|||||||
----
|
----
|
||||||
echo "U2FsdGVkX199jgh5oANElFdtCxIEvdEvciLi+v+5loE+VCuy6Ii0b+5byb5DXp32RPmT02Ek1pf55ctQN+DHbwCPiVRfFQamDmbHBUpD7as=" | openssl enc -aes-256-cbc -d -a -kfile ....
|
echo "U2FsdGVkX199jgh5oANElFdtCxIEvdEvciLi+v+5loE+VCuy6Ii0b+5byb5DXp32RPmT02Ek1pf55ctQN+DHbwCPiVRfFQamDmbHBUpD7as=" | openssl enc -aes-256-cbc -d -a -kfile ....
|
||||||
----
|
----
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -23,4 +23,3 @@ Basic authentication is sometimes used by web applications. This uses base64 enc
|
|||||||
The HTTP header will look like:
|
The HTTP header will look like:
|
||||||
|
|
||||||
Authorization: Basic bXl1c2VyOm15cGFzc3dvcmQ=
|
Authorization: Basic bXl1c2VyOm15cGFzc3dvcmQ=
|
||||||
|
|
||||||
|
@ -28,5 +28,3 @@ Here is a short description of what happens if you open your browser and go to a
|
|||||||
* At the end of this process both the browser and the webserver will use the exchanged symmetric key (in the asymmetric key exchange process) to encrypt and decrypt messages that are sent back and forth between the browser and the webserver.
|
* At the end of this process both the browser and the webserver will use the exchanged symmetric key (in the asymmetric key exchange process) to encrypt and decrypt messages that are sent back and forth between the browser and the webserver.
|
||||||
|
|
||||||
Symmetric keys are used because it can be used more easily with large sets of data and requires less processing power in doing so. However, the information on these pages is just for a basic understanding of cryptography. Look on the internet for more detailed information about these topics.
|
Symmetric keys are used because it can be used more easily with large sets of data and requires less processing power in doing so. However, the information on these pages is just for a basic understanding of cryptography. Look on the internet for more detailed information about these topics.
|
||||||
|
|
||||||
|
|
||||||
|
@ -36,5 +36,3 @@ Governments usually send official documents with a PDF that contains a certifica
|
|||||||
== Assignment
|
== Assignment
|
||||||
|
|
||||||
Here is a simple assignment. A private RSA key is sent to you. Determine the modulus of the RSA key as a hex string, and calculate a signature for that hex string using the key. The exercise requires some experience with OpenSSL. You can search on the Internet for useful commands and/or use the HINTS button to get some tips.
|
Here is a simple assignment. A private RSA key is sent to you. Determine the modulus of the RSA key as a hex string, and calculate a signature for that hex string using the key. The exercise requires some experience with OpenSSL. You can search on the Internet for useful commands and/or use the HINTS button to get some tips.
|
||||||
|
|
||||||
|
|
||||||
|
@ -20,8 +20,3 @@ with the server are performed with JavaScript. On the server side you only need
|
|||||||
if this header is not present deny the request.
|
if this header is not present deny the request.
|
||||||
Some frameworks offer this implementation by default however researcher Alex Infuhr found out that this can be bypassed
|
Some frameworks offer this implementation by default however researcher Alex Infuhr found out that this can be bypassed
|
||||||
as well. You can read about: https://insert-script.blogspot.com/2018/05/adobe-reader-pdf-client-side-request.html[Adobe Reader PDF - Client Side Request Injection]
|
as well. You can read about: https://insert-script.blogspot.com/2018/05/adobe-reader-pdf-client-side-request.html[Adobe Reader PDF - Client Side Request Injection]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -6,5 +6,3 @@ This is the most simple CSRF attack to perform. For example you receive an e-mai
|
|||||||
|
|
||||||
If the user is still logged in to the website of bank.com this simple GET request will transfer money from one account to another.
|
If the user is still logged in to the website of bank.com this simple GET request will transfer money from one account to another.
|
||||||
Of course in most cases the website might have multiple controls to approve the request.
|
Of course in most cases the website might have multiple controls to approve the request.
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
== Basic Get CSRF Exercise
|
== Basic Get CSRF Exercise
|
||||||
|
|
||||||
Trigger the form below from an external source while logged in. The response will include a 'flag' (a numeric value).
|
Trigger the form below from an external source while logged in. The response will include a 'flag' (a numeric value).
|
||||||
|
|
||||||
|
@ -6,4 +6,3 @@ finding somewhere that you want to execute the CSRF attack. The classic example
|
|||||||
|
|
||||||
But we're keeping it simple here. In this case, you just need to trigger a review submission on behalf of the currently
|
But we're keeping it simple here. In this case, you just need to trigger a review submission on behalf of the currently
|
||||||
logged in user.
|
logged in user.
|
||||||
|
|
||||||
|
@ -21,7 +21,3 @@ something. Forcing the victim to retrieve data doesn't benefit an attacker becau
|
|||||||
As such, CSRF attacks target state-changing requests.
|
As such, CSRF attacks target state-changing requests.
|
||||||
|
|
||||||
Let's continue with some exercises to address way to perform a CSRF request.
|
Let's continue with some exercises to address way to perform a CSRF request.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
= Hijack a Session
|
= Hijack a Session
|
||||||
|
|
||||||
In this lesson we are trying to predict the 'hijack_cookie' value. The 'hijack_cookie' is used to differentiate authenticated and anonymous users of WebGoat.
|
In this lesson we are trying to predict the 'hijack_cookie' value. The 'hijack_cookie' is used to differentiate authenticated and anonymous users of WebGoat.
|
||||||
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
== The Quiz
|
== The Quiz
|
||||||
|
|
||||||
What type of HTTP command did WebGoat use for this lesson. A POST or a GET.
|
What type of HTTP command did WebGoat use for this lesson. A POST or a GET.
|
||||||
|
|
||||||
|
@ -25,4 +25,3 @@ The client initiates a transaction as follows:
|
|||||||
** User-Agent: Mozilla/4.06 Accept: image/gif,image/jpeg, */*
|
** User-Agent: Mozilla/4.06 Accept: image/gif,image/jpeg, */*
|
||||||
|
|
||||||
* In a POST request, the user supplied data will follow the optional headers and is not part of the contained within the POST URL.
|
* In a POST request, the user supplied data will follow the optional headers and is not part of the contained within the POST URL.
|
||||||
|
|
||||||
|
@ -7,5 +7,3 @@ Otherwise, this will show you how to set up ZAP as a proxy on your local host.
|
|||||||
* First download and install https://www.zaproxy.org/download/[ZAP] for your operating system
|
* First download and install https://www.zaproxy.org/download/[ZAP] for your operating system
|
||||||
* Start ZAP
|
* Start ZAP
|
||||||
* Start the browser directly from ZAP
|
* Start the browser directly from ZAP
|
||||||
|
|
||||||
|
|
||||||
|
@ -26,5 +26,3 @@ image::images/zap_edit_and_send.png[Open/Resend with Request Editor,style="lesso
|
|||||||
++++
|
++++
|
||||||
|
|
||||||
image::images/zap_edit_and_response.png[Open/Resend response,style="lesson-image"]
|
image::images/zap_edit_and_response.png[Open/Resend response,style="lesson-image"]
|
||||||
|
|
||||||
|
|
||||||
|
@ -52,5 +52,3 @@ image::images/chrome-manual-proxy.png[Chrome Proxy Config,700,447,style="lesson-
|
|||||||
image::images/chrome-manual-proxy-win.png[Chrome Proxy, 394,346,style="lesson-image"]
|
image::images/chrome-manual-proxy-win.png[Chrome Proxy, 394,346,style="lesson-image"]
|
||||||
|
|
||||||
(Win config image above)
|
(Win config image above)
|
||||||
|
|
||||||
|
|
||||||
|
@ -56,4 +56,3 @@ Instead, use static keys that are securely managed and updated regularly.
|
|||||||
- **Audit and monitoring**: Regularly audit JWT usage, monitor for suspicious activity, and implement anomaly detection mechanisms.
|
- **Audit and monitoring**: Regularly audit JWT usage, monitor for suspicious activity, and implement anomaly detection mechanisms.
|
||||||
|
|
||||||
- **Security testing**: Regularly perform security testing, including penetration testing and code reviews, to identify and remediate potential vulnerabilities.
|
- **Security testing**: Regularly perform security testing, including penetration testing and code reviews, to identify and remediate potential vulnerabilities.
|
||||||
|
|
||||||
|
@ -3,4 +3,3 @@
|
|||||||
Below you see two accounts, one of Jerry and one of Tom.
|
Below you see two accounts, one of Jerry and one of Tom.
|
||||||
Jerry wants to remove Tom's account from Twitter, but his token can only delete his account.
|
Jerry wants to remove Tom's account from Twitter, but his token can only delete his account.
|
||||||
Can you try to help him and delete Toms account?
|
Can you try to help him and delete Toms account?
|
||||||
|
|
||||||
|
@ -9,4 +9,3 @@ eyJhbGciOiJIUzI1NiJ9.ew0KICAiYXV0aG9yaXRpZXMiIDogWyAiUk9MRV9BRE1JTiIsICJST0xFX1V
|
|||||||
----
|
----
|
||||||
|
|
||||||
Copy and paste the following token and decode the token, can you find the user inside the token?
|
Copy and paste the following token and decode the token, can you find the user inside the token?
|
||||||
|
|
||||||
|
@ -58,4 +58,3 @@ try {
|
|||||||
----
|
----
|
||||||
|
|
||||||
Can you spot the weakness?
|
Can you spot the weakness?
|
||||||
|
|
||||||
|
@ -16,4 +16,3 @@ information in the token to identify the user.
|
|||||||
|
|
||||||
The token contains claims to identify the user and all other information necessary for the server to fulfill the request.
|
The token contains claims to identify the user and all other information necessary for the server to fulfill the request.
|
||||||
Be aware not to store sensitive information in the token and always send it over a secure channel.
|
Be aware not to store sensitive information in the token and always send it over a secure channel.
|
||||||
|
|
||||||
|
@ -34,7 +34,3 @@ the validity and integrity of the token in a secure way, all of this in a statel
|
|||||||
and portable approach (portable in the way that client and server technologies can
|
and portable approach (portable in the way that client and server technologies can
|
||||||
be different including also the transport channel even if HTTP is the most often used)
|
be different including also the transport channel even if HTTP is the most often used)
|
||||||
-------------------------------------------------------
|
-------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -85,4 +85,3 @@ application you are better of using plain old cookies. See for more information:
|
|||||||
- http://cryto.net/~joepie91/blog/2016/06/13/stop-using-jwt-for-sessions/[stop-using-jwt-for-sessions, window="_blank"]
|
- http://cryto.net/~joepie91/blog/2016/06/13/stop-using-jwt-for-sessions/[stop-using-jwt-for-sessions, window="_blank"]
|
||||||
- http://cryto.net/~joepie91/blog/2016/06/19/stop-using-jwt-for-sessions-part-2-why-your-solution-doesnt-work/[stop-using-jwt-for-sessions-part-2-why-your-solution-doesnt-work, window="_blank"]
|
- http://cryto.net/~joepie91/blog/2016/06/19/stop-using-jwt-for-sessions-part-2-why-your-solution-doesnt-work/[stop-using-jwt-for-sessions-part-2-why-your-solution-doesnt-work, window="_blank"]
|
||||||
- http://cryto.net/~joepie91/blog/attachments/jwt-flowchart.png[flowchart, window="_blank"]
|
- http://cryto.net/~joepie91/blog/attachments/jwt-flowchart.png[flowchart, window="_blank"]
|
||||||
|
|
||||||
|
@ -9,5 +9,3 @@ found in a private bug bounty program on Bugcrowd, you can read the full write u
|
|||||||
|
|
||||||
From a breach of last year the following logfile is available link:images/logs.txt[here]
|
From a breach of last year the following logfile is available link:images/logs.txt[here]
|
||||||
Can you find a way to order the books but let *Tom* pay for them?
|
Can you find a way to order the books but let *Tom* pay for them?
|
||||||
|
|
||||||
|
|
||||||
|
@ -14,7 +14,3 @@ to be aware of before validating the token.
|
|||||||
== Assignment
|
== Assignment
|
||||||
|
|
||||||
Try to change the token you receive and become an admin user by changing the token and once you are admin reset the votes
|
Try to change the token you receive and become an admin user by changing the token and once you are admin reset the votes
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -86,6 +86,3 @@ Now we can replace the token in the cookie and perform the reset again. One thin
|
|||||||
For more information take a look at the following video:
|
For more information take a look at the following video:
|
||||||
|
|
||||||
video::wt3UixCiPfo[youtube, height=480, width=100%]
|
video::wt3UixCiPfo[youtube, height=480, width=100%]
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -13,5 +13,3 @@ The token is base64 encoded and consists of three parts:
|
|||||||
|
|
||||||
Both header and claims consist are represented by a JSON object. The header describes the cryptographic operations applied to the JWT and optionally, additional properties of the JWT.
|
Both header and claims consist are represented by a JSON object. The header describes the cryptographic operations applied to the JWT and optionally, additional properties of the JWT.
|
||||||
The claims represent a JSON object whose members are the claims conveyed by the JWT.
|
The claims represent a JSON object whose members are the claims conveyed by the JWT.
|
||||||
|
|
||||||
|
|
||||||
|
@ -7,4 +7,3 @@ dictionary attack is not feasible. Once you have a token you can start an offlin
|
|||||||
=== Assignment
|
=== Assignment
|
||||||
|
|
||||||
Given we have the following token try to find out secret key and submit a new key with the username changed to WebGoat.
|
Given we have the following token try to find out secret key and submit a new key with the username changed to WebGoat.
|
||||||
|
|
||||||
|
@ -31,6 +31,3 @@ function updateTotal() {
|
|||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -6,4 +6,3 @@ function follow(user) {
|
|||||||
$("#toast").append(result);
|
$("#toast").append(result);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -84,4 +84,3 @@ function vote(title) {
|
|||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,4 +6,3 @@ This lesson describes the steps needed to add a new lesson to WebGoat. In genera
|
|||||||
- Add one or more assignments within the lesson
|
- Add one or more assignments within the lesson
|
||||||
|
|
||||||
Let's see how to create a new lesson.
|
Let's see how to create a new lesson.
|
||||||
|
|
||||||
|
@ -8,4 +8,3 @@ lesson-template.sample-attack.failure-1=Sample failure message
|
|||||||
lesson-template.sample-attack.failure-2=Sample failure message 2
|
lesson-template.sample-attack.failure-2=Sample failure message 2
|
||||||
|
|
||||||
lesson-template.sample-attack.success=Sample success message
|
lesson-template.sample-attack.success=Sample success message
|
||||||
|
|
||||||
|
@ -1,2 +1 @@
|
|||||||
logging.title=Logging Security
|
logging.title=Logging Security
|
||||||
|
|
||||||
|
@ -17,4 +17,3 @@ that password. Note: it is not possible to use OWASP ZAP for this lesson, also b
|
|||||||
tools like `curl` and the like will be more successful for this attack.
|
tools like `curl` and the like will be more successful for this attack.
|
||||||
|
|
||||||
Tom always resets his password immediately after receiving the email with the link.
|
Tom always resets his password immediately after receiving the email with the link.
|
||||||
|
|
||||||
|
@ -18,6 +18,3 @@ resets, a good resource for security questions is: http://goodsecurityquestions.
|
|||||||
Users can retrieve their password if they can answer the secret question properly. There is no lock-out mechanism on
|
Users can retrieve their password if they can answer the secret question properly. There is no lock-out mechanism on
|
||||||
this 'Forgot Password' page. Your username is 'webgoat' and your favorite color is 'red'. The goal is to retrieve the
|
this 'Forgot Password' page. Your username is 'webgoat' and your favorite color is 'red'. The goal is to retrieve the
|
||||||
password of another user. Users you could try are: "tom", "admin" and "larry".
|
password of another user. Users you could try are: "tom", "admin" and "larry".
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -3,4 +3,3 @@
|
|||||||
Let's first do a simple assignment to make sure you are able to read e-mails with WebWolf, first start WebWolf (see webWolfLink:here[])
|
Let's first do a simple assignment to make sure you are able to read e-mails with WebWolf, first start WebWolf (see webWolfLink:here[])
|
||||||
In the reset page below send an e-mail to `username@webgoat.org` (part behind the @ is not important)
|
In the reset page below send an e-mail to `username@webgoat.org` (part behind the @ is not important)
|
||||||
Open WebWolf and read the e-mail and login with your username and the password provided in the e-mail.
|
Open WebWolf and read the e-mail and login with your username and the password provided in the e-mail.
|
||||||
|
|
||||||
|
@ -19,5 +19,3 @@ it again to `../`.
|
|||||||
Also, note that avoiding applications filtering those encodings double encoding might work as well. Double encoding
|
Also, note that avoiding applications filtering those encodings double encoding might work as well. Double encoding
|
||||||
might be necessary when you have a system A which calls system B. System A will only decode once and
|
might be necessary when you have a system A which calls system B. System A will only decode once and
|
||||||
call B with the still encoded URL.
|
call B with the still encoded URL.
|
||||||
|
|
||||||
|
|
||||||
|
@ -2,5 +2,3 @@
|
|||||||
|
|
||||||
Path traversals are not limited to file uploads; when retrieving files, it can be the case that a path traversal
|
Path traversals are not limited to file uploads; when retrieving files, it can be the case that a path traversal
|
||||||
is possible to retrieve other files from the system. In this assignment, try to find a file called `path-traversal-secret.jpg`
|
is possible to retrieve other files from the system. In this assignment, try to find a file called `path-traversal-secret.jpg`
|
||||||
|
|
||||||
|
|
||||||
|
@ -67,4 +67,3 @@ if you replace `1.jpg` with `../../secret.txt`, it will block the request. With
|
|||||||
will not be there.
|
will not be there.
|
||||||
|
|
||||||
In the lesson about "File uploads" more examples of vulnerabilities are shown.
|
In the lesson about "File uploads" more examples of vulnerabilities are shown.
|
||||||
|
|
||||||
|
@ -11,5 +11,3 @@ To make the assignment a bit easier below you will find the location of the prof
|
|||||||
|`webGoatTempDir:temppath[]PathTraversal/username:user[]/username:user[].jpg`
|
|`webGoatTempDir:temppath[]PathTraversal/username:user[]/username:user[].jpg`
|
||||||
|
|
||||||
|===
|
|===
|
||||||
|
|
||||||
|
|
||||||
|
@ -55,4 +55,3 @@ path-traversal-zip-slip.hint4=Check the http request to find out which image nam
|
|||||||
|
|
||||||
path-traversal-zip-slip.no-zip=Please upload a zip file
|
path-traversal-zip-slip.no-zip=Please upload a zip file
|
||||||
path-traversal-zip-slip.extracted=Zip file extracted successfully failed to copy the image. Please get in touch with our helpdesk.
|
path-traversal-zip-slip.extracted=Zip file extracted successfully failed to copy the image. Please get in touch with our helpdesk.
|
||||||
|
|
||||||
|
@ -88,5 +88,3 @@ for the deserialization: got to the link: http://www.pwntester.com/blog/2013/12
|
|||||||
</handler>
|
</handler>
|
||||||
</dynamic-proxy>
|
</dynamic-proxy>
|
||||||
</sorted-set>
|
</sorted-set>
|
||||||
|
|
||||||
|
|
||||||
|
@ -28,4 +28,3 @@ var obs = new MutationObserver(function(mutations) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
obs.observe(target, { characterData: false, attributes: false, childList: true, subtree: false });
|
obs.observe(target, { characterData: false, attributes: false, childList: true, subtree: false });
|
||||||
|
|
||||||
|
@ -11,4 +11,3 @@ INSERT INTO grant_rights VALUES ('89762','Tobi', 'Barnett', 'Development', 7
|
|||||||
INSERT INTO grant_rights VALUES ('96134','Bob', 'Franco', 'Marketing', 83700);
|
INSERT INTO grant_rights VALUES ('96134','Bob', 'Franco', 'Marketing', 83700);
|
||||||
INSERT INTO grant_rights VALUES ('34477','Abraham ', 'Holman', 'Development', 50000);
|
INSERT INTO grant_rights VALUES ('34477','Abraham ', 'Holman', 'Development', 50000);
|
||||||
INSERT INTO grant_rights VALUES ('37648','John', 'Smith', 'Marketing', 64350);
|
INSERT INTO grant_rights VALUES ('37648','John', 'Smith', 'Marketing', 64350);
|
||||||
|
|
||||||
|
@ -10,4 +10,3 @@
|
|||||||
* SQL injection
|
* SQL injection
|
||||||
|
|
||||||
=== Often the database is considered trusted
|
=== Often the database is considered trusted
|
||||||
|
|
||||||
|
@ -10,4 +10,3 @@ Let's repeat one of the previous assignments, the developer fixed the possible S
|
|||||||
spot the weakness in this approach?
|
spot the weakness in this approach?
|
||||||
|
|
||||||
Read about the lesson goal link:start.mvc#lesson/SqlInjectionAdvanced.lesson/2[here].
|
Read about the lesson goal link:start.mvc#lesson/SqlInjectionAdvanced.lesson/2[here].
|
||||||
|
|
||||||
|
@ -4,5 +4,3 @@ So the last attempt to validate if the query did not contain any spaces failed,
|
|||||||
into the direction of only performing input validation, can you find out where it went wrong this time?
|
into the direction of only performing input validation, can you find out where it went wrong this time?
|
||||||
|
|
||||||
Read about the lesson goal link:start.mvc#lesson/SqlInjectionAdvanced.lesson/2[here].
|
Read about the lesson goal link:start.mvc#lesson/SqlInjectionAdvanced.lesson/2[here].
|
||||||
|
|
||||||
|
|
||||||
|
@ -56,4 +56,3 @@ To achieve this kind of SQL injection you could use:
|
|||||||
----
|
----
|
||||||
article = 4; sleep(10) --
|
article = 4; sleep(10) --
|
||||||
----
|
----
|
||||||
|
|
||||||
|
@ -48,4 +48,3 @@ statement.setString(2, "webgoat");
|
|||||||
statement.setString(3, "webgoat@owasp.org");
|
statement.setString(3, "webgoat@owasp.org");
|
||||||
statement.executeUpdate();
|
statement.executeUpdate();
|
||||||
----
|
----
|
||||||
|
|
||||||
|
@ -20,6 +20,3 @@ If an attacker succeeds in "injecting" DML statements into a SQL database, he ca
|
|||||||
=== It is your turn!
|
=== It is your turn!
|
||||||
Try to change the department of Tobi Barnett to 'Sales'.
|
Try to change the department of Tobi Barnett to 'Sales'.
|
||||||
Note that you have been granted full administrator privileges in this assignment and can access all data without authentication.
|
Note that you have been granted full administrator privileges in this assignment and can access all data without authentication.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -21,4 +21,3 @@ If an attacker successfully "injects" DDL type SQL commands into a database, he
|
|||||||
** This statement creates the employees example table given on page 2.
|
** This statement creates the employees example table given on page 2.
|
||||||
|
|
||||||
Now try to modify the schema by adding the column "phone" (varchar(20)) to the table "employees". :
|
Now try to modify the schema by adding the column "phone" (varchar(20)) to the table "employees". :
|
||||||
|
|
||||||
|
@ -11,4 +11,3 @@ If an attacker successfully "injects" DCL type SQL commands into a database, he
|
|||||||
|
|
||||||
|
|
||||||
Try to grant rights to the table `grant_rights` to user `unauthorized_user`:
|
Try to grant rights to the table `grant_rights` to user `unauthorized_user`:
|
||||||
|
|
||||||
|
@ -11,4 +11,3 @@ This lesson describes what Structured Query Language (SQL) is and how it can be
|
|||||||
** String SQL injection
|
** String SQL injection
|
||||||
** Numeric SQL injection
|
** Numeric SQL injection
|
||||||
** How SQL injection violates the CIA triad
|
** How SQL injection violates the CIA triad
|
||||||
|
|
||||||
|
@ -8,4 +8,3 @@ To prevent SSRF vulnerabilities in web applications, it is recommended to adhere
|
|||||||
|
|
||||||
== References
|
== References
|
||||||
* https://cheatsheetseries.owasp.org/cheatsheets/Server_Side_Request_Forgery_Prevention_Cheat_Sheet.html
|
* https://cheatsheetseries.owasp.org/cheatsheets/Server_Side_Request_Forgery_Prevention_Cheat_Sheet.html
|
||||||
|
|
||||||
|
@ -10,4 +10,3 @@
|
|||||||
** Some repositories allow you to remove published artifacts
|
** Some repositories allow you to remove published artifacts
|
||||||
* Many different packaging systems; even for the same language
|
* Many different packaging systems; even for the same language
|
||||||
* Different coordinates systems and level of granularity
|
* Different coordinates systems and level of granularity
|
||||||
|
|
||||||
|
@ -8,4 +8,3 @@ WebGoat uses almost *200 Java and JavaScript* libraries. Like most Java applica
|
|||||||
When this lesson was created WebGoat contained more than a dozen high security risks within it's components. Most of these were not deliberate choices. How are developers supposed to track this information across the hundreds of components?
|
When this lesson was created WebGoat contained more than a dozen high security risks within it's components. Most of these were not deliberate choices. How are developers supposed to track this information across the hundreds of components?
|
||||||
|
|
||||||
image::images/WebGoat-Vulns.png[caption="Figure: ", title="WebGoat Security Issues", alt="Security Issues", width="800", height="400", style="lesson-image"]
|
image::images/WebGoat-Vulns.png[caption="Figure: ", title="WebGoat Security Issues", alt="Security Issues", width="800", height="400", style="lesson-image"]
|
||||||
|
|
||||||
|
@ -3,4 +3,3 @@ Below is an example of using the same WebGoat source code, but different version
|
|||||||
|
|
||||||
=== jquery-ui:1.10.4
|
=== jquery-ui:1.10.4
|
||||||
This example allows the user to specify the content of the "closeText" for the jquery-ui dialog. This is an unlikely development scenario, however the jquery-ui dialog (TBD - show exploit link) does not defend against XSS in the button text of the close dialog.
|
This example allows the user to specify the content of the "closeText" for the jquery-ui dialog. This is an unlikely development scenario, however the jquery-ui dialog (TBD - show exploit link) does not defend against XSS in the button text of the close dialog.
|
||||||
|
|
||||||
|
@ -56,5 +56,3 @@ In the case of WebGoat, the plugin is activated when the following is run (owasp
|
|||||||
Below is a snippet of a report, which can be found in e.g. webgoat-container/target/dependency-check-report.html:
|
Below is a snippet of a report, which can be found in e.g. webgoat-container/target/dependency-check-report.html:
|
||||||
|
|
||||||
image::images/OWASP-Dep-Check.png[caption="Figure: ", title="WebGoat Bill of Materials", alt="BoM", width="988", height="515", style="lesson-image"]
|
image::images/OWASP-Dep-Check.png[caption="Figure: ", title="WebGoat Bill of Materials", alt="BoM", width="988", height="515", style="lesson-image"]
|
||||||
|
|
||||||
|
|
||||||
|
@ -20,4 +20,3 @@
|
|||||||
|
|
||||||
* It is not reasonable to expect a developer to continually research each component.
|
* It is not reasonable to expect a developer to continually research each component.
|
||||||
* Developers are not security experts; they already have a day job.
|
* Developers are not security experts; they already have a day job.
|
||||||
|
|
||||||
|
@ -12,4 +12,3 @@ Ref: https://diniscruz.blogspot.com/2013/12/xstream-remote-code-execution-exploi
|
|||||||
https://github.com/pwntester/XStreamPOC[pwntester/XStreamPOC]
|
https://github.com/pwntester/XStreamPOC[pwntester/XStreamPOC]
|
||||||
|
|
||||||
You may want to read the article(s) before trying this lesson. Let's see if you can figure out how to exploit this in WebGoat.
|
You may want to read the article(s) before trying this lesson. Let's see if you can figure out how to exploit this in WebGoat.
|
||||||
|
|
||||||
|
@ -12,5 +12,3 @@
|
|||||||
** Use http://lmgtfy.com/?q=OSS+bill+of+materials[automated tooling]
|
** Use http://lmgtfy.com/?q=OSS+bill+of+materials[automated tooling]
|
||||||
* Baseline open source consumption in your organization.
|
* Baseline open source consumption in your organization.
|
||||||
* Develop an open source component risk management strategy to mitigate current risk and reduce future risk.
|
* Develop an open source component risk management strategy to mitigate current risk and reduce future risk.
|
||||||
|
|
||||||
|
|
||||||
|
@ -13,4 +13,3 @@ image::images/OpenSourceGrowing2023.png[caption="Figure: ", title="The continued
|
|||||||
* Gain awareness that the open source consumed is as important as your own custom code.
|
* Gain awareness that the open source consumed is as important as your own custom code.
|
||||||
* Gain awareness of the management, or lack of management, in our open source component consumption.
|
* Gain awareness of the management, or lack of management, in our open source component consumption.
|
||||||
* Understand the importance of a Bill of Materials in determining open source component risk
|
* Understand the importance of a Bill of Materials in determining open source component risk
|
||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user