Si estás acá, deberías salir ahora mismo !

Web request

_ /bin/bash/


cURL

curl -h | cURL help menu

curl lab154.net | Solicitud GET básica

curl -s -O lab154.net/index.html | Download file

curl -k https://lab154.net | Omitir la validación del certificado HTTPS (SSL)

curl lab154.net -v | Imprimir detalles completos de solicitud/respuesta HTTP

curl -I https://www.lab154.net | Enviar solicitud HEAD (solo imprime encabezados de respuesta)

curl -i https://www.lab154.net | Imprimir HEAD de respuesta y BODY de respuesta

curl https://www.lab154.net -A 'Mozilla/5.0' | Establece User-Agent en el encabezado

curl -u user:password http://lab154.net:80/ | Establecer credenciales de autorización básicas HTTP

curl http://user:password@lab154.net:80/ | Pase las credenciales de autorización básicas de HTTP en la URL

curl -H 'Authorization: Basic YWRtaW46YWRtaW4=' http://lab154.net:80/ | Establecer encabezado de solicitud

curl 'http://lab154.net:80/search.php?search=le' | Pasar parámetros GET

curl -X POST -d 'username=admin&password=admin' http://lab154.net:80/ | Enviar solicitud POST con datos POST

curl -b 'PHPSESSID=c1nsa6op7vtk7kdis7bcnbadf1' http://[SERVER_IP]:[PORT]/ | Establecer cookies de solicitud

curl -X POST -d '{"search":"london"}' -H 'Content-Type: application/json' http://[SERVER_IP]:[PORT]/search.php | Enviar solicitud POST con datos JSON


API

curl http://[SERVER_IP]:[PORT]/api.php/city/london | Leer entrada

curl -s http://[SERVER_IP]:[PORT]/api.php/city/ \| jq | Leer todas las entradas

curl -X POST http://[SERVER_IP]:[PORT]/api.php/city/ -d '{"city_name":"HTB_City", "country_name":"HTB"}' -H 'Content-Type: application/json' | Crear (añadir) entrada

curl -X PUT http://[SERVER_IP]:[PORT]/api.php/city/london -d '{"city_name":"New_HTB_City", "country_name":"HTB"}' -H 'Content-Type: application/json' | Actualizar (modificar) entrada

curl -X DELETE http://[SERVER_IP]:[PORT]/api.php/city/New_HTB_City | Eliminar la entrada


BROWSER DEVTOOL

CTRL+SHIFT+I or F12 | Mostrar herramientas de desarrollo

CTRL+SHIFT+E | Mostrar pestaña Red

CTRL+SHIFT+K | Mostrar pestaña Consola