├── final-result ├── .editorconfig ├── .gitignore ├── config │ ├── default.json │ └── production.json ├── package-lock.json ├── package.json ├── sql │ └── init.sql ├── src │ ├── @types │ │ └── express.d.ts │ ├── database.ts │ ├── errors │ │ ├── application.error.ts │ │ ├── database.error.ts │ │ └── forbidden.error.ts │ ├── index.ts │ ├── middlewares │ │ ├── basic-authentication.middleware.ts │ │ ├── error-handdles.middleware.ts │ │ └── jwt-authentication.middleware.ts │ ├── models │ │ ├── http-response.model.ts │ │ └── user.model.ts │ ├── repositories │ │ └── user.repository.ts │ └── routes │ │ ├── authentication.route.ts │ │ └── user.route.ts └── tsconfig.json ├── live-01 ├── .gitignore ├── package-lock.json ├── package.json ├── src │ ├── index.ts │ └── routes │ │ ├── status.route.ts │ │ └── users.route.ts └── tsconfig.json ├── live-02 ├── .gitignore ├── package-lock.json ├── package.json ├── sql │ └── init.sql ├── src │ ├── db.ts │ ├── index.ts │ ├── middlewares │ │ └── error-handler.middleware.ts │ ├── models │ │ ├── errors │ │ │ └── database.error.model.ts │ │ └── user.model.ts │ ├── repositories │ │ └── user.repository.ts │ └── routes │ │ ├── status.route.ts │ │ └── users.route.ts └── tsconfig.json ├── live-03 ├── .gitignore ├── package-lock.json ├── package.json ├── sql │ └── init.sql ├── src │ ├── @types │ │ └── express.d.ts │ ├── db.ts │ ├── index.ts │ ├── middlewares │ │ ├── basic-authentication.middleware.ts │ │ └── error-handler.middleware.ts │ ├── models │ │ ├── errors │ │ │ ├── database.error.model.ts │ │ │ └── forbidden.error.model.ts │ │ └── user.model.ts │ ├── repositories │ │ └── user.repository.ts │ └── routes │ │ ├── authorization.route.ts │ │ ├── status.route.ts │ │ └── users.route.ts └── tsconfig.json └── readme.md /final-result/.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig is awesome: https://EditorConfig.org 2 | 3 | # top-most EditorConfig file 4 | root = true 5 | 6 | [*] 7 | indent_style = space 8 | indent_size = 4 9 | end_of_line = crlf 10 | charset = utf-8 11 | trim_trailing_whitespace = false 12 | insert_final_newline = false 13 | -------------------------------------------------------------------------------- /final-result/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist -------------------------------------------------------------------------------- /final-result/config/default.json: -------------------------------------------------------------------------------- 1 | { 2 | "database": { 3 | "uri": "your_database_uri" 4 | }, 5 | "authentication": { 6 | "cryptKey": "my_salt" 7 | } 8 | } -------------------------------------------------------------------------------- /final-result/config/production.json: -------------------------------------------------------------------------------- 1 | { 2 | "database": { 3 | "uri": "DATABASE_URI" 4 | }, 5 | "authentication": { 6 | "cryptKey": "AUTHENTICATION_CRYPT_KEY" 7 | } 8 | } -------------------------------------------------------------------------------- /final-result/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "dio-node-user-authentication-api", 3 | "version": "1.0.0", 4 | "description": "Microserviço de autenticação de usuários feito em nodejs com o intuito de contribuir com o conhecimento desta comunidade DEV incrível!", 5 | "scripts": { 6 | "build": "tsc -p .", 7 | "dev": "ts-node-dev -r tsconfig-paths/register --respawn --transpile-only --ignore-watch node_modules --no-notify src/index.ts", 8 | "start": "node ./dist/index.js" 9 | }, 10 | "author": "Renan Johannsen de Paula", 11 | "license": "ISC", 12 | "devDependencies": { 13 | "@types/config": "^0.0.39", 14 | "@types/express": "^4.17.13", 15 | "@types/jsonwebtoken": "^8.5.5", 16 | "@types/node": "^16.7.2", 17 | "@types/pg": "^8.6.1", 18 | "ts-node-dev": "^1.1.8", 19 | "tsconfig-paths": "^3.11.0", 20 | "typescript": "^4.4.0" 21 | }, 22 | "dependencies": { 23 | "config": "^3.3.6", 24 | "express": "^4.17.1", 25 | "http-status-codes": "^2.1.4", 26 | "jsonwebtoken": "^8.5.1", 27 | "pg": "^8.7.1" 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /final-result/sql/init.sql: -------------------------------------------------------------------------------- 1 | 2 | CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; 3 | CREATE EXTENSION IF NOT EXISTS "pgcrypto"; 4 | 5 | CREATE TABLE IF NOT EXISTS application_user ( 6 | uuid uuid DEFAULT uuid_generate_v4(), 7 | username VARCHAR NOT NULL, 8 | password VARCHAR NOT NULL, 9 | PRIMARY KEY (uuid) 10 | ); 11 | 12 | INSERT INTO application_user (username, password) VALUES ('admin', crypt('admin', 'my_salt')); 13 | 14 | -------------------------------------------------------------------------------- /final-result/src/@types/express.d.ts: -------------------------------------------------------------------------------- 1 | import { User } from '../models/user.model'; 2 | 3 | declare module 'express-serve-static-core' { 4 | 5 | interface Request { 6 | user?: User | null 7 | } 8 | 9 | } 10 | -------------------------------------------------------------------------------- /final-result/src/database.ts: -------------------------------------------------------------------------------- 1 | 2 | import config from 'config'; 3 | import { Pool } from 'pg'; 4 | 5 | const connectionString = config.get('database.uri'); 6 | const db = new Pool({ connectionString }); 7 | 8 | export default db; 9 | -------------------------------------------------------------------------------- /final-result/src/errors/application.error.ts: -------------------------------------------------------------------------------- 1 | 2 | export type ApplicationErrorConfig = { 3 | log?: string; 4 | messagekey?: string; 5 | data?: T; 6 | }; 7 | 8 | export const DEFAULT_APPLICATION_ERROR_CONFIG: ApplicationErrorConfig = { 9 | log: 'Unexpected error', 10 | messagekey: 'unexpected-error' 11 | }; 12 | 13 | export class ApplicationError extends Error { 14 | 15 | constructor( 16 | public config: ApplicationErrorConfig 17 | ) { 18 | super(config.log || DEFAULT_APPLICATION_ERROR_CONFIG.log); 19 | if (!config.messagekey) { 20 | config.messagekey = DEFAULT_APPLICATION_ERROR_CONFIG.messagekey; 21 | } 22 | } 23 | 24 | } 25 | -------------------------------------------------------------------------------- /final-result/src/errors/database.error.ts: -------------------------------------------------------------------------------- 1 | import { ApplicationError } from './application.error'; 2 | 3 | export class DatabaseError extends ApplicationError {} 4 | -------------------------------------------------------------------------------- /final-result/src/errors/forbidden.error.ts: -------------------------------------------------------------------------------- 1 | 2 | import { ApplicationError } from './application.error'; 3 | 4 | export class ForbiddenError extends ApplicationError { }; 5 | 6 | -------------------------------------------------------------------------------- /final-result/src/index.ts: -------------------------------------------------------------------------------- 1 | import express, { Request, Response } from 'express'; 2 | import db from './database'; 3 | import errorHanddlerMiddleware from './middlewares/error-handdles.middleware'; 4 | import jwtAuthenticationMiddleware from './middlewares/jwt-authentication.middleware'; 5 | import authenticationRoute from './routes/authentication.route'; 6 | import userRoute from './routes/user.route'; 7 | 8 | const app = express(); 9 | 10 | app.use(express.json()); 11 | app.use(express.urlencoded({ extended: true })); 12 | 13 | app.use('/authentication', authenticationRoute); 14 | app.use('/users', jwtAuthenticationMiddleware, userRoute); 15 | 16 | app.use(errorHanddlerMiddleware); 17 | 18 | app.use('/', (req: Request, res: Response) => { 19 | res.json({ message: 'ok' }); 20 | }); 21 | 22 | const server = app.listen(3000, () => { 23 | console.log('listem on 3000!'); 24 | }); 25 | 26 | process.on('SIGTERM', () => { 27 | db.end(() => { 28 | console.log('database connection closed!') 29 | }); 30 | server.close(() => { 31 | console.log('server on 3000 closed!'); 32 | }); 33 | }) 34 | 35 | -------------------------------------------------------------------------------- /final-result/src/middlewares/basic-authentication.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from 'express'; 2 | import { ForbiddenError } from '../errors/forbidden.error'; 3 | import userRepository from '../repositories/user.repository'; 4 | 5 | const basicAuthMiddleware = async (req: Request, res: Response, next: NextFunction): Promise => { 6 | try { 7 | const authorizationHeader = req.headers.authorization; 8 | 9 | if (!authorizationHeader) { 10 | throw new ForbiddenError({ log: 'Credenciais not found' }); 11 | } 12 | 13 | const [authorizationType, base64Token] = authorizationHeader.split(' '); 14 | 15 | if (authorizationType !== 'Basic') { 16 | throw new ForbiddenError({ log: 'Invalid authorization type' }); 17 | } 18 | 19 | const [username, password] = Buffer.from(base64Token, 'base64').toString('utf-8').split(':'); 20 | 21 | if (!username || !password) { 22 | throw new ForbiddenError({ log: 'Credenciais not found' }); 23 | } 24 | 25 | const user = await userRepository.findByUsernameAndPassword(username, password); 26 | 27 | if (!user) { 28 | throw new ForbiddenError({ log: 'Invalid credentials' }); 29 | } 30 | 31 | req.user = user; 32 | return next(); 33 | } catch (error) { 34 | return next(error); 35 | } 36 | } 37 | 38 | export default basicAuthMiddleware; 39 | 40 | -------------------------------------------------------------------------------- /final-result/src/middlewares/error-handdles.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from 'express'; 2 | import { StatusCodes } from 'http-status-codes'; 3 | import { ForbiddenError } from '../errors/forbidden.error'; 4 | import HttpResponse from '../models/http-response.model'; 5 | 6 | const UNEXPECTED_ERROR = new HttpResponse( 7 | StatusCodes.INTERNAL_SERVER_ERROR, 8 | { message: 'unexpected-error' } 9 | ); 10 | 11 | const FORBIDDEN_ERROR = new HttpResponse( 12 | StatusCodes.FORBIDDEN, 13 | { message: 'forbidden' } 14 | ); 15 | 16 | const errorHanddlerMiddleware = (error: Error, req: Request, res: Response, next: NextFunction) => { 17 | let errorResponse = UNEXPECTED_ERROR; 18 | 19 | if (error instanceof ForbiddenError) { 20 | errorResponse = FORBIDDEN_ERROR; 21 | } 22 | 23 | console.error(error); 24 | return res.status(errorResponse.status).send(errorResponse.body); 25 | } 26 | 27 | export default errorHanddlerMiddleware; 28 | -------------------------------------------------------------------------------- /final-result/src/middlewares/jwt-authentication.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from 'express'; 2 | import JWT from 'jsonwebtoken'; 3 | import { ForbiddenError } from '../errors/forbidden.error'; 4 | import userRepository from '../repositories/user.repository'; 5 | 6 | 7 | const jwtAuthenticationMiddleware = async (req: Request, res: Response, next: NextFunction): Promise => { 8 | try { 9 | const authorizationHeader = req.headers.authorization; 10 | 11 | if (!authorizationHeader) { 12 | throw new ForbiddenError({ log: 'Credenciais not found' }); 13 | } 14 | 15 | const [authorizationType, jwtToken] = authorizationHeader.split(' '); 16 | 17 | if (authorizationType !== 'Bearer') { 18 | throw new ForbiddenError({ log: 'Invalid authorization type' }); 19 | } 20 | 21 | if (!jwtToken) { 22 | throw new ForbiddenError({ log: 'Invalid token' }); 23 | } 24 | 25 | try { 26 | const tokenPayload = JWT.verify(jwtToken, 'teste'); 27 | if (typeof tokenPayload !== 'object' || !tokenPayload.sub) { 28 | throw new ForbiddenError({ log: 'Invalid token' }); 29 | } 30 | 31 | const user = await userRepository.findByUuid(tokenPayload.sub); 32 | req.user = user; 33 | return next(); 34 | } catch (error) { 35 | throw new ForbiddenError({ log: 'Invalid token' }); 36 | } 37 | } catch (error) { 38 | return next(error); 39 | } 40 | } 41 | 42 | export default jwtAuthenticationMiddleware; -------------------------------------------------------------------------------- /final-result/src/models/http-response.model.ts: -------------------------------------------------------------------------------- 1 | 2 | export default class HttpResponse { 3 | constructor( 4 | public status: number, 5 | public body: { 6 | message: string; 7 | data?: T; 8 | } 9 | ) { }; 10 | } 11 | -------------------------------------------------------------------------------- /final-result/src/models/user.model.ts: -------------------------------------------------------------------------------- 1 | 2 | export type User = { 3 | uuid: string; 4 | username: string; 5 | password?: string; 6 | } 7 | -------------------------------------------------------------------------------- /final-result/src/repositories/user.repository.ts: -------------------------------------------------------------------------------- 1 | import config from 'config'; 2 | import db from '../database'; 3 | import { User } from '../models/user.model'; 4 | import { DatabaseError } from './../errors/database.error'; 5 | 6 | const authenticationCryptKey = config.get('authentication.cryptKey'); 7 | 8 | class UserRepository { 9 | 10 | async create(user: User): Promise { 11 | try { 12 | const script = ` 13 | INSERT INTO application_user ( 14 | username, 15 | password 16 | ) 17 | VALUES ($1, crypt($2, '${authenticationCryptKey}')) 18 | RETURNING uuid 19 | `; 20 | 21 | const values = [user.username, user.password]; 22 | const queryResult = await db.query<{ uuid: string }>(script, values); 23 | 24 | const [row] = queryResult.rows; 25 | return row.uuid; 26 | } catch (error) { 27 | throw new DatabaseError({ log: 'Erro ao inserir usuário', data: error }); 28 | } 29 | } 30 | 31 | async update(user: User): Promise { 32 | try { 33 | const script = ` 34 | UPDATE application_user 35 | SET 36 | username = $2, 37 | password = crypt($3, '${authenticationCryptKey}') 38 | WHERE uuid = $1 39 | `; 40 | 41 | const values = [user.uuid, user.username, user.password]; 42 | await db.query(script, values); 43 | } catch (error) { 44 | throw new DatabaseError({ log: 'Erro ao atualizar usuário', data: error }); 45 | } 46 | } 47 | 48 | async remove(uuid: string): Promise { 49 | try { 50 | const script = ` 51 | DELETE 52 | FROM application_user 53 | WHERE uuid = $1 54 | `; 55 | 56 | const values = [uuid]; 57 | await db.query(script, values); 58 | } catch (error) { 59 | throw new DatabaseError({ log: 'Erro ao deletar usuário', data: error }); 60 | } 61 | } 62 | 63 | async findByUuid(uuid: string): Promise { 64 | try { 65 | const query = ` 66 | SELECT 67 | uuid, 68 | username 69 | FROM application_user 70 | WHERE uuid = $1 71 | `; 72 | const queryResult = await db.query(query, [uuid]); 73 | const [row] = queryResult.rows; 74 | return !row ? null : row; 75 | } catch (error) { 76 | throw new DatabaseError({ log: 'Erro ao buscar usuário por uuid', data: error }); 77 | } 78 | } 79 | 80 | async findByUsernameAndPassword(username: string, password: string): Promise { 81 | try { 82 | const query = ` 83 | SELECT 84 | uuid, 85 | username 86 | FROM application_user 87 | WHERE username = $1 88 | AND password = crypt($2, '${authenticationCryptKey}') 89 | `; 90 | const queryResult = await db.query(query, [username, password]); 91 | const [row] = queryResult.rows; 92 | return !row ? null : row; 93 | } catch (error) { 94 | throw new DatabaseError({ log: 'Erro ao buscar usuário por username e password', data: error }); 95 | } 96 | } 97 | 98 | } 99 | 100 | export default new UserRepository(); 101 | -------------------------------------------------------------------------------- /final-result/src/routes/authentication.route.ts: -------------------------------------------------------------------------------- 1 | 2 | import { NextFunction, Request, Response, Router } from "express"; 3 | import { StatusCodes } from 'http-status-codes'; 4 | import JWT from 'jsonwebtoken'; 5 | import basicAuthMiddleware from "../middlewares/basic-authentication.middleware"; 6 | 7 | const route = Router(); 8 | 9 | // “iss” O domínio da aplicação geradora do token 10 | // “sub” É o assunto do token, mas é muito utilizado para guarda o ID do usuário 11 | // “aud” Define quem pode usar o token 12 | // “exp” Data para expiração do token 13 | // “nbf” Define uma data para qual o token não pode ser aceito antes dela 14 | // “iat” Data de criação do token 15 | // “jti” O id do token 16 | 17 | route.post('/token', basicAuthMiddleware, async (req: Request, res: Response, next: NextFunction) => { 18 | try { 19 | const token = JWT.sign({}, 'teste', { 20 | audience: 'consumer-uuid or api key', 21 | subject: req.user?.uuid 22 | }); 23 | 24 | return res.status(StatusCodes.OK).json({ token }); 25 | } catch (error) { 26 | next(error); 27 | } 28 | }); 29 | 30 | export default route; 31 | -------------------------------------------------------------------------------- /final-result/src/routes/user.route.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response, Router } from "express"; 2 | import { StatusCodes } from 'http-status-codes'; 3 | import { User } from '../models/user.model'; 4 | import userRepository from '../repositories/user.repository'; 5 | 6 | const route = Router(); 7 | 8 | route.get('/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 9 | try { 10 | const uuid = req.params.uuid; 11 | const user: User | null = await userRepository.findByUuid(uuid); 12 | 13 | if (!user) { 14 | return res.sendStatus(StatusCodes.NO_CONTENT); 15 | } 16 | 17 | return res.status(StatusCodes.OK).json(user); 18 | } catch (error) { 19 | return next(error); 20 | } 21 | }); 22 | 23 | route.post('/', async (req: Request, res: Response, next: NextFunction) => { 24 | try { 25 | const user: User = req.body; 26 | const uuid = await userRepository.create(user); 27 | return res.status(StatusCodes.CREATED).json({ uuid }); 28 | } catch (error) { 29 | return next(error); 30 | } 31 | }); 32 | 33 | route.put('/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 34 | try { 35 | const uuid = req.params.uuid; 36 | const user: User = req.body; 37 | user.uuid = uuid; 38 | const updatedUser = await userRepository.update(user); 39 | return res.status(StatusCodes.OK).json(updatedUser); 40 | } catch (error) { 41 | return next(error); 42 | } 43 | }); 44 | 45 | route.delete('/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 46 | try { 47 | const uuid = req.params.uuid; 48 | await userRepository.remove(uuid); 49 | return res.sendStatus(StatusCodes.OK); 50 | } catch (error) { 51 | return next(error); 52 | } 53 | }); 54 | 55 | export default route; 56 | -------------------------------------------------------------------------------- /final-result/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | /* Visit https://aka.ms/tsconfig.json to read more about this file */ 4 | 5 | /* Projects */ 6 | // "incremental": true, /* Enable incremental compilation */ 7 | // "composite": true, /* Enable constraints that allow a TypeScript project to be used with project references. */ 8 | // "tsBuildInfoFile": "./", /* Specify the folder for .tsbuildinfo incremental compilation files. */ 9 | // "disableSourceOfProjectReferenceRedirect": true, /* Disable preferring source files instead of declaration files when referencing composite projects */ 10 | // "disableSolutionSearching": true, /* Opt a project out of multi-project reference checking when editing. */ 11 | // "disableReferencedProjectLoad": true, /* Reduce the number of projects loaded automatically by TypeScript. */ 12 | 13 | /* Language and Environment */ 14 | "target": "es2019", /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */ 15 | // "lib": [], /* Specify a set of bundled library declaration files that describe the target runtime environment. */ 16 | // "jsx": "preserve", /* Specify what JSX code is generated. */ 17 | // "experimentalDecorators": true, /* Enable experimental support for TC39 stage 2 draft decorators. */ 18 | // "emitDecoratorMetadata": true, /* Emit design-type metadata for decorated declarations in source files. */ 19 | // "jsxFactory": "", /* Specify the JSX factory function used when targeting React JSX emit, e.g. 'React.createElement' or 'h' */ 20 | // "jsxFragmentFactory": "", /* Specify the JSX Fragment reference used for fragments when targeting React JSX emit e.g. 'React.Fragment' or 'Fragment'. */ 21 | // "jsxImportSource": "", /* Specify module specifier used to import the JSX factory functions when using `jsx: react-jsx*`.` */ 22 | // "reactNamespace": "", /* Specify the object invoked for `createElement`. This only applies when targeting `react` JSX emit. */ 23 | // "noLib": true, /* Disable including any library files, including the default lib.d.ts. */ 24 | // "useDefineForClassFields": true, /* Emit ECMAScript-standard-compliant class fields. */ 25 | 26 | /* Modules */ 27 | "module": "commonjs", /* Specify what module code is generated. */ 28 | "moduleResolution": "node", /* Specify how TypeScript looks up a file from a given module specifier. */ 29 | "rootDir": "src", /* Specify the root folder within your source files. */ 30 | // "baseUrl": "src", /* Specify the base directory to resolve non-relative module names. */ 31 | // "paths": { 32 | // "@/*": ["*"] 33 | // }, /* Specify a set of entries that re-map imports to additional lookup locations. */ 34 | // "rootDirs": [], /* Allow multiple folders to be treated as one when resolving modules. */ 35 | "typeRoots": [ 36 | "./src/@types", 37 | "./node_modules/@types" 38 | ], /* Specify multiple folders that act like `./node_modules/@types`. */ 39 | // "types": [], /* Specify type package names to be included without being referenced in a source file. */ 40 | // "allowUmdGlobalAccess": true, /* Allow accessing UMD globals from modules. */ 41 | // "resolveJsonModule": true, /* Enable importing .json files */ 42 | // "noResolve": true, /* Disallow `import`s, `require`s or ``s from expanding the number of files TypeScript should add to a project. */ 43 | 44 | /* JavaScript Support */ 45 | // "allowJs": true, /* Allow JavaScript files to be a part of your program. Use the `checkJS` option to get errors from these files. */ 46 | // "checkJs": true, /* Enable error reporting in type-checked JavaScript files. */ 47 | // "maxNodeModuleJsDepth": 1, /* Specify the maximum folder depth used for checking JavaScript files from `node_modules`. Only applicable with `allowJs`. */ 48 | 49 | /* Emit */ 50 | // "declaration": true, /* Generate .d.ts files from TypeScript and JavaScript files in your project. */ 51 | // "declarationMap": true, /* Create sourcemaps for d.ts files. */ 52 | // "emitDeclarationOnly": true, /* Only output d.ts files and not JavaScript files. */ 53 | // "sourceMap": true, /* Create source map files for emitted JavaScript files. */ 54 | // "outFile": "./", /* Specify a file that bundles all outputs into one JavaScript file. If `declaration` is true, also designates a file that bundles all .d.ts output. */ 55 | "outDir": "./dist", /* Specify an output folder for all emitted files. */ 56 | "removeComments": true, /* Disable emitting comments. */ 57 | // "noEmit": true, /* Disable emitting files from a compilation. */ 58 | // "importHelpers": true, /* Allow importing helper functions from tslib once per project, instead of including them per-file. */ 59 | // "importsNotUsedAsValues": "remove", /* Specify emit/checking behavior for imports that are only used for types */ 60 | // "downlevelIteration": true, /* Emit more compliant, but verbose and less performant JavaScript for iteration. */ 61 | // "sourceRoot": "", /* Specify the root path for debuggers to find the reference source code. */ 62 | // "mapRoot": "", /* Specify the location where debugger should locate map files instead of generated locations. */ 63 | // "inlineSourceMap": true, /* Include sourcemap files inside the emitted JavaScript. */ 64 | // "inlineSources": true, /* Include source code in the sourcemaps inside the emitted JavaScript. */ 65 | // "emitBOM": true, /* Emit a UTF-8 Byte Order Mark (BOM) in the beginning of output files. */ 66 | // "newLine": "crlf", /* Set the newline character for emitting files. */ 67 | // "stripInternal": true, /* Disable emitting declarations that have `@internal` in their JSDoc comments. */ 68 | // "noEmitHelpers": true, /* Disable generating custom helper functions like `__extends` in compiled output. */ 69 | // "noEmitOnError": true, /* Disable emitting files if any type checking errors are reported. */ 70 | // "preserveConstEnums": true, /* Disable erasing `const enum` declarations in generated code. */ 71 | // "declarationDir": "./", /* Specify the output directory for generated declaration files. */ 72 | 73 | /* Interop Constraints */ 74 | // "isolatedModules": true, /* Ensure that each file can be safely transpiled without relying on other imports. */ 75 | // "allowSyntheticDefaultImports": true, /* Allow 'import x from y' when a module doesn't have a default export. */ 76 | "esModuleInterop": true, /* Emit additional JavaScript to ease support for importing CommonJS modules. This enables `allowSyntheticDefaultImports` for type compatibility. */ 77 | // "preserveSymlinks": true, /* Disable resolving symlinks to their realpath. This correlates to the same flag in node. */ 78 | "forceConsistentCasingInFileNames": true, /* Ensure that casing is correct in imports. */ 79 | 80 | /* Type Checking */ 81 | "strict": true, /* Enable all strict type-checking options. */ 82 | // "noImplicitAny": true, /* Enable error reporting for expressions and declarations with an implied `any` type.. */ 83 | // "strictNullChecks": true, /* When type checking, take into account `null` and `undefined`. */ 84 | // "strictFunctionTypes": true, /* When assigning functions, check to ensure parameters and the return values are subtype-compatible. */ 85 | // "strictBindCallApply": true, /* Check that the arguments for `bind`, `call`, and `apply` methods match the original function. */ 86 | // "strictPropertyInitialization": true, /* Check for class properties that are declared but not set in the constructor. */ 87 | // "noImplicitThis": true, /* Enable error reporting when `this` is given the type `any`. */ 88 | // "useUnknownInCatchVariables": true, /* Type catch clause variables as 'unknown' instead of 'any'. */ 89 | // "alwaysStrict": true, /* Ensure 'use strict' is always emitted. */ 90 | // "noUnusedLocals": true, /* Enable error reporting when a local variables aren't read. */ 91 | // "noUnusedParameters": true, /* Raise an error when a function parameter isn't read */ 92 | // "exactOptionalPropertyTypes": true, /* Interpret optional property types as written, rather than adding 'undefined'. */ 93 | // "noImplicitReturns": true, /* Enable error reporting for codepaths that do not explicitly return in a function. */ 94 | // "noFallthroughCasesInSwitch": true, /* Enable error reporting for fallthrough cases in switch statements. */ 95 | // "noUncheckedIndexedAccess": true, /* Include 'undefined' in index signature results */ 96 | // "noImplicitOverride": true, /* Ensure overriding members in derived classes are marked with an override modifier. */ 97 | // "noPropertyAccessFromIndexSignature": true, /* Enforces using indexed accessors for keys declared using an indexed type */ 98 | // "allowUnusedLabels": true, /* Disable error reporting for unused labels. */ 99 | // "allowUnreachableCode": true, /* Disable error reporting for unreachable code. */ 100 | 101 | /* Completeness */ 102 | // "skipDefaultLibCheck": true, /* Skip type checking .d.ts files that are included with TypeScript. */ 103 | "skipLibCheck": true /* Skip type checking all .d.ts files. */ 104 | } 105 | } 106 | -------------------------------------------------------------------------------- /live-01/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist -------------------------------------------------------------------------------- /live-01/package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ms-authentication", 3 | "version": "1.0.0", 4 | "lockfileVersion": 2, 5 | "requires": true, 6 | "packages": { 7 | "": { 8 | "name": "ms-authentication", 9 | "version": "1.0.0", 10 | "license": "ISC", 11 | "dependencies": { 12 | "express": "^4.17.1", 13 | "http-status-codes": "^2.1.4" 14 | }, 15 | "devDependencies": { 16 | "@types/express": "^4.17.13", 17 | "@types/node": "^16.7.11", 18 | "ts-node-dev": "^1.1.8", 19 | "typescript": "^4.4.2" 20 | } 21 | }, 22 | "node_modules/@types/body-parser": { 23 | "version": "1.19.1", 24 | "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.1.tgz", 25 | "integrity": "sha512-a6bTJ21vFOGIkwM0kzh9Yr89ziVxq4vYH2fQ6N8AeipEzai/cFK6aGMArIkUeIdRIgpwQa+2bXiLuUJCpSf2Cg==", 26 | "dev": true, 27 | "dependencies": { 28 | "@types/connect": "*", 29 | "@types/node": "*" 30 | } 31 | }, 32 | "node_modules/@types/connect": { 33 | "version": "3.4.35", 34 | "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.35.tgz", 35 | "integrity": "sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==", 36 | "dev": true, 37 | "dependencies": { 38 | "@types/node": "*" 39 | } 40 | }, 41 | "node_modules/@types/express": { 42 | "version": "4.17.13", 43 | "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.13.tgz", 44 | "integrity": "sha512-6bSZTPaTIACxn48l50SR+axgrqm6qXFIxrdAKaG6PaJk3+zuUr35hBlgT7vOmJcum+OEaIBLtHV/qloEAFITeA==", 45 | "dev": true, 46 | "dependencies": { 47 | "@types/body-parser": "*", 48 | "@types/express-serve-static-core": "^4.17.18", 49 | "@types/qs": "*", 50 | "@types/serve-static": "*" 51 | } 52 | }, 53 | "node_modules/@types/express-serve-static-core": { 54 | "version": "4.17.24", 55 | "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.24.tgz", 56 | "integrity": "sha512-3UJuW+Qxhzwjq3xhwXm2onQcFHn76frIYVbTu+kn24LFxI+dEhdfISDFovPB8VpEgW8oQCTpRuCe+0zJxB7NEA==", 57 | "dev": true, 58 | "dependencies": { 59 | "@types/node": "*", 60 | "@types/qs": "*", 61 | "@types/range-parser": "*" 62 | } 63 | }, 64 | "node_modules/@types/mime": { 65 | "version": "1.3.2", 66 | "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.2.tgz", 67 | "integrity": "sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==", 68 | "dev": true 69 | }, 70 | "node_modules/@types/node": { 71 | "version": "16.7.11", 72 | "resolved": "https://registry.npmjs.org/@types/node/-/node-16.7.11.tgz", 73 | "integrity": "sha512-OtOGO+DYmNNqJQG9HG4e5a6iqoRcNfdCf4ha3div7XF5w/uOa3YVpb5aRGClwSDKLmfOysv2hFIvoklffnQi4w==", 74 | "dev": true 75 | }, 76 | "node_modules/@types/qs": { 77 | "version": "6.9.7", 78 | "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.7.tgz", 79 | "integrity": "sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==", 80 | "dev": true 81 | }, 82 | "node_modules/@types/range-parser": { 83 | "version": "1.2.4", 84 | "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.4.tgz", 85 | "integrity": "sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==", 86 | "dev": true 87 | }, 88 | "node_modules/@types/serve-static": { 89 | "version": "1.13.10", 90 | "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.13.10.tgz", 91 | "integrity": "sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ==", 92 | "dev": true, 93 | "dependencies": { 94 | "@types/mime": "^1", 95 | "@types/node": "*" 96 | } 97 | }, 98 | "node_modules/@types/strip-bom": { 99 | "version": "3.0.0", 100 | "resolved": "https://registry.npmjs.org/@types/strip-bom/-/strip-bom-3.0.0.tgz", 101 | "integrity": "sha1-FKjsOVbC6B7bdSB5CuzyHCkK69I=", 102 | "dev": true 103 | }, 104 | "node_modules/@types/strip-json-comments": { 105 | "version": "0.0.30", 106 | "resolved": "https://registry.npmjs.org/@types/strip-json-comments/-/strip-json-comments-0.0.30.tgz", 107 | "integrity": "sha512-7NQmHra/JILCd1QqpSzl8+mJRc8ZHz3uDm8YV1Ks9IhK0epEiTw8aIErbvH9PI+6XbqhyIQy3462nEsn7UVzjQ==", 108 | "dev": true 109 | }, 110 | "node_modules/accepts": { 111 | "version": "1.3.7", 112 | "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", 113 | "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", 114 | "dependencies": { 115 | "mime-types": "~2.1.24", 116 | "negotiator": "0.6.2" 117 | }, 118 | "engines": { 119 | "node": ">= 0.6" 120 | } 121 | }, 122 | "node_modules/anymatch": { 123 | "version": "3.1.2", 124 | "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", 125 | "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", 126 | "dev": true, 127 | "dependencies": { 128 | "normalize-path": "^3.0.0", 129 | "picomatch": "^2.0.4" 130 | }, 131 | "engines": { 132 | "node": ">= 8" 133 | } 134 | }, 135 | "node_modules/arg": { 136 | "version": "4.1.3", 137 | "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", 138 | "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", 139 | "dev": true 140 | }, 141 | "node_modules/array-flatten": { 142 | "version": "1.1.1", 143 | "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", 144 | "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=" 145 | }, 146 | "node_modules/balanced-match": { 147 | "version": "1.0.2", 148 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", 149 | "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", 150 | "dev": true 151 | }, 152 | "node_modules/binary-extensions": { 153 | "version": "2.2.0", 154 | "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", 155 | "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", 156 | "dev": true, 157 | "engines": { 158 | "node": ">=8" 159 | } 160 | }, 161 | "node_modules/body-parser": { 162 | "version": "1.19.0", 163 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", 164 | "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", 165 | "dependencies": { 166 | "bytes": "3.1.0", 167 | "content-type": "~1.0.4", 168 | "debug": "2.6.9", 169 | "depd": "~1.1.2", 170 | "http-errors": "1.7.2", 171 | "iconv-lite": "0.4.24", 172 | "on-finished": "~2.3.0", 173 | "qs": "6.7.0", 174 | "raw-body": "2.4.0", 175 | "type-is": "~1.6.17" 176 | }, 177 | "engines": { 178 | "node": ">= 0.8" 179 | } 180 | }, 181 | "node_modules/brace-expansion": { 182 | "version": "1.1.11", 183 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 184 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 185 | "dev": true, 186 | "dependencies": { 187 | "balanced-match": "^1.0.0", 188 | "concat-map": "0.0.1" 189 | } 190 | }, 191 | "node_modules/braces": { 192 | "version": "3.0.2", 193 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", 194 | "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", 195 | "dev": true, 196 | "dependencies": { 197 | "fill-range": "^7.0.1" 198 | }, 199 | "engines": { 200 | "node": ">=8" 201 | } 202 | }, 203 | "node_modules/buffer-from": { 204 | "version": "1.1.2", 205 | "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", 206 | "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", 207 | "dev": true 208 | }, 209 | "node_modules/bytes": { 210 | "version": "3.1.0", 211 | "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", 212 | "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==", 213 | "engines": { 214 | "node": ">= 0.8" 215 | } 216 | }, 217 | "node_modules/chokidar": { 218 | "version": "3.5.2", 219 | "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.2.tgz", 220 | "integrity": "sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ==", 221 | "dev": true, 222 | "dependencies": { 223 | "anymatch": "~3.1.2", 224 | "braces": "~3.0.2", 225 | "glob-parent": "~5.1.2", 226 | "is-binary-path": "~2.1.0", 227 | "is-glob": "~4.0.1", 228 | "normalize-path": "~3.0.0", 229 | "readdirp": "~3.6.0" 230 | }, 231 | "engines": { 232 | "node": ">= 8.10.0" 233 | }, 234 | "optionalDependencies": { 235 | "fsevents": "~2.3.2" 236 | } 237 | }, 238 | "node_modules/concat-map": { 239 | "version": "0.0.1", 240 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 241 | "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", 242 | "dev": true 243 | }, 244 | "node_modules/content-disposition": { 245 | "version": "0.5.3", 246 | "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz", 247 | "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==", 248 | "dependencies": { 249 | "safe-buffer": "5.1.2" 250 | }, 251 | "engines": { 252 | "node": ">= 0.6" 253 | } 254 | }, 255 | "node_modules/content-type": { 256 | "version": "1.0.4", 257 | "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", 258 | "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==", 259 | "engines": { 260 | "node": ">= 0.6" 261 | } 262 | }, 263 | "node_modules/cookie": { 264 | "version": "0.4.0", 265 | "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", 266 | "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==", 267 | "engines": { 268 | "node": ">= 0.6" 269 | } 270 | }, 271 | "node_modules/cookie-signature": { 272 | "version": "1.0.6", 273 | "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", 274 | "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw=" 275 | }, 276 | "node_modules/create-require": { 277 | "version": "1.1.1", 278 | "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", 279 | "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", 280 | "dev": true 281 | }, 282 | "node_modules/debug": { 283 | "version": "2.6.9", 284 | "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", 285 | "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", 286 | "dependencies": { 287 | "ms": "2.0.0" 288 | } 289 | }, 290 | "node_modules/depd": { 291 | "version": "1.1.2", 292 | "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", 293 | "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=", 294 | "engines": { 295 | "node": ">= 0.6" 296 | } 297 | }, 298 | "node_modules/destroy": { 299 | "version": "1.0.4", 300 | "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", 301 | "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" 302 | }, 303 | "node_modules/diff": { 304 | "version": "4.0.2", 305 | "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", 306 | "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", 307 | "dev": true, 308 | "engines": { 309 | "node": ">=0.3.1" 310 | } 311 | }, 312 | "node_modules/dynamic-dedupe": { 313 | "version": "0.3.0", 314 | "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", 315 | "integrity": "sha1-BuRMIj9eTpTXjvnbI6ZRXOL5YqE=", 316 | "dev": true, 317 | "dependencies": { 318 | "xtend": "^4.0.0" 319 | } 320 | }, 321 | "node_modules/ee-first": { 322 | "version": "1.1.1", 323 | "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", 324 | "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" 325 | }, 326 | "node_modules/encodeurl": { 327 | "version": "1.0.2", 328 | "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", 329 | "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=", 330 | "engines": { 331 | "node": ">= 0.8" 332 | } 333 | }, 334 | "node_modules/escape-html": { 335 | "version": "1.0.3", 336 | "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", 337 | "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" 338 | }, 339 | "node_modules/etag": { 340 | "version": "1.8.1", 341 | "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", 342 | "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=", 343 | "engines": { 344 | "node": ">= 0.6" 345 | } 346 | }, 347 | "node_modules/express": { 348 | "version": "4.17.1", 349 | "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz", 350 | "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==", 351 | "dependencies": { 352 | "accepts": "~1.3.7", 353 | "array-flatten": "1.1.1", 354 | "body-parser": "1.19.0", 355 | "content-disposition": "0.5.3", 356 | "content-type": "~1.0.4", 357 | "cookie": "0.4.0", 358 | "cookie-signature": "1.0.6", 359 | "debug": "2.6.9", 360 | "depd": "~1.1.2", 361 | "encodeurl": "~1.0.2", 362 | "escape-html": "~1.0.3", 363 | "etag": "~1.8.1", 364 | "finalhandler": "~1.1.2", 365 | "fresh": "0.5.2", 366 | "merge-descriptors": "1.0.1", 367 | "methods": "~1.1.2", 368 | "on-finished": "~2.3.0", 369 | "parseurl": "~1.3.3", 370 | "path-to-regexp": "0.1.7", 371 | "proxy-addr": "~2.0.5", 372 | "qs": "6.7.0", 373 | "range-parser": "~1.2.1", 374 | "safe-buffer": "5.1.2", 375 | "send": "0.17.1", 376 | "serve-static": "1.14.1", 377 | "setprototypeof": "1.1.1", 378 | "statuses": "~1.5.0", 379 | "type-is": "~1.6.18", 380 | "utils-merge": "1.0.1", 381 | "vary": "~1.1.2" 382 | }, 383 | "engines": { 384 | "node": ">= 0.10.0" 385 | } 386 | }, 387 | "node_modules/fill-range": { 388 | "version": "7.0.1", 389 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", 390 | "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", 391 | "dev": true, 392 | "dependencies": { 393 | "to-regex-range": "^5.0.1" 394 | }, 395 | "engines": { 396 | "node": ">=8" 397 | } 398 | }, 399 | "node_modules/finalhandler": { 400 | "version": "1.1.2", 401 | "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", 402 | "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", 403 | "dependencies": { 404 | "debug": "2.6.9", 405 | "encodeurl": "~1.0.2", 406 | "escape-html": "~1.0.3", 407 | "on-finished": "~2.3.0", 408 | "parseurl": "~1.3.3", 409 | "statuses": "~1.5.0", 410 | "unpipe": "~1.0.0" 411 | }, 412 | "engines": { 413 | "node": ">= 0.8" 414 | } 415 | }, 416 | "node_modules/forwarded": { 417 | "version": "0.2.0", 418 | "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", 419 | "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", 420 | "engines": { 421 | "node": ">= 0.6" 422 | } 423 | }, 424 | "node_modules/fresh": { 425 | "version": "0.5.2", 426 | "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", 427 | "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=", 428 | "engines": { 429 | "node": ">= 0.6" 430 | } 431 | }, 432 | "node_modules/fs.realpath": { 433 | "version": "1.0.0", 434 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 435 | "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", 436 | "dev": true 437 | }, 438 | "node_modules/fsevents": { 439 | "version": "2.3.2", 440 | "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", 441 | "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", 442 | "dev": true, 443 | "hasInstallScript": true, 444 | "optional": true, 445 | "os": [ 446 | "darwin" 447 | ], 448 | "engines": { 449 | "node": "^8.16.0 || ^10.6.0 || >=11.0.0" 450 | } 451 | }, 452 | "node_modules/function-bind": { 453 | "version": "1.1.1", 454 | "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", 455 | "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", 456 | "dev": true 457 | }, 458 | "node_modules/glob": { 459 | "version": "7.1.7", 460 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz", 461 | "integrity": "sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==", 462 | "dev": true, 463 | "dependencies": { 464 | "fs.realpath": "^1.0.0", 465 | "inflight": "^1.0.4", 466 | "inherits": "2", 467 | "minimatch": "^3.0.4", 468 | "once": "^1.3.0", 469 | "path-is-absolute": "^1.0.0" 470 | }, 471 | "engines": { 472 | "node": "*" 473 | }, 474 | "funding": { 475 | "url": "https://github.com/sponsors/isaacs" 476 | } 477 | }, 478 | "node_modules/glob-parent": { 479 | "version": "5.1.2", 480 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", 481 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", 482 | "dev": true, 483 | "dependencies": { 484 | "is-glob": "^4.0.1" 485 | }, 486 | "engines": { 487 | "node": ">= 6" 488 | } 489 | }, 490 | "node_modules/has": { 491 | "version": "1.0.3", 492 | "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", 493 | "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", 494 | "dev": true, 495 | "dependencies": { 496 | "function-bind": "^1.1.1" 497 | }, 498 | "engines": { 499 | "node": ">= 0.4.0" 500 | } 501 | }, 502 | "node_modules/http-errors": { 503 | "version": "1.7.2", 504 | "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", 505 | "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", 506 | "dependencies": { 507 | "depd": "~1.1.2", 508 | "inherits": "2.0.3", 509 | "setprototypeof": "1.1.1", 510 | "statuses": ">= 1.5.0 < 2", 511 | "toidentifier": "1.0.0" 512 | }, 513 | "engines": { 514 | "node": ">= 0.6" 515 | } 516 | }, 517 | "node_modules/http-status-codes": { 518 | "version": "2.1.4", 519 | "resolved": "https://registry.npmjs.org/http-status-codes/-/http-status-codes-2.1.4.tgz", 520 | "integrity": "sha512-MZVIsLKGVOVE1KEnldppe6Ij+vmemMuApDfjhVSLzyYP+td0bREEYyAoIw9yFePoBXManCuBqmiNP5FqJS5Xkg==" 521 | }, 522 | "node_modules/iconv-lite": { 523 | "version": "0.4.24", 524 | "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", 525 | "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", 526 | "dependencies": { 527 | "safer-buffer": ">= 2.1.2 < 3" 528 | }, 529 | "engines": { 530 | "node": ">=0.10.0" 531 | } 532 | }, 533 | "node_modules/inflight": { 534 | "version": "1.0.6", 535 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 536 | "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", 537 | "dev": true, 538 | "dependencies": { 539 | "once": "^1.3.0", 540 | "wrappy": "1" 541 | } 542 | }, 543 | "node_modules/inherits": { 544 | "version": "2.0.3", 545 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", 546 | "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" 547 | }, 548 | "node_modules/ipaddr.js": { 549 | "version": "1.9.1", 550 | "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", 551 | "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", 552 | "engines": { 553 | "node": ">= 0.10" 554 | } 555 | }, 556 | "node_modules/is-binary-path": { 557 | "version": "2.1.0", 558 | "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", 559 | "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", 560 | "dev": true, 561 | "dependencies": { 562 | "binary-extensions": "^2.0.0" 563 | }, 564 | "engines": { 565 | "node": ">=8" 566 | } 567 | }, 568 | "node_modules/is-core-module": { 569 | "version": "2.6.0", 570 | "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.6.0.tgz", 571 | "integrity": "sha512-wShG8vs60jKfPWpF2KZRaAtvt3a20OAn7+IJ6hLPECpSABLcKtFKTTI4ZtH5QcBruBHlq+WsdHWyz0BCZW7svQ==", 572 | "dev": true, 573 | "dependencies": { 574 | "has": "^1.0.3" 575 | }, 576 | "funding": { 577 | "url": "https://github.com/sponsors/ljharb" 578 | } 579 | }, 580 | "node_modules/is-extglob": { 581 | "version": "2.1.1", 582 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", 583 | "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", 584 | "dev": true, 585 | "engines": { 586 | "node": ">=0.10.0" 587 | } 588 | }, 589 | "node_modules/is-glob": { 590 | "version": "4.0.1", 591 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", 592 | "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", 593 | "dev": true, 594 | "dependencies": { 595 | "is-extglob": "^2.1.1" 596 | }, 597 | "engines": { 598 | "node": ">=0.10.0" 599 | } 600 | }, 601 | "node_modules/is-number": { 602 | "version": "7.0.0", 603 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", 604 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", 605 | "dev": true, 606 | "engines": { 607 | "node": ">=0.12.0" 608 | } 609 | }, 610 | "node_modules/make-error": { 611 | "version": "1.3.6", 612 | "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", 613 | "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", 614 | "dev": true 615 | }, 616 | "node_modules/media-typer": { 617 | "version": "0.3.0", 618 | "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", 619 | "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=", 620 | "engines": { 621 | "node": ">= 0.6" 622 | } 623 | }, 624 | "node_modules/merge-descriptors": { 625 | "version": "1.0.1", 626 | "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", 627 | "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" 628 | }, 629 | "node_modules/methods": { 630 | "version": "1.1.2", 631 | "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", 632 | "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=", 633 | "engines": { 634 | "node": ">= 0.6" 635 | } 636 | }, 637 | "node_modules/mime": { 638 | "version": "1.6.0", 639 | "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", 640 | "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", 641 | "bin": { 642 | "mime": "cli.js" 643 | }, 644 | "engines": { 645 | "node": ">=4" 646 | } 647 | }, 648 | "node_modules/mime-db": { 649 | "version": "1.49.0", 650 | "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", 651 | "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==", 652 | "engines": { 653 | "node": ">= 0.6" 654 | } 655 | }, 656 | "node_modules/mime-types": { 657 | "version": "2.1.32", 658 | "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", 659 | "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", 660 | "dependencies": { 661 | "mime-db": "1.49.0" 662 | }, 663 | "engines": { 664 | "node": ">= 0.6" 665 | } 666 | }, 667 | "node_modules/minimatch": { 668 | "version": "3.0.4", 669 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", 670 | "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", 671 | "dev": true, 672 | "dependencies": { 673 | "brace-expansion": "^1.1.7" 674 | }, 675 | "engines": { 676 | "node": "*" 677 | } 678 | }, 679 | "node_modules/minimist": { 680 | "version": "1.2.5", 681 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", 682 | "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", 683 | "dev": true 684 | }, 685 | "node_modules/mkdirp": { 686 | "version": "1.0.4", 687 | "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", 688 | "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", 689 | "dev": true, 690 | "bin": { 691 | "mkdirp": "bin/cmd.js" 692 | }, 693 | "engines": { 694 | "node": ">=10" 695 | } 696 | }, 697 | "node_modules/ms": { 698 | "version": "2.0.0", 699 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", 700 | "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" 701 | }, 702 | "node_modules/negotiator": { 703 | "version": "0.6.2", 704 | "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", 705 | "integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==", 706 | "engines": { 707 | "node": ">= 0.6" 708 | } 709 | }, 710 | "node_modules/normalize-path": { 711 | "version": "3.0.0", 712 | "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", 713 | "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", 714 | "dev": true, 715 | "engines": { 716 | "node": ">=0.10.0" 717 | } 718 | }, 719 | "node_modules/on-finished": { 720 | "version": "2.3.0", 721 | "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", 722 | "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", 723 | "dependencies": { 724 | "ee-first": "1.1.1" 725 | }, 726 | "engines": { 727 | "node": ">= 0.8" 728 | } 729 | }, 730 | "node_modules/once": { 731 | "version": "1.4.0", 732 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 733 | "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", 734 | "dev": true, 735 | "dependencies": { 736 | "wrappy": "1" 737 | } 738 | }, 739 | "node_modules/parseurl": { 740 | "version": "1.3.3", 741 | "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", 742 | "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", 743 | "engines": { 744 | "node": ">= 0.8" 745 | } 746 | }, 747 | "node_modules/path-is-absolute": { 748 | "version": "1.0.1", 749 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 750 | "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", 751 | "dev": true, 752 | "engines": { 753 | "node": ">=0.10.0" 754 | } 755 | }, 756 | "node_modules/path-parse": { 757 | "version": "1.0.7", 758 | "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", 759 | "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", 760 | "dev": true 761 | }, 762 | "node_modules/path-to-regexp": { 763 | "version": "0.1.7", 764 | "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", 765 | "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" 766 | }, 767 | "node_modules/picomatch": { 768 | "version": "2.3.0", 769 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", 770 | "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", 771 | "dev": true, 772 | "engines": { 773 | "node": ">=8.6" 774 | }, 775 | "funding": { 776 | "url": "https://github.com/sponsors/jonschlinkert" 777 | } 778 | }, 779 | "node_modules/proxy-addr": { 780 | "version": "2.0.7", 781 | "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", 782 | "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", 783 | "dependencies": { 784 | "forwarded": "0.2.0", 785 | "ipaddr.js": "1.9.1" 786 | }, 787 | "engines": { 788 | "node": ">= 0.10" 789 | } 790 | }, 791 | "node_modules/qs": { 792 | "version": "6.7.0", 793 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", 794 | "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==", 795 | "engines": { 796 | "node": ">=0.6" 797 | } 798 | }, 799 | "node_modules/range-parser": { 800 | "version": "1.2.1", 801 | "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", 802 | "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", 803 | "engines": { 804 | "node": ">= 0.6" 805 | } 806 | }, 807 | "node_modules/raw-body": { 808 | "version": "2.4.0", 809 | "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz", 810 | "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==", 811 | "dependencies": { 812 | "bytes": "3.1.0", 813 | "http-errors": "1.7.2", 814 | "iconv-lite": "0.4.24", 815 | "unpipe": "1.0.0" 816 | }, 817 | "engines": { 818 | "node": ">= 0.8" 819 | } 820 | }, 821 | "node_modules/readdirp": { 822 | "version": "3.6.0", 823 | "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", 824 | "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", 825 | "dev": true, 826 | "dependencies": { 827 | "picomatch": "^2.2.1" 828 | }, 829 | "engines": { 830 | "node": ">=8.10.0" 831 | } 832 | }, 833 | "node_modules/resolve": { 834 | "version": "1.20.0", 835 | "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz", 836 | "integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==", 837 | "dev": true, 838 | "dependencies": { 839 | "is-core-module": "^2.2.0", 840 | "path-parse": "^1.0.6" 841 | }, 842 | "funding": { 843 | "url": "https://github.com/sponsors/ljharb" 844 | } 845 | }, 846 | "node_modules/rimraf": { 847 | "version": "2.7.1", 848 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", 849 | "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", 850 | "dev": true, 851 | "dependencies": { 852 | "glob": "^7.1.3" 853 | }, 854 | "bin": { 855 | "rimraf": "bin.js" 856 | } 857 | }, 858 | "node_modules/safe-buffer": { 859 | "version": "5.1.2", 860 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 861 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" 862 | }, 863 | "node_modules/safer-buffer": { 864 | "version": "2.1.2", 865 | "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", 866 | "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" 867 | }, 868 | "node_modules/send": { 869 | "version": "0.17.1", 870 | "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz", 871 | "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==", 872 | "dependencies": { 873 | "debug": "2.6.9", 874 | "depd": "~1.1.2", 875 | "destroy": "~1.0.4", 876 | "encodeurl": "~1.0.2", 877 | "escape-html": "~1.0.3", 878 | "etag": "~1.8.1", 879 | "fresh": "0.5.2", 880 | "http-errors": "~1.7.2", 881 | "mime": "1.6.0", 882 | "ms": "2.1.1", 883 | "on-finished": "~2.3.0", 884 | "range-parser": "~1.2.1", 885 | "statuses": "~1.5.0" 886 | }, 887 | "engines": { 888 | "node": ">= 0.8.0" 889 | } 890 | }, 891 | "node_modules/send/node_modules/ms": { 892 | "version": "2.1.1", 893 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", 894 | "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" 895 | }, 896 | "node_modules/serve-static": { 897 | "version": "1.14.1", 898 | "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz", 899 | "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==", 900 | "dependencies": { 901 | "encodeurl": "~1.0.2", 902 | "escape-html": "~1.0.3", 903 | "parseurl": "~1.3.3", 904 | "send": "0.17.1" 905 | }, 906 | "engines": { 907 | "node": ">= 0.8.0" 908 | } 909 | }, 910 | "node_modules/setprototypeof": { 911 | "version": "1.1.1", 912 | "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz", 913 | "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==" 914 | }, 915 | "node_modules/source-map": { 916 | "version": "0.6.1", 917 | "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", 918 | "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", 919 | "dev": true, 920 | "engines": { 921 | "node": ">=0.10.0" 922 | } 923 | }, 924 | "node_modules/source-map-support": { 925 | "version": "0.5.19", 926 | "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", 927 | "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", 928 | "dev": true, 929 | "dependencies": { 930 | "buffer-from": "^1.0.0", 931 | "source-map": "^0.6.0" 932 | } 933 | }, 934 | "node_modules/statuses": { 935 | "version": "1.5.0", 936 | "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", 937 | "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=", 938 | "engines": { 939 | "node": ">= 0.6" 940 | } 941 | }, 942 | "node_modules/strip-bom": { 943 | "version": "3.0.0", 944 | "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", 945 | "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", 946 | "dev": true, 947 | "engines": { 948 | "node": ">=4" 949 | } 950 | }, 951 | "node_modules/strip-json-comments": { 952 | "version": "2.0.1", 953 | "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", 954 | "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", 955 | "dev": true, 956 | "engines": { 957 | "node": ">=0.10.0" 958 | } 959 | }, 960 | "node_modules/to-regex-range": { 961 | "version": "5.0.1", 962 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", 963 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", 964 | "dev": true, 965 | "dependencies": { 966 | "is-number": "^7.0.0" 967 | }, 968 | "engines": { 969 | "node": ">=8.0" 970 | } 971 | }, 972 | "node_modules/toidentifier": { 973 | "version": "1.0.0", 974 | "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", 975 | "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==", 976 | "engines": { 977 | "node": ">=0.6" 978 | } 979 | }, 980 | "node_modules/tree-kill": { 981 | "version": "1.2.2", 982 | "resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz", 983 | "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==", 984 | "dev": true, 985 | "bin": { 986 | "tree-kill": "cli.js" 987 | } 988 | }, 989 | "node_modules/ts-node": { 990 | "version": "9.1.1", 991 | "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz", 992 | "integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==", 993 | "dev": true, 994 | "dependencies": { 995 | "arg": "^4.1.0", 996 | "create-require": "^1.1.0", 997 | "diff": "^4.0.1", 998 | "make-error": "^1.1.1", 999 | "source-map-support": "^0.5.17", 1000 | "yn": "3.1.1" 1001 | }, 1002 | "bin": { 1003 | "ts-node": "dist/bin.js", 1004 | "ts-node-script": "dist/bin-script.js", 1005 | "ts-node-transpile-only": "dist/bin-transpile.js", 1006 | "ts-script": "dist/bin-script-deprecated.js" 1007 | }, 1008 | "engines": { 1009 | "node": ">=10.0.0" 1010 | }, 1011 | "peerDependencies": { 1012 | "typescript": ">=2.7" 1013 | } 1014 | }, 1015 | "node_modules/ts-node-dev": { 1016 | "version": "1.1.8", 1017 | "resolved": "https://registry.npmjs.org/ts-node-dev/-/ts-node-dev-1.1.8.tgz", 1018 | "integrity": "sha512-Q/m3vEwzYwLZKmV6/0VlFxcZzVV/xcgOt+Tx/VjaaRHyiBcFlV0541yrT09QjzzCxlDZ34OzKjrFAynlmtflEg==", 1019 | "dev": true, 1020 | "dependencies": { 1021 | "chokidar": "^3.5.1", 1022 | "dynamic-dedupe": "^0.3.0", 1023 | "minimist": "^1.2.5", 1024 | "mkdirp": "^1.0.4", 1025 | "resolve": "^1.0.0", 1026 | "rimraf": "^2.6.1", 1027 | "source-map-support": "^0.5.12", 1028 | "tree-kill": "^1.2.2", 1029 | "ts-node": "^9.0.0", 1030 | "tsconfig": "^7.0.0" 1031 | }, 1032 | "bin": { 1033 | "ts-node-dev": "lib/bin.js", 1034 | "tsnd": "lib/bin.js" 1035 | }, 1036 | "engines": { 1037 | "node": ">=0.8.0" 1038 | }, 1039 | "peerDependencies": { 1040 | "node-notifier": "*", 1041 | "typescript": "*" 1042 | }, 1043 | "peerDependenciesMeta": { 1044 | "node-notifier": { 1045 | "optional": true 1046 | } 1047 | } 1048 | }, 1049 | "node_modules/tsconfig": { 1050 | "version": "7.0.0", 1051 | "resolved": "https://registry.npmjs.org/tsconfig/-/tsconfig-7.0.0.tgz", 1052 | "integrity": "sha512-vZXmzPrL+EmC4T/4rVlT2jNVMWCi/O4DIiSj3UHg1OE5kCKbk4mfrXc6dZksLgRM/TZlKnousKH9bbTazUWRRw==", 1053 | "dev": true, 1054 | "dependencies": { 1055 | "@types/strip-bom": "^3.0.0", 1056 | "@types/strip-json-comments": "0.0.30", 1057 | "strip-bom": "^3.0.0", 1058 | "strip-json-comments": "^2.0.0" 1059 | } 1060 | }, 1061 | "node_modules/type-is": { 1062 | "version": "1.6.18", 1063 | "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", 1064 | "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", 1065 | "dependencies": { 1066 | "media-typer": "0.3.0", 1067 | "mime-types": "~2.1.24" 1068 | }, 1069 | "engines": { 1070 | "node": ">= 0.6" 1071 | } 1072 | }, 1073 | "node_modules/typescript": { 1074 | "version": "4.4.2", 1075 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.4.2.tgz", 1076 | "integrity": "sha512-gzP+t5W4hdy4c+68bfcv0t400HVJMMd2+H9B7gae1nQlBzCqvrXX+6GL/b3GAgyTH966pzrZ70/fRjwAtZksSQ==", 1077 | "dev": true, 1078 | "bin": { 1079 | "tsc": "bin/tsc", 1080 | "tsserver": "bin/tsserver" 1081 | }, 1082 | "engines": { 1083 | "node": ">=4.2.0" 1084 | } 1085 | }, 1086 | "node_modules/unpipe": { 1087 | "version": "1.0.0", 1088 | "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", 1089 | "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=", 1090 | "engines": { 1091 | "node": ">= 0.8" 1092 | } 1093 | }, 1094 | "node_modules/utils-merge": { 1095 | "version": "1.0.1", 1096 | "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", 1097 | "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=", 1098 | "engines": { 1099 | "node": ">= 0.4.0" 1100 | } 1101 | }, 1102 | "node_modules/vary": { 1103 | "version": "1.1.2", 1104 | "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", 1105 | "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=", 1106 | "engines": { 1107 | "node": ">= 0.8" 1108 | } 1109 | }, 1110 | "node_modules/wrappy": { 1111 | "version": "1.0.2", 1112 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 1113 | "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", 1114 | "dev": true 1115 | }, 1116 | "node_modules/xtend": { 1117 | "version": "4.0.2", 1118 | "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", 1119 | "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", 1120 | "dev": true, 1121 | "engines": { 1122 | "node": ">=0.4" 1123 | } 1124 | }, 1125 | "node_modules/yn": { 1126 | "version": "3.1.1", 1127 | "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", 1128 | "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", 1129 | "dev": true, 1130 | "engines": { 1131 | "node": ">=6" 1132 | } 1133 | } 1134 | }, 1135 | "dependencies": { 1136 | "@types/body-parser": { 1137 | "version": "1.19.1", 1138 | "resolved": "https://registry.npmjs.org/@types/body-parser/-/body-parser-1.19.1.tgz", 1139 | "integrity": "sha512-a6bTJ21vFOGIkwM0kzh9Yr89ziVxq4vYH2fQ6N8AeipEzai/cFK6aGMArIkUeIdRIgpwQa+2bXiLuUJCpSf2Cg==", 1140 | "dev": true, 1141 | "requires": { 1142 | "@types/connect": "*", 1143 | "@types/node": "*" 1144 | } 1145 | }, 1146 | "@types/connect": { 1147 | "version": "3.4.35", 1148 | "resolved": "https://registry.npmjs.org/@types/connect/-/connect-3.4.35.tgz", 1149 | "integrity": "sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ==", 1150 | "dev": true, 1151 | "requires": { 1152 | "@types/node": "*" 1153 | } 1154 | }, 1155 | "@types/express": { 1156 | "version": "4.17.13", 1157 | "resolved": "https://registry.npmjs.org/@types/express/-/express-4.17.13.tgz", 1158 | "integrity": "sha512-6bSZTPaTIACxn48l50SR+axgrqm6qXFIxrdAKaG6PaJk3+zuUr35hBlgT7vOmJcum+OEaIBLtHV/qloEAFITeA==", 1159 | "dev": true, 1160 | "requires": { 1161 | "@types/body-parser": "*", 1162 | "@types/express-serve-static-core": "^4.17.18", 1163 | "@types/qs": "*", 1164 | "@types/serve-static": "*" 1165 | } 1166 | }, 1167 | "@types/express-serve-static-core": { 1168 | "version": "4.17.24", 1169 | "resolved": "https://registry.npmjs.org/@types/express-serve-static-core/-/express-serve-static-core-4.17.24.tgz", 1170 | "integrity": "sha512-3UJuW+Qxhzwjq3xhwXm2onQcFHn76frIYVbTu+kn24LFxI+dEhdfISDFovPB8VpEgW8oQCTpRuCe+0zJxB7NEA==", 1171 | "dev": true, 1172 | "requires": { 1173 | "@types/node": "*", 1174 | "@types/qs": "*", 1175 | "@types/range-parser": "*" 1176 | } 1177 | }, 1178 | "@types/mime": { 1179 | "version": "1.3.2", 1180 | "resolved": "https://registry.npmjs.org/@types/mime/-/mime-1.3.2.tgz", 1181 | "integrity": "sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw==", 1182 | "dev": true 1183 | }, 1184 | "@types/node": { 1185 | "version": "16.7.11", 1186 | "resolved": "https://registry.npmjs.org/@types/node/-/node-16.7.11.tgz", 1187 | "integrity": "sha512-OtOGO+DYmNNqJQG9HG4e5a6iqoRcNfdCf4ha3div7XF5w/uOa3YVpb5aRGClwSDKLmfOysv2hFIvoklffnQi4w==", 1188 | "dev": true 1189 | }, 1190 | "@types/qs": { 1191 | "version": "6.9.7", 1192 | "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.9.7.tgz", 1193 | "integrity": "sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==", 1194 | "dev": true 1195 | }, 1196 | "@types/range-parser": { 1197 | "version": "1.2.4", 1198 | "resolved": "https://registry.npmjs.org/@types/range-parser/-/range-parser-1.2.4.tgz", 1199 | "integrity": "sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw==", 1200 | "dev": true 1201 | }, 1202 | "@types/serve-static": { 1203 | "version": "1.13.10", 1204 | "resolved": "https://registry.npmjs.org/@types/serve-static/-/serve-static-1.13.10.tgz", 1205 | "integrity": "sha512-nCkHGI4w7ZgAdNkrEu0bv+4xNV/XDqW+DydknebMOQwkpDGx8G+HTlj7R7ABI8i8nKxVw0wtKPi1D+lPOkh4YQ==", 1206 | "dev": true, 1207 | "requires": { 1208 | "@types/mime": "^1", 1209 | "@types/node": "*" 1210 | } 1211 | }, 1212 | "@types/strip-bom": { 1213 | "version": "3.0.0", 1214 | "resolved": "https://registry.npmjs.org/@types/strip-bom/-/strip-bom-3.0.0.tgz", 1215 | "integrity": "sha1-FKjsOVbC6B7bdSB5CuzyHCkK69I=", 1216 | "dev": true 1217 | }, 1218 | "@types/strip-json-comments": { 1219 | "version": "0.0.30", 1220 | "resolved": "https://registry.npmjs.org/@types/strip-json-comments/-/strip-json-comments-0.0.30.tgz", 1221 | "integrity": "sha512-7NQmHra/JILCd1QqpSzl8+mJRc8ZHz3uDm8YV1Ks9IhK0epEiTw8aIErbvH9PI+6XbqhyIQy3462nEsn7UVzjQ==", 1222 | "dev": true 1223 | }, 1224 | "accepts": { 1225 | "version": "1.3.7", 1226 | "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", 1227 | "integrity": "sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==", 1228 | "requires": { 1229 | "mime-types": "~2.1.24", 1230 | "negotiator": "0.6.2" 1231 | } 1232 | }, 1233 | "anymatch": { 1234 | "version": "3.1.2", 1235 | "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.2.tgz", 1236 | "integrity": "sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==", 1237 | "dev": true, 1238 | "requires": { 1239 | "normalize-path": "^3.0.0", 1240 | "picomatch": "^2.0.4" 1241 | } 1242 | }, 1243 | "arg": { 1244 | "version": "4.1.3", 1245 | "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", 1246 | "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", 1247 | "dev": true 1248 | }, 1249 | "array-flatten": { 1250 | "version": "1.1.1", 1251 | "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-1.1.1.tgz", 1252 | "integrity": "sha1-ml9pkFGx5wczKPKgCJaLZOopVdI=" 1253 | }, 1254 | "balanced-match": { 1255 | "version": "1.0.2", 1256 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", 1257 | "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", 1258 | "dev": true 1259 | }, 1260 | "binary-extensions": { 1261 | "version": "2.2.0", 1262 | "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", 1263 | "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", 1264 | "dev": true 1265 | }, 1266 | "body-parser": { 1267 | "version": "1.19.0", 1268 | "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", 1269 | "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", 1270 | "requires": { 1271 | "bytes": "3.1.0", 1272 | "content-type": "~1.0.4", 1273 | "debug": "2.6.9", 1274 | "depd": "~1.1.2", 1275 | "http-errors": "1.7.2", 1276 | "iconv-lite": "0.4.24", 1277 | "on-finished": "~2.3.0", 1278 | "qs": "6.7.0", 1279 | "raw-body": "2.4.0", 1280 | "type-is": "~1.6.17" 1281 | } 1282 | }, 1283 | "brace-expansion": { 1284 | "version": "1.1.11", 1285 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 1286 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 1287 | "dev": true, 1288 | "requires": { 1289 | "balanced-match": "^1.0.0", 1290 | "concat-map": "0.0.1" 1291 | } 1292 | }, 1293 | "braces": { 1294 | "version": "3.0.2", 1295 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", 1296 | "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", 1297 | "dev": true, 1298 | "requires": { 1299 | "fill-range": "^7.0.1" 1300 | } 1301 | }, 1302 | "buffer-from": { 1303 | "version": "1.1.2", 1304 | "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", 1305 | "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==", 1306 | "dev": true 1307 | }, 1308 | "bytes": { 1309 | "version": "3.1.0", 1310 | "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", 1311 | "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" 1312 | }, 1313 | "chokidar": { 1314 | "version": "3.5.2", 1315 | "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.2.tgz", 1316 | "integrity": "sha512-ekGhOnNVPgT77r4K/U3GDhu+FQ2S8TnK/s2KbIGXi0SZWuwkZ2QNyfWdZW+TVfn84DpEP7rLeCt2UI6bJ8GwbQ==", 1317 | "dev": true, 1318 | "requires": { 1319 | "anymatch": "~3.1.2", 1320 | "braces": "~3.0.2", 1321 | "fsevents": "~2.3.2", 1322 | "glob-parent": "~5.1.2", 1323 | "is-binary-path": "~2.1.0", 1324 | "is-glob": "~4.0.1", 1325 | "normalize-path": "~3.0.0", 1326 | "readdirp": "~3.6.0" 1327 | } 1328 | }, 1329 | "concat-map": { 1330 | "version": "0.0.1", 1331 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 1332 | "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", 1333 | "dev": true 1334 | }, 1335 | "content-disposition": { 1336 | "version": "0.5.3", 1337 | "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz", 1338 | "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==", 1339 | "requires": { 1340 | "safe-buffer": "5.1.2" 1341 | } 1342 | }, 1343 | "content-type": { 1344 | "version": "1.0.4", 1345 | "resolved": "https://registry.npmjs.org/content-type/-/content-type-1.0.4.tgz", 1346 | "integrity": "sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==" 1347 | }, 1348 | "cookie": { 1349 | "version": "0.4.0", 1350 | "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", 1351 | "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==" 1352 | }, 1353 | "cookie-signature": { 1354 | "version": "1.0.6", 1355 | "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.6.tgz", 1356 | "integrity": "sha1-4wOogrNCzD7oylE6eZmXNNqzriw=" 1357 | }, 1358 | "create-require": { 1359 | "version": "1.1.1", 1360 | "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", 1361 | "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", 1362 | "dev": true 1363 | }, 1364 | "debug": { 1365 | "version": "2.6.9", 1366 | "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", 1367 | "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", 1368 | "requires": { 1369 | "ms": "2.0.0" 1370 | } 1371 | }, 1372 | "depd": { 1373 | "version": "1.1.2", 1374 | "resolved": "https://registry.npmjs.org/depd/-/depd-1.1.2.tgz", 1375 | "integrity": "sha1-m81S4UwJd2PnSbJ0xDRu0uVgtak=" 1376 | }, 1377 | "destroy": { 1378 | "version": "1.0.4", 1379 | "resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.4.tgz", 1380 | "integrity": "sha1-l4hXRCxEdJ5CBmE+N5RiBYJqvYA=" 1381 | }, 1382 | "diff": { 1383 | "version": "4.0.2", 1384 | "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", 1385 | "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", 1386 | "dev": true 1387 | }, 1388 | "dynamic-dedupe": { 1389 | "version": "0.3.0", 1390 | "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", 1391 | "integrity": "sha1-BuRMIj9eTpTXjvnbI6ZRXOL5YqE=", 1392 | "dev": true, 1393 | "requires": { 1394 | "xtend": "^4.0.0" 1395 | } 1396 | }, 1397 | "ee-first": { 1398 | "version": "1.1.1", 1399 | "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", 1400 | "integrity": "sha1-WQxhFWsK4vTwJVcyoViyZrxWsh0=" 1401 | }, 1402 | "encodeurl": { 1403 | "version": "1.0.2", 1404 | "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", 1405 | "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=" 1406 | }, 1407 | "escape-html": { 1408 | "version": "1.0.3", 1409 | "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", 1410 | "integrity": "sha1-Aljq5NPQwJdN4cFpGI7wBR0dGYg=" 1411 | }, 1412 | "etag": { 1413 | "version": "1.8.1", 1414 | "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", 1415 | "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" 1416 | }, 1417 | "express": { 1418 | "version": "4.17.1", 1419 | "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz", 1420 | "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==", 1421 | "requires": { 1422 | "accepts": "~1.3.7", 1423 | "array-flatten": "1.1.1", 1424 | "body-parser": "1.19.0", 1425 | "content-disposition": "0.5.3", 1426 | "content-type": "~1.0.4", 1427 | "cookie": "0.4.0", 1428 | "cookie-signature": "1.0.6", 1429 | "debug": "2.6.9", 1430 | "depd": "~1.1.2", 1431 | "encodeurl": "~1.0.2", 1432 | "escape-html": "~1.0.3", 1433 | "etag": "~1.8.1", 1434 | "finalhandler": "~1.1.2", 1435 | "fresh": "0.5.2", 1436 | "merge-descriptors": "1.0.1", 1437 | "methods": "~1.1.2", 1438 | "on-finished": "~2.3.0", 1439 | "parseurl": "~1.3.3", 1440 | "path-to-regexp": "0.1.7", 1441 | "proxy-addr": "~2.0.5", 1442 | "qs": "6.7.0", 1443 | "range-parser": "~1.2.1", 1444 | "safe-buffer": "5.1.2", 1445 | "send": "0.17.1", 1446 | "serve-static": "1.14.1", 1447 | "setprototypeof": "1.1.1", 1448 | "statuses": "~1.5.0", 1449 | "type-is": "~1.6.18", 1450 | "utils-merge": "1.0.1", 1451 | "vary": "~1.1.2" 1452 | } 1453 | }, 1454 | "fill-range": { 1455 | "version": "7.0.1", 1456 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", 1457 | "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", 1458 | "dev": true, 1459 | "requires": { 1460 | "to-regex-range": "^5.0.1" 1461 | } 1462 | }, 1463 | "finalhandler": { 1464 | "version": "1.1.2", 1465 | "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", 1466 | "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", 1467 | "requires": { 1468 | "debug": "2.6.9", 1469 | "encodeurl": "~1.0.2", 1470 | "escape-html": "~1.0.3", 1471 | "on-finished": "~2.3.0", 1472 | "parseurl": "~1.3.3", 1473 | "statuses": "~1.5.0", 1474 | "unpipe": "~1.0.0" 1475 | } 1476 | }, 1477 | "forwarded": { 1478 | "version": "0.2.0", 1479 | "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", 1480 | "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==" 1481 | }, 1482 | "fresh": { 1483 | "version": "0.5.2", 1484 | "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", 1485 | "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" 1486 | }, 1487 | "fs.realpath": { 1488 | "version": "1.0.0", 1489 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 1490 | "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", 1491 | "dev": true 1492 | }, 1493 | "fsevents": { 1494 | "version": "2.3.2", 1495 | "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz", 1496 | "integrity": "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==", 1497 | "dev": true, 1498 | "optional": true 1499 | }, 1500 | "function-bind": { 1501 | "version": "1.1.1", 1502 | "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", 1503 | "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", 1504 | "dev": true 1505 | }, 1506 | "glob": { 1507 | "version": "7.1.7", 1508 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.1.7.tgz", 1509 | "integrity": "sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==", 1510 | "dev": true, 1511 | "requires": { 1512 | "fs.realpath": "^1.0.0", 1513 | "inflight": "^1.0.4", 1514 | "inherits": "2", 1515 | "minimatch": "^3.0.4", 1516 | "once": "^1.3.0", 1517 | "path-is-absolute": "^1.0.0" 1518 | } 1519 | }, 1520 | "glob-parent": { 1521 | "version": "5.1.2", 1522 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", 1523 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", 1524 | "dev": true, 1525 | "requires": { 1526 | "is-glob": "^4.0.1" 1527 | } 1528 | }, 1529 | "has": { 1530 | "version": "1.0.3", 1531 | "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", 1532 | "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", 1533 | "dev": true, 1534 | "requires": { 1535 | "function-bind": "^1.1.1" 1536 | } 1537 | }, 1538 | "http-errors": { 1539 | "version": "1.7.2", 1540 | "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", 1541 | "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", 1542 | "requires": { 1543 | "depd": "~1.1.2", 1544 | "inherits": "2.0.3", 1545 | "setprototypeof": "1.1.1", 1546 | "statuses": ">= 1.5.0 < 2", 1547 | "toidentifier": "1.0.0" 1548 | } 1549 | }, 1550 | "http-status-codes": { 1551 | "version": "2.1.4", 1552 | "resolved": "https://registry.npmjs.org/http-status-codes/-/http-status-codes-2.1.4.tgz", 1553 | "integrity": "sha512-MZVIsLKGVOVE1KEnldppe6Ij+vmemMuApDfjhVSLzyYP+td0bREEYyAoIw9yFePoBXManCuBqmiNP5FqJS5Xkg==" 1554 | }, 1555 | "iconv-lite": { 1556 | "version": "0.4.24", 1557 | "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", 1558 | "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", 1559 | "requires": { 1560 | "safer-buffer": ">= 2.1.2 < 3" 1561 | } 1562 | }, 1563 | "inflight": { 1564 | "version": "1.0.6", 1565 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 1566 | "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", 1567 | "dev": true, 1568 | "requires": { 1569 | "once": "^1.3.0", 1570 | "wrappy": "1" 1571 | } 1572 | }, 1573 | "inherits": { 1574 | "version": "2.0.3", 1575 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", 1576 | "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" 1577 | }, 1578 | "ipaddr.js": { 1579 | "version": "1.9.1", 1580 | "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", 1581 | "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==" 1582 | }, 1583 | "is-binary-path": { 1584 | "version": "2.1.0", 1585 | "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", 1586 | "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", 1587 | "dev": true, 1588 | "requires": { 1589 | "binary-extensions": "^2.0.0" 1590 | } 1591 | }, 1592 | "is-core-module": { 1593 | "version": "2.6.0", 1594 | "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.6.0.tgz", 1595 | "integrity": "sha512-wShG8vs60jKfPWpF2KZRaAtvt3a20OAn7+IJ6hLPECpSABLcKtFKTTI4ZtH5QcBruBHlq+WsdHWyz0BCZW7svQ==", 1596 | "dev": true, 1597 | "requires": { 1598 | "has": "^1.0.3" 1599 | } 1600 | }, 1601 | "is-extglob": { 1602 | "version": "2.1.1", 1603 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", 1604 | "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", 1605 | "dev": true 1606 | }, 1607 | "is-glob": { 1608 | "version": "4.0.1", 1609 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.1.tgz", 1610 | "integrity": "sha512-5G0tKtBTFImOqDnLB2hG6Bp2qcKEFduo4tZu9MT/H6NQv/ghhy30o55ufafxJ/LdH79LLs2Kfrn85TLKyA7BUg==", 1611 | "dev": true, 1612 | "requires": { 1613 | "is-extglob": "^2.1.1" 1614 | } 1615 | }, 1616 | "is-number": { 1617 | "version": "7.0.0", 1618 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", 1619 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", 1620 | "dev": true 1621 | }, 1622 | "make-error": { 1623 | "version": "1.3.6", 1624 | "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", 1625 | "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", 1626 | "dev": true 1627 | }, 1628 | "media-typer": { 1629 | "version": "0.3.0", 1630 | "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", 1631 | "integrity": "sha1-hxDXrwqmJvj/+hzgAWhUUmMlV0g=" 1632 | }, 1633 | "merge-descriptors": { 1634 | "version": "1.0.1", 1635 | "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", 1636 | "integrity": "sha1-sAqqVW3YtEVoFQ7J0blT8/kMu2E=" 1637 | }, 1638 | "methods": { 1639 | "version": "1.1.2", 1640 | "resolved": "https://registry.npmjs.org/methods/-/methods-1.1.2.tgz", 1641 | "integrity": "sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=" 1642 | }, 1643 | "mime": { 1644 | "version": "1.6.0", 1645 | "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", 1646 | "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" 1647 | }, 1648 | "mime-db": { 1649 | "version": "1.49.0", 1650 | "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.49.0.tgz", 1651 | "integrity": "sha512-CIc8j9URtOVApSFCQIF+VBkX1RwXp/oMMOrqdyXSBXq5RWNEsRfyj1kiRnQgmNXmHxPoFIxOroKA3zcU9P+nAA==" 1652 | }, 1653 | "mime-types": { 1654 | "version": "2.1.32", 1655 | "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.32.tgz", 1656 | "integrity": "sha512-hJGaVS4G4c9TSMYh2n6SQAGrC4RnfU+daP8G7cSCmaqNjiOoUY0VHCMS42pxnQmVF1GWwFhbHWn3RIxCqTmZ9A==", 1657 | "requires": { 1658 | "mime-db": "1.49.0" 1659 | } 1660 | }, 1661 | "minimatch": { 1662 | "version": "3.0.4", 1663 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.0.4.tgz", 1664 | "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", 1665 | "dev": true, 1666 | "requires": { 1667 | "brace-expansion": "^1.1.7" 1668 | } 1669 | }, 1670 | "minimist": { 1671 | "version": "1.2.5", 1672 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", 1673 | "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", 1674 | "dev": true 1675 | }, 1676 | "mkdirp": { 1677 | "version": "1.0.4", 1678 | "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-1.0.4.tgz", 1679 | "integrity": "sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==", 1680 | "dev": true 1681 | }, 1682 | "ms": { 1683 | "version": "2.0.0", 1684 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", 1685 | "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" 1686 | }, 1687 | "negotiator": { 1688 | "version": "0.6.2", 1689 | "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.6.2.tgz", 1690 | "integrity": "sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==" 1691 | }, 1692 | "normalize-path": { 1693 | "version": "3.0.0", 1694 | "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", 1695 | "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", 1696 | "dev": true 1697 | }, 1698 | "on-finished": { 1699 | "version": "2.3.0", 1700 | "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz", 1701 | "integrity": "sha1-IPEzZIGwg811M3mSoWlxqi2QaUc=", 1702 | "requires": { 1703 | "ee-first": "1.1.1" 1704 | } 1705 | }, 1706 | "once": { 1707 | "version": "1.4.0", 1708 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 1709 | "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", 1710 | "dev": true, 1711 | "requires": { 1712 | "wrappy": "1" 1713 | } 1714 | }, 1715 | "parseurl": { 1716 | "version": "1.3.3", 1717 | "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", 1718 | "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==" 1719 | }, 1720 | "path-is-absolute": { 1721 | "version": "1.0.1", 1722 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 1723 | "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", 1724 | "dev": true 1725 | }, 1726 | "path-parse": { 1727 | "version": "1.0.7", 1728 | "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", 1729 | "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==", 1730 | "dev": true 1731 | }, 1732 | "path-to-regexp": { 1733 | "version": "0.1.7", 1734 | "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.7.tgz", 1735 | "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=" 1736 | }, 1737 | "picomatch": { 1738 | "version": "2.3.0", 1739 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.0.tgz", 1740 | "integrity": "sha512-lY1Q/PiJGC2zOv/z391WOTD+Z02bCgsFfvxoXXf6h7kv9o+WmsmzYqrAwY63sNgOxE4xEdq0WyUnXfKeBrSvYw==", 1741 | "dev": true 1742 | }, 1743 | "proxy-addr": { 1744 | "version": "2.0.7", 1745 | "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.7.tgz", 1746 | "integrity": "sha512-llQsMLSUDUPT44jdrU/O37qlnifitDP+ZwrmmZcoSKyLKvtZxpyV0n2/bD/N4tBAAZ/gJEdZU7KMraoK1+XYAg==", 1747 | "requires": { 1748 | "forwarded": "0.2.0", 1749 | "ipaddr.js": "1.9.1" 1750 | } 1751 | }, 1752 | "qs": { 1753 | "version": "6.7.0", 1754 | "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", 1755 | "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" 1756 | }, 1757 | "range-parser": { 1758 | "version": "1.2.1", 1759 | "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", 1760 | "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" 1761 | }, 1762 | "raw-body": { 1763 | "version": "2.4.0", 1764 | "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz", 1765 | "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==", 1766 | "requires": { 1767 | "bytes": "3.1.0", 1768 | "http-errors": "1.7.2", 1769 | "iconv-lite": "0.4.24", 1770 | "unpipe": "1.0.0" 1771 | } 1772 | }, 1773 | "readdirp": { 1774 | "version": "3.6.0", 1775 | "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", 1776 | "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", 1777 | "dev": true, 1778 | "requires": { 1779 | "picomatch": "^2.2.1" 1780 | } 1781 | }, 1782 | "resolve": { 1783 | "version": "1.20.0", 1784 | "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.20.0.tgz", 1785 | "integrity": "sha512-wENBPt4ySzg4ybFQW2TT1zMQucPK95HSh/nq2CFTZVOGut2+pQvSsgtda4d26YrYcr067wjbmzOG8byDPBX63A==", 1786 | "dev": true, 1787 | "requires": { 1788 | "is-core-module": "^2.2.0", 1789 | "path-parse": "^1.0.6" 1790 | } 1791 | }, 1792 | "rimraf": { 1793 | "version": "2.7.1", 1794 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", 1795 | "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", 1796 | "dev": true, 1797 | "requires": { 1798 | "glob": "^7.1.3" 1799 | } 1800 | }, 1801 | "safe-buffer": { 1802 | "version": "5.1.2", 1803 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 1804 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" 1805 | }, 1806 | "safer-buffer": { 1807 | "version": "2.1.2", 1808 | "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", 1809 | "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" 1810 | }, 1811 | "send": { 1812 | "version": "0.17.1", 1813 | "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz", 1814 | "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==", 1815 | "requires": { 1816 | "debug": "2.6.9", 1817 | "depd": "~1.1.2", 1818 | "destroy": "~1.0.4", 1819 | "encodeurl": "~1.0.2", 1820 | "escape-html": "~1.0.3", 1821 | "etag": "~1.8.1", 1822 | "fresh": "0.5.2", 1823 | "http-errors": "~1.7.2", 1824 | "mime": "1.6.0", 1825 | "ms": "2.1.1", 1826 | "on-finished": "~2.3.0", 1827 | "range-parser": "~1.2.1", 1828 | "statuses": "~1.5.0" 1829 | }, 1830 | "dependencies": { 1831 | "ms": { 1832 | "version": "2.1.1", 1833 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", 1834 | "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" 1835 | } 1836 | } 1837 | }, 1838 | "serve-static": { 1839 | "version": "1.14.1", 1840 | "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz", 1841 | "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==", 1842 | "requires": { 1843 | "encodeurl": "~1.0.2", 1844 | "escape-html": "~1.0.3", 1845 | "parseurl": "~1.3.3", 1846 | "send": "0.17.1" 1847 | } 1848 | }, 1849 | "setprototypeof": { 1850 | "version": "1.1.1", 1851 | "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz", 1852 | "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==" 1853 | }, 1854 | "source-map": { 1855 | "version": "0.6.1", 1856 | "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", 1857 | "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", 1858 | "dev": true 1859 | }, 1860 | "source-map-support": { 1861 | "version": "0.5.19", 1862 | "resolved": "https://registry.npmjs.org/source-map-support/-/source-map-support-0.5.19.tgz", 1863 | "integrity": "sha512-Wonm7zOCIJzBGQdB+thsPar0kYuCIzYvxZwlBa87yi/Mdjv7Tip2cyVbLj5o0cFPN4EVkuTwb3GDDyUx2DGnGw==", 1864 | "dev": true, 1865 | "requires": { 1866 | "buffer-from": "^1.0.0", 1867 | "source-map": "^0.6.0" 1868 | } 1869 | }, 1870 | "statuses": { 1871 | "version": "1.5.0", 1872 | "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", 1873 | "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" 1874 | }, 1875 | "strip-bom": { 1876 | "version": "3.0.0", 1877 | "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz", 1878 | "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM=", 1879 | "dev": true 1880 | }, 1881 | "strip-json-comments": { 1882 | "version": "2.0.1", 1883 | "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", 1884 | "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", 1885 | "dev": true 1886 | }, 1887 | "to-regex-range": { 1888 | "version": "5.0.1", 1889 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", 1890 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", 1891 | "dev": true, 1892 | "requires": { 1893 | "is-number": "^7.0.0" 1894 | } 1895 | }, 1896 | "toidentifier": { 1897 | "version": "1.0.0", 1898 | "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", 1899 | "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" 1900 | }, 1901 | "tree-kill": { 1902 | "version": "1.2.2", 1903 | "resolved": "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz", 1904 | "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==", 1905 | "dev": true 1906 | }, 1907 | "ts-node": { 1908 | "version": "9.1.1", 1909 | "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-9.1.1.tgz", 1910 | "integrity": "sha512-hPlt7ZACERQGf03M253ytLY3dHbGNGrAq9qIHWUY9XHYl1z7wYngSr3OQ5xmui8o2AaxsONxIzjafLUiWBo1Fg==", 1911 | "dev": true, 1912 | "requires": { 1913 | "arg": "^4.1.0", 1914 | "create-require": "^1.1.0", 1915 | "diff": "^4.0.1", 1916 | "make-error": "^1.1.1", 1917 | "source-map-support": "^0.5.17", 1918 | "yn": "3.1.1" 1919 | } 1920 | }, 1921 | "ts-node-dev": { 1922 | "version": "1.1.8", 1923 | "resolved": "https://registry.npmjs.org/ts-node-dev/-/ts-node-dev-1.1.8.tgz", 1924 | "integrity": "sha512-Q/m3vEwzYwLZKmV6/0VlFxcZzVV/xcgOt+Tx/VjaaRHyiBcFlV0541yrT09QjzzCxlDZ34OzKjrFAynlmtflEg==", 1925 | "dev": true, 1926 | "requires": { 1927 | "chokidar": "^3.5.1", 1928 | "dynamic-dedupe": "^0.3.0", 1929 | "minimist": "^1.2.5", 1930 | "mkdirp": "^1.0.4", 1931 | "resolve": "^1.0.0", 1932 | "rimraf": "^2.6.1", 1933 | "source-map-support": "^0.5.12", 1934 | "tree-kill": "^1.2.2", 1935 | "ts-node": "^9.0.0", 1936 | "tsconfig": "^7.0.0" 1937 | } 1938 | }, 1939 | "tsconfig": { 1940 | "version": "7.0.0", 1941 | "resolved": "https://registry.npmjs.org/tsconfig/-/tsconfig-7.0.0.tgz", 1942 | "integrity": "sha512-vZXmzPrL+EmC4T/4rVlT2jNVMWCi/O4DIiSj3UHg1OE5kCKbk4mfrXc6dZksLgRM/TZlKnousKH9bbTazUWRRw==", 1943 | "dev": true, 1944 | "requires": { 1945 | "@types/strip-bom": "^3.0.0", 1946 | "@types/strip-json-comments": "0.0.30", 1947 | "strip-bom": "^3.0.0", 1948 | "strip-json-comments": "^2.0.0" 1949 | } 1950 | }, 1951 | "type-is": { 1952 | "version": "1.6.18", 1953 | "resolved": "https://registry.npmjs.org/type-is/-/type-is-1.6.18.tgz", 1954 | "integrity": "sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==", 1955 | "requires": { 1956 | "media-typer": "0.3.0", 1957 | "mime-types": "~2.1.24" 1958 | } 1959 | }, 1960 | "typescript": { 1961 | "version": "4.4.2", 1962 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.4.2.tgz", 1963 | "integrity": "sha512-gzP+t5W4hdy4c+68bfcv0t400HVJMMd2+H9B7gae1nQlBzCqvrXX+6GL/b3GAgyTH966pzrZ70/fRjwAtZksSQ==", 1964 | "dev": true 1965 | }, 1966 | "unpipe": { 1967 | "version": "1.0.0", 1968 | "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", 1969 | "integrity": "sha1-sr9O6FFKrmFltIF4KdIbLvSZBOw=" 1970 | }, 1971 | "utils-merge": { 1972 | "version": "1.0.1", 1973 | "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", 1974 | "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" 1975 | }, 1976 | "vary": { 1977 | "version": "1.1.2", 1978 | "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", 1979 | "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" 1980 | }, 1981 | "wrappy": { 1982 | "version": "1.0.2", 1983 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 1984 | "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", 1985 | "dev": true 1986 | }, 1987 | "xtend": { 1988 | "version": "4.0.2", 1989 | "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", 1990 | "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", 1991 | "dev": true 1992 | }, 1993 | "yn": { 1994 | "version": "3.1.1", 1995 | "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", 1996 | "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", 1997 | "dev": true 1998 | } 1999 | } 2000 | } 2001 | -------------------------------------------------------------------------------- /live-01/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ms-authentication", 3 | "version": "1.0.0", 4 | "description": "Microservice criado durante o live code com o pessoal da DIO", 5 | "main": "./dist/index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "start": "node ./", 9 | "build": "tsc -p .", 10 | "dev": "ts-node-dev --respawn --transpile-only --ignore-watch node_modules --no-notify src/index.ts" 11 | }, 12 | "author": "Renan J Paula", 13 | "license": "ISC", 14 | "devDependencies": { 15 | "@types/express": "^4.17.13", 16 | "@types/node": "^16.7.11", 17 | "ts-node-dev": "^1.1.8", 18 | "typescript": "^4.4.2" 19 | }, 20 | "dependencies": { 21 | "express": "^4.17.1", 22 | "http-status-codes": "^2.1.4" 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /live-01/src/index.ts: -------------------------------------------------------------------------------- 1 | 2 | import express from 'express'; 3 | import statusRoute from './routes/status.route'; 4 | import usersRoute from './routes/users.route'; 5 | 6 | const app = express(); 7 | 8 | // Configurações da aplicação 9 | app.use(express.json()); 10 | app.use(express.urlencoded({ extended: true })); 11 | 12 | // Configurações de Rotas 13 | app.use(statusRoute); 14 | app.use(usersRoute); 15 | 16 | // Inicialização do servidor 17 | app.listen(3000, () => { 18 | console.log('Aplicação executando na porta 3000!'); 19 | }); 20 | -------------------------------------------------------------------------------- /live-01/src/routes/status.route.ts: -------------------------------------------------------------------------------- 1 | 2 | import { Router, Request, Response, NextFunction } from 'express'; 3 | import { StatusCodes } from 'http-status-codes'; 4 | 5 | const statusRoute = Router(); 6 | 7 | statusRoute.get('/status', (req: Request, res: Response, next: NextFunction) => { 8 | res.sendStatus(StatusCodes.OK); 9 | }); 10 | 11 | export default statusRoute; 12 | -------------------------------------------------------------------------------- /live-01/src/routes/users.route.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response, Router } from 'express'; 2 | import { StatusCodes } from 'http-status-codes'; 3 | 4 | const usersRoute = Router(); 5 | 6 | usersRoute.get('/users', (req: Request, res: Response, next: NextFunction) => { 7 | const users = [{ userName: 'Renan' }]; 8 | res.status(StatusCodes.OK).send(users); 9 | }); 10 | 11 | usersRoute.get('/users/:uuid', (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 12 | const uuid = req.params.uuid; 13 | res.status(StatusCodes.OK).send({ uuid }); 14 | }); 15 | 16 | usersRoute.post('/users', (req: Request, res: Response, next: NextFunction) => { 17 | const newUser = req.body; 18 | res.status(StatusCodes.CREATED).send(newUser); 19 | }); 20 | 21 | usersRoute.put('/users/:uuid', (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 22 | const uuid = req.params.uuid; 23 | const modifiedUser = req.body; 24 | 25 | modifiedUser.uuid = uuid; 26 | 27 | res.status(StatusCodes.OK).send(modifiedUser); 28 | }); 29 | 30 | usersRoute.delete('/users/:uuid', (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 31 | res.sendStatus(StatusCodes.OK); 32 | }); 33 | 34 | export default usersRoute; 35 | -------------------------------------------------------------------------------- /live-01/tsconfig.json: -------------------------------------------------------------------------------- 1 | /* Visit https://aka.ms/tsconfig.json to read more about this file */ 2 | { 3 | "compilerOptions": { 4 | "target": "es2019", 5 | "module": "commonjs", 6 | "moduleResolution": "node", 7 | "rootDir": "src", 8 | "typeRoots": [ 9 | "./src/@types", 10 | "./node_modules/@types" 11 | ], 12 | "outDir": "./dist", 13 | "removeComments": true, 14 | "esModuleInterop": true, 15 | "forceConsistentCasingInFileNames": true, 16 | "strict": true, 17 | "skipLibCheck": true 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /live-02/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist -------------------------------------------------------------------------------- /live-02/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ms-authentication", 3 | "version": "1.0.0", 4 | "description": "Microservice criado durante o live code com o pessoal da DIO", 5 | "main": "./dist/index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "start": "node ./", 9 | "build": "tsc -p .", 10 | "dev": "ts-node-dev --respawn --transpile-only --ignore-watch node_modules --no-notify src/index.ts" 11 | }, 12 | "author": "Renan J Paula", 13 | "license": "ISC", 14 | "devDependencies": { 15 | "@types/express": "^4.17.13", 16 | "@types/node": "^16.7.11", 17 | "@types/pg": "^8.6.1", 18 | "ts-node-dev": "^1.1.8", 19 | "typescript": "^4.4.2" 20 | }, 21 | "dependencies": { 22 | "express": "^4.17.1", 23 | "http-status-codes": "^2.1.4", 24 | "pg": "^8.7.1" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /live-02/sql/init.sql: -------------------------------------------------------------------------------- 1 | CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; 2 | CREATE EXTENSION IF NOT EXISTS "pgcrypto"; 3 | 4 | CREATE TABLE IF NOT EXISTS application_user( 5 | uuid uuid DEFAULT uuid_generate_v4(), 6 | username VARCHAR NOT NULL, 7 | password VARCHAR NOT NULL, 8 | PRIMARY KEY (uuid) 9 | ); 10 | 11 | INSERT INTO application_user (username, password) VALUES ('renan', crypt('admin', 'my_salt')); 12 | -------------------------------------------------------------------------------- /live-02/src/db.ts: -------------------------------------------------------------------------------- 1 | import { Pool } from 'pg'; 2 | 3 | const connectionString = ''; 4 | 5 | const db = new Pool({ connectionString }); 6 | 7 | export default db; 8 | -------------------------------------------------------------------------------- /live-02/src/index.ts: -------------------------------------------------------------------------------- 1 | 2 | import express from 'express'; 3 | import errorHandler from './middlewares/error-handler.middleware'; 4 | import statusRoute from './routes/status.route'; 5 | import usersRoute from './routes/users.route'; 6 | 7 | const app = express(); 8 | 9 | // Configurações da aplicação 10 | app.use(express.json()); 11 | app.use(express.urlencoded({ extended: true })); 12 | 13 | // Configurações de Rotas 14 | app.use(statusRoute); 15 | app.use(usersRoute); 16 | 17 | // Configuração dos Handlers de Erro 18 | app.use(errorHandler); 19 | 20 | // Inicialização do servidor 21 | app.listen(3000, () => { 22 | console.log('Aplicação executando na porta 3000!'); 23 | }); 24 | -------------------------------------------------------------------------------- /live-02/src/middlewares/error-handler.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from "express"; 2 | import { StatusCodes } from "http-status-codes"; 3 | import DatabaseError from "../models/errors/database.error.model"; 4 | 5 | function errorHandler(error: any, req: Request, res: Response, next: NextFunction) { 6 | if (error instanceof DatabaseError) { 7 | res.sendStatus(StatusCodes.BAD_REQUEST); 8 | } else { 9 | res.sendStatus(StatusCodes.INTERNAL_SERVER_ERROR); 10 | } 11 | } 12 | 13 | export default errorHandler; -------------------------------------------------------------------------------- /live-02/src/models/errors/database.error.model.ts: -------------------------------------------------------------------------------- 1 | 2 | class DatabaseError extends Error { 3 | 4 | constructor( 5 | public message: string, 6 | public error?: any, 7 | ) { 8 | super(message); 9 | } 10 | 11 | } 12 | 13 | export default DatabaseError; 14 | -------------------------------------------------------------------------------- /live-02/src/models/user.model.ts: -------------------------------------------------------------------------------- 1 | 2 | type User = { 3 | uuid?: string; 4 | username: string; 5 | password?: string; 6 | } 7 | 8 | export default User; 9 | -------------------------------------------------------------------------------- /live-02/src/repositories/user.repository.ts: -------------------------------------------------------------------------------- 1 | import db from '../db'; 2 | import User from '../models/user.model'; 3 | import DatabaseError from '../models/errors/database.error.model'; 4 | 5 | class UserRepository { 6 | 7 | async findAllUsers(): Promise { 8 | const query = ` 9 | SELECT uuid, username 10 | FROM application_user 11 | `; 12 | 13 | const { rows } = await db.query(query); 14 | return rows || []; 15 | } 16 | 17 | async findById(uuid: string): Promise { 18 | try { 19 | const query = ` 20 | SELECT uuid, username 21 | FROM application_user 22 | WHERE uuid = $1 23 | `; 24 | 25 | const values = [uuid]; 26 | 27 | const { rows } = await db.query(query, values); 28 | const [user] = rows; 29 | 30 | return user; 31 | } catch (error) { 32 | throw new DatabaseError('Erro na consulta por ID', error); 33 | } 34 | } 35 | 36 | async create(user: User): Promise { 37 | const script = ` 38 | INSERT INTO application_user ( 39 | username, 40 | password 41 | ) 42 | VALUES ($1, crypt($2, 'my_salt')) 43 | RETURNING uuid 44 | `; 45 | 46 | const values = [user.username, user.password]; 47 | 48 | const { rows } = await db.query<{ uuid: string }>(script, values); 49 | const [newUser] = rows; 50 | return newUser.uuid; 51 | } 52 | 53 | async update(user: User): Promise { 54 | const script = ` 55 | UPDATE application_user 56 | SET 57 | username = $1, 58 | password = crypt($2, 'my_salt') 59 | WHERE uuid = $3 60 | `; 61 | 62 | const values = [user.username, user.password, user.uuid]; 63 | await db.query(script, values); 64 | } 65 | 66 | async remove(uuid: string): Promise { 67 | const cript = ` 68 | DELETE 69 | FROM application_user 70 | WHERE uuid = $1 71 | `; 72 | const values = [uuid]; 73 | await db.query(cript, values); 74 | } 75 | 76 | } 77 | 78 | export default new UserRepository(); 79 | -------------------------------------------------------------------------------- /live-02/src/routes/status.route.ts: -------------------------------------------------------------------------------- 1 | 2 | import { Router, Request, Response, NextFunction } from 'express'; 3 | import { StatusCodes } from 'http-status-codes'; 4 | 5 | const statusRoute = Router(); 6 | 7 | statusRoute.get('/status', (req: Request, res: Response, next: NextFunction) => { 8 | res.sendStatus(StatusCodes.OK); 9 | }); 10 | 11 | export default statusRoute; 12 | -------------------------------------------------------------------------------- /live-02/src/routes/users.route.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response, Router } from 'express'; 2 | import { StatusCodes } from 'http-status-codes'; 3 | import DatabaseError from '../models/errors/database.error.model'; 4 | import userRepository from '../repositories/user.repository'; 5 | 6 | const usersRoute = Router(); 7 | 8 | usersRoute.get('/users', async (req: Request, res: Response, next: NextFunction) => { 9 | const users = await userRepository.findAllUsers(); 10 | res.status(StatusCodes.OK).send(users); 11 | }); 12 | 13 | usersRoute.get('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 14 | try { 15 | const uuid = req.params.uuid; 16 | const user = await userRepository.findById(uuid); 17 | res.status(StatusCodes.OK).send(user); 18 | } catch (error) { 19 | next(error); 20 | } 21 | }); 22 | 23 | usersRoute.post('/users', async (req: Request, res: Response, next: NextFunction) => { 24 | const newUser = req.body; 25 | const uuid = await userRepository.create(newUser); 26 | res.status(StatusCodes.CREATED).send(uuid); 27 | }); 28 | 29 | usersRoute.put('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 30 | const uuid = req.params.uuid; 31 | const modifiedUser = req.body; 32 | 33 | modifiedUser.uuid = uuid; 34 | 35 | await userRepository.update(modifiedUser); 36 | 37 | res.status(StatusCodes.OK).send(); 38 | }); 39 | 40 | usersRoute.delete('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 41 | const uuid = req.params.uuid; 42 | await userRepository.remove(uuid); 43 | res.sendStatus(StatusCodes.OK); 44 | }); 45 | 46 | export default usersRoute; 47 | -------------------------------------------------------------------------------- /live-02/tsconfig.json: -------------------------------------------------------------------------------- 1 | /* Visit https://aka.ms/tsconfig.json to read more about this file */ 2 | { 3 | "compilerOptions": { 4 | "target": "es2019", 5 | "module": "commonjs", 6 | "moduleResolution": "node", 7 | "rootDir": "src", 8 | "typeRoots": [ 9 | "./src/@types", 10 | "./node_modules/@types" 11 | ], 12 | "outDir": "./dist", 13 | "removeComments": true, 14 | "esModuleInterop": true, 15 | "forceConsistentCasingInFileNames": true, 16 | "strict": true, 17 | "skipLibCheck": true 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /live-03/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist -------------------------------------------------------------------------------- /live-03/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ms-authentication", 3 | "version": "1.0.0", 4 | "description": "Microservice criado durante o live code com o pessoal da DIO", 5 | "main": "./dist/index.js", 6 | "scripts": { 7 | "test": "echo \"Error: no test specified\" && exit 1", 8 | "start": "node ./", 9 | "build": "tsc -p .", 10 | "dev": "ts-node-dev --respawn --transpile-only --ignore-watch node_modules --no-notify src/index.ts" 11 | }, 12 | "author": "Renan J Paula", 13 | "license": "ISC", 14 | "devDependencies": { 15 | "@types/express": "^4.17.13", 16 | "@types/jsonwebtoken": "^8.5.5", 17 | "@types/node": "^16.7.11", 18 | "@types/pg": "^8.6.1", 19 | "ts-node-dev": "^1.1.8", 20 | "typescript": "^4.4.2" 21 | }, 22 | "dependencies": { 23 | "express": "^4.17.1", 24 | "http-status-codes": "^2.1.4", 25 | "jsonwebtoken": "^8.5.1", 26 | "pg": "^8.7.1" 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /live-03/sql/init.sql: -------------------------------------------------------------------------------- 1 | CREATE EXTENSION IF NOT EXISTS "uuid-ossp"; 2 | CREATE EXTENSION IF NOT EXISTS "pgcrypto"; 3 | 4 | CREATE TABLE IF NOT EXISTS application_user( 5 | uuid uuid DEFAULT uuid_generate_v4(), 6 | username VARCHAR NOT NULL, 7 | password VARCHAR NOT NULL, 8 | PRIMARY KEY (uuid) 9 | ); 10 | 11 | INSERT INTO application_user (username, password) VALUES ('renan', crypt('admin', 'my_salt')); 12 | -------------------------------------------------------------------------------- /live-03/src/@types/express.d.ts: -------------------------------------------------------------------------------- 1 | import { User } from '../models/user.model'; 2 | 3 | declare module 'express-serve-static-core' { 4 | 5 | interface Request { 6 | user?: User 7 | } 8 | 9 | } 10 | -------------------------------------------------------------------------------- /live-03/src/db.ts: -------------------------------------------------------------------------------- 1 | import { Pool } from 'pg'; 2 | 3 | const connectionString = 'postgres://jmcnebnv:wYIxVJfUARnSYojuaDgr2-rSKXVGeB-n@kesavan.db.elephantsql.com/jmcnebnv'; 4 | 5 | const db = new Pool({ connectionString }); 6 | 7 | export default db; 8 | -------------------------------------------------------------------------------- /live-03/src/index.ts: -------------------------------------------------------------------------------- 1 | 2 | import express from 'express'; 3 | import errorHandler from './middlewares/error-handler.middleware'; 4 | import authorizationRoute from './routes/authorization.route'; 5 | import statusRoute from './routes/status.route'; 6 | import usersRoute from './routes/users.route'; 7 | 8 | const app = express(); 9 | 10 | // Configurações da aplicação 11 | app.use(express.json()); 12 | app.use(express.urlencoded({ extended: true })); 13 | 14 | // Configurações de Rotas 15 | app.use(statusRoute); 16 | app.use(usersRoute); 17 | app.use(authorizationRoute); 18 | 19 | // Configuração dos Handlers de Erro 20 | app.use(errorHandler); 21 | 22 | // Inicialização do servidor 23 | app.listen(3000, () => { 24 | console.log('Aplicação executando na porta 3000!'); 25 | }); 26 | -------------------------------------------------------------------------------- /live-03/src/middlewares/basic-authentication.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from "express"; 2 | import ForbiddenError from "../models/errors/forbidden.error.model"; 3 | import userRepository from "../repositories/user.repository"; 4 | 5 | async function basicAuthenticationMiddleware(req: Request, res: Response, next: NextFunction) { 6 | try { 7 | const authorizationHeader = req.headers['authorization']; 8 | 9 | if (!authorizationHeader) { 10 | throw new ForbiddenError('Credenciais não informadas'); 11 | } 12 | 13 | const [authenticationType, token] = authorizationHeader.split(' '); 14 | 15 | if (authenticationType !== 'Basic' || !token) { 16 | throw new ForbiddenError('Tipo de authenticação inválido'); 17 | } 18 | 19 | const tokenContent = Buffer.from(token, 'base64').toString('utf-8'); 20 | 21 | const [username, password] = tokenContent.split(':'); 22 | 23 | if (!username || !password) { 24 | throw new ForbiddenError('Credenciais não preenchidas'); 25 | } 26 | 27 | const user = await userRepository.findByUsernameAndPassword(username, password); 28 | 29 | if (!user) { 30 | throw new ForbiddenError('Usuário ou senha inválidos!'); 31 | } 32 | 33 | req.user = user; 34 | next(); 35 | } catch (error) { 36 | next(error); 37 | } 38 | } 39 | 40 | export default basicAuthenticationMiddleware; 41 | -------------------------------------------------------------------------------- /live-03/src/middlewares/error-handler.middleware.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response } from "express"; 2 | import { StatusCodes } from "http-status-codes"; 3 | import DatabaseError from "../models/errors/database.error.model"; 4 | import ForbiddenError from "../models/errors/forbidden.error.model"; 5 | 6 | function errorHandler(error: any, req: Request, res: Response, next: NextFunction) { 7 | if (error instanceof DatabaseError) { 8 | res.sendStatus(StatusCodes.BAD_REQUEST); 9 | } else if (error instanceof ForbiddenError) { 10 | res.sendStatus(StatusCodes.FORBIDDEN); 11 | } else { 12 | res.sendStatus(StatusCodes.INTERNAL_SERVER_ERROR); 13 | } 14 | } 15 | 16 | export default errorHandler; -------------------------------------------------------------------------------- /live-03/src/models/errors/database.error.model.ts: -------------------------------------------------------------------------------- 1 | 2 | class DatabaseError extends Error { 3 | 4 | constructor( 5 | public message: string, 6 | public error?: any, 7 | ) { 8 | super(message); 9 | } 10 | 11 | } 12 | 13 | export default DatabaseError; 14 | -------------------------------------------------------------------------------- /live-03/src/models/errors/forbidden.error.model.ts: -------------------------------------------------------------------------------- 1 | 2 | export default class ForbiddenError extends Error { 3 | constructor( 4 | public message: string, 5 | public error?: any, 6 | ) { 7 | super(message); 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /live-03/src/models/user.model.ts: -------------------------------------------------------------------------------- 1 | 2 | type User = { 3 | uuid?: string; 4 | username: string; 5 | password?: string; 6 | } 7 | 8 | export default User; 9 | -------------------------------------------------------------------------------- /live-03/src/repositories/user.repository.ts: -------------------------------------------------------------------------------- 1 | import db from '../db'; 2 | import DatabaseError from '../models/errors/database.error.model'; 3 | import User from '../models/user.model'; 4 | 5 | class UserRepository { 6 | 7 | async findAllUsers(): Promise { 8 | const query = ` 9 | SELECT uuid, username 10 | FROM application_user 11 | `; 12 | 13 | const { rows } = await db.query(query); 14 | return rows || []; 15 | } 16 | 17 | async findById(uuid: string): Promise { 18 | try { 19 | const query = ` 20 | SELECT uuid, username 21 | FROM application_user 22 | WHERE uuid = $1 23 | `; 24 | 25 | const values = [uuid]; 26 | 27 | const { rows } = await db.query(query, values); 28 | const [user] = rows; 29 | 30 | return user; 31 | } catch (error) { 32 | throw new DatabaseError('Erro na consulta por ID', error); 33 | } 34 | } 35 | 36 | async findByUsernameAndPassword(username: string, password: string): Promise { 37 | try { 38 | const query = ` 39 | SELECT uuid, username 40 | FROM application_user 41 | WHERE username = $1 42 | AND password = crypt($2, 'my_salt') 43 | `; 44 | const values = [username, password]; 45 | const { rows } = await db.query(query, values); 46 | const [user] = rows; 47 | return user || null; 48 | } catch (error) { 49 | throw new DatabaseError('Erro na consulta por username e password', error); 50 | } 51 | } 52 | 53 | async create(user: User): Promise { 54 | const script = ` 55 | INSERT INTO application_user ( 56 | username, 57 | password 58 | ) 59 | VALUES ($1, crypt($2, 'my_salt')) 60 | RETURNING uuid 61 | `; 62 | 63 | const values = [user.username, user.password]; 64 | 65 | const { rows } = await db.query<{ uuid: string }>(script, values); 66 | const [newUser] = rows; 67 | return newUser.uuid; 68 | } 69 | 70 | async update(user: User): Promise { 71 | const script = ` 72 | UPDATE application_user 73 | SET 74 | username = $1, 75 | password = crypt($2, 'my_salt') 76 | WHERE uuid = $3 77 | `; 78 | 79 | const values = [user.username, user.password, user.uuid]; 80 | await db.query(script, values); 81 | } 82 | 83 | async remove(uuid: string): Promise { 84 | const cript = ` 85 | DELETE 86 | FROM application_user 87 | WHERE uuid = $1 88 | `; 89 | const values = [uuid]; 90 | await db.query(cript, values); 91 | } 92 | 93 | } 94 | 95 | export default new UserRepository(); 96 | -------------------------------------------------------------------------------- /live-03/src/routes/authorization.route.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response, Router } from 'express'; 2 | import { StatusCodes } from 'http-status-codes'; 3 | import JWT from 'jsonwebtoken'; 4 | import basicAuthenticationMiddleware from '../middlewares/basic-authentication.middleware'; 5 | import ForbiddenError from '../models/errors/forbidden.error.model'; 6 | 7 | const authorizationRoute = Router(); 8 | 9 | authorizationRoute.post('/token', basicAuthenticationMiddleware, async (req: Request, res: Response, next: NextFunction) => { 10 | try { 11 | const user = req.user; 12 | 13 | if (!user) { 14 | throw new ForbiddenError('Usuário não informado!'); 15 | } 16 | 17 | const jwtPayload = { username: user.username }; 18 | const jwtOptions = { subject: user?.uuid }; 19 | const secretKey = 'my_secret_key'; 20 | 21 | const jwt = JWT.sign(jwtPayload, secretKey, jwtOptions); 22 | 23 | res.status(StatusCodes.OK).json({ token: jwt }); 24 | } catch (error) { 25 | next(error); 26 | } 27 | }); 28 | 29 | 30 | export default authorizationRoute; 31 | -------------------------------------------------------------------------------- /live-03/src/routes/status.route.ts: -------------------------------------------------------------------------------- 1 | 2 | import { Router, Request, Response, NextFunction } from 'express'; 3 | import { StatusCodes } from 'http-status-codes'; 4 | 5 | const statusRoute = Router(); 6 | 7 | statusRoute.get('/status', (req: Request, res: Response, next: NextFunction) => { 8 | res.sendStatus(StatusCodes.OK); 9 | }); 10 | 11 | export default statusRoute; 12 | -------------------------------------------------------------------------------- /live-03/src/routes/users.route.ts: -------------------------------------------------------------------------------- 1 | import { NextFunction, Request, Response, Router } from 'express'; 2 | import { StatusCodes } from 'http-status-codes'; 3 | import userRepository from '../repositories/user.repository'; 4 | 5 | const usersRoute = Router(); 6 | 7 | usersRoute.get('/users', async (req: Request, res: Response, next: NextFunction) => { 8 | 9 | console.log(req.headers['authorization']); 10 | 11 | const users = await userRepository.findAllUsers(); 12 | res.status(StatusCodes.OK).send(users); 13 | }); 14 | 15 | usersRoute.get('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 16 | try { 17 | const uuid = req.params.uuid; 18 | const user = await userRepository.findById(uuid); 19 | res.status(StatusCodes.OK).send(user); 20 | } catch (error) { 21 | next(error); 22 | } 23 | }); 24 | 25 | usersRoute.post('/users', async (req: Request, res: Response, next: NextFunction) => { 26 | const newUser = req.body; 27 | const uuid = await userRepository.create(newUser); 28 | res.status(StatusCodes.CREATED).send(uuid); 29 | }); 30 | 31 | usersRoute.put('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 32 | const uuid = req.params.uuid; 33 | const modifiedUser = req.body; 34 | 35 | modifiedUser.uuid = uuid; 36 | 37 | await userRepository.update(modifiedUser); 38 | 39 | res.status(StatusCodes.OK).send(); 40 | }); 41 | 42 | usersRoute.delete('/users/:uuid', async (req: Request<{ uuid: string }>, res: Response, next: NextFunction) => { 43 | const uuid = req.params.uuid; 44 | await userRepository.remove(uuid); 45 | res.sendStatus(StatusCodes.OK); 46 | }); 47 | 48 | export default usersRoute; 49 | -------------------------------------------------------------------------------- /live-03/tsconfig.json: -------------------------------------------------------------------------------- 1 | /* Visit https://aka.ms/tsconfig.json to read more about this file */ 2 | { 3 | "compilerOptions": { 4 | "target": "es2019", 5 | "module": "commonjs", 6 | "moduleResolution": "node", 7 | "rootDir": "src", 8 | "typeRoots": [ 9 | "./src/@types", 10 | "./node_modules/@types" 11 | ], 12 | "outDir": "./dist", 13 | "removeComments": true, 14 | "esModuleInterop": true, 15 | "forceConsistentCasingInFileNames": true, 16 | "strict": true, 17 | "skipLibCheck": true 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | # Microserviço de autenticação com Nodejs 2 | 3 | Este é um projeto desenvolvido durante algumas lives para dissiminação de conhecimento dentro da [DIO](https://digitalinnovation.one/), uma plataforma de cursos gratuíta que todo DEV deveria conhecer! :wink: 4 | 5 | Neste projeto iremos criar um **microserviço de autenticação** que poderá compor a sua caixinha de ferramentas e ser muito útil no seu dia a dia. :hammer::wrench: 6 | 7 | ## Composição do nosso projeto 8 | 9 | Neste projeto Temos alguns **Endpoints Base** que podem ser extendidos da forma mais adequada para seu contexto. 10 | 11 | São eles: 12 | 13 | ### Usuários 14 | 15 | * GET /users 16 | * GET /users/:uuid 17 | * POST /users 18 | * PUT /users/:uuid 19 | * DELETE /users/:uuid 20 | 21 | ### Autenticação 22 | 23 | * POST /token 24 | * POST /token/validate 25 | 26 | ## Links úteis 27 | 28 | [Link](https://docs.google.com/presentation/d/1xcmu1IRAfPiWWEB6Y93ioVhup1McR3VY/edit?usp=sharing&ouid=111532941625525152923&rtpof=true&sd=true) para os slides utilizados dutante a live. 29 | --------------------------------------------------------------------------------