Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--pending-deprecation DeprecationWarning: url.parse() #181

Open
CodeIter opened this issue Jan 14, 2024 · 0 comments
Open

--pending-deprecation DeprecationWarning: url.parse() #181

CodeIter opened this issue Jan 14, 2024 · 0 comments

Comments

@CodeIter
Copy link

Hi, I found a pending deprecation hier:

this._key = options.sessionKey || ('oauth2:' + url.parse(options.authorizationURL).hostname);

I used This NODE_OPTIONS:

NODE_OPTIONS="--pending-deprecation --throw-deprecation --trace-deprecation"

Output:

+ node server.mjs
node:internal/process/warning:162
        throw warning;
        ^

DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
    at Object.urlParse [as parse] (node:url:154:13)
    at Strategy.OAuth2Strategy (.../myproject/node_modules/.pnpm/[email protected]/node_modules/passport-oauth2/lib/strategy.js:103:54)
    at new Strategy (.../myproject/node_modules/.pnpm/[email protected]/node_modules/passport-facebook/lib/strategy.js:56:18)
    at file://.../myproject/src/auth/strategy/facebook.mjs:7:33
    at ModuleJob.run (node:internal/modules/esm/module_job:192:25) {
  code: 'DEP0169'
}

Node.js v20.2.0

Fail : Code status 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant