question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to Use Passport Strategies & Create New Middleware

See original GitHub issue

https://learn.freecodecamp.org/information-security-and-quality-assurance/advanced-node-and-express/create-new-middleware/

  1. code does not work for mongodb package 3.X needs 2.X or will get db.collection is not a function. hence this dependency needs to be more strictly enforced error…

  2. test no.2 does not pass even though i am pretty certain code redirects to ‘/’

Challenge Name

https://beta.freecodecamp.org/en/challenges/advanced-node-and-express/create-new-middleware https://beta.freecodecamp.org/en/challenges/advanced-node-and-express/how-to-use-passport-strategies

Issue Description

Browser Information

  • Browser Name, Version:
  • Operating System:
  • Mobile, Desktop, or Tablet:

Your Code

https://tan-bow.glitch.me/




Screenshot

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:3
  • Comments:19 (10 by maintainers)

github_iconTop GitHub Comments

8reactions
ghostcommented, Sep 15, 2018

Still broken for me. I just put “Home Page” in the index.pug description. Either add that to the challenge or just fix the glitch/github clone?

screen shot 2018-09-14 at 7 09 43 pm
8reactions
Em-Antcommented, Jun 3, 2018

Create new middleware works, allowing the new domain

istantanea_2018-06-03_20-28-12

@clickingmouse be aware that the redirection is tested searching for the text ‘Home page’ so you have to put it somewhere in the ‘/’ page. Probably the test or the description could be improved.

check this: https://glitch.com/edit/#!/oasis-thief

Read more comments on GitHub >

github_iconTop Results From Across the Web

Documentation: Middleware
Passport is used as middleware within a web application to authenticate requests. Middleware was popularized in Node.js by Express and its even more...
Read more >
07 - How to Use Passport Strategies - freeCodeCamp - YouTube
To link login forms to our strategies, we can mount a middleware called passport.authenticate() to our POST route.
Read more >
Node JS with Passport Authentication simplified
Step 1: Import the libraries into your file · Step 2: Initialize Middleware · Step 3: Use Passport to define the Authentication Strategy...
Read more >
Authenticate Users With Node ExpressJS and Passport.js
In this tutorial we'll: Create a login form for a Node application using Passport; Use the session authentication strategy with Passport; Connect Passport...
Read more >
The Ultimate Guide to Passport JS
In this post, I am going to walk through why the Passport-JWT authentication strategy is a simple, secure solution for small teams and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found