Installatiedocumentatie: OWASP Juice Shop
Omgeving: Ubuntu Server Technologie: Node.js + Express + Angular
0lecturas
Omgeving: Ubuntu Server Technologie: Node.js + Express + Angular
1. Installatie van Node.js
Sección titulada «1. Instalación de Node.js»OWASP Juice Shop vereist een moderne versie van Node.js (v18 of hoger). We zullen versie 22 installeren.
sudo apt updatecurl -fsSL [https://deb.nodesource.com/setup_22.x](https://deb.nodesource.com/setup_22.x) | sudo -E bash -sudo apt install -y nodejs
# Verificar versiónnode -v# Debe ser v20+2. Implementatie van de code
Sección titulada «2. Despliegue del Código»cd /var/www/htmlsudo git clone [https://github.com/juice-shop/juice-shop.git](https://github.com/juice-shop/juice-shop.git)cd juice-shop3. Installatie en Compilatie (Build)
Sección titulada «3. Instalación y Compilación (Build)»Deze stap is kritiek. Als het mislukt, start de server niet op (Fout CONNECTION_REFUSED). We moeten npm install uitvoeren met schrijfrechten om de map build te genereren.
# 1. Asignar propiedad a tu usuario actual para poder compilarsudo chown -R $USER:$USER /var/www/html/juice-shop
# 2. Instalar dependencias y compilar la aplicaciónnpm install
# 3. Devolver la propiedad al usuario web (seguridad)sudo chown -R www-data:www-data /var/www/html/juice-shop4. Servicebeheer (Starten en Stoppen)
Sección titulada «4. Gestión del Servicio (Iniciar y Parar)»OWASP Juice Shop is geen systeemdienst (zoals Apache), het is een Node.js-proces dat we actief moeten houden in de terminal.
OWASP Juice Shop starten
Sección titulada «Iniciar OWASP Juice Shop»cd /var/www/html/juice-shopsudo -u www-data npm startWe wachten tot we de melding zien: info: Server listening on port 3000
Webtoegang: http://TU_IP:3000
Stop OWASP Juice Shop
Sección titulada «Detener OWASP Juice Shop»In de terminal waar het wordt uitgevoerd, drukken we:
Ctrl + C

