I’m doing the infosec course and the current version is 4.2.0 (as of 12/11/2020) and it seems to be breaking my courses. because i DEFINITELY installed it correctly (typing “npm install helmet@3.21.1” into console) but it still doesn’t work. quite frankly i’m at my wits end but i REALLY need a cybersecurity cert.
you will need to provide the challenge link and the link to your code to get help
ah right, my apologies!
My code: https://repl.it/@Ejwere/boilerplate-infosec-4#package.json
the challenge: https://www.freecodecamp.org/learn/information-security/information-security-with-helmetjs/install-and-require-helmet
i actually got through it somehow, and i only got stuck on the one with the ieNoOpen challenge. yes, i clicked run.
Welcome, Ejwere.
This is a slight bug:
The solution is:
npm install --save-exact helmet@3.21.3
Otherwise, manually change the version in the package.json
Hope this helps
still no dice, copied and pasted into the console and clicked run.
WAIT, HOLD ON.
var helmet = require('helmet');
VAR
edit: nevermind. i put “const” but still no dice.
I don’t see you using the middleware in your code on repl?
Also, I think the test needs the specific middleware mounted in the code, even if just using app.use(helmet())
includes the middleware by default.
yeah uh, i have the big stupid. the biggest stupid. that worked. might want to update the challenges to reflect this. thanks all.