diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 76d23fe2ab51eefc7f6efcca77f5ce6274c26c96..362208a8c378384c58b7306bbc16b054a8c01943 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,6 +1,7 @@ -pages-devel: +pages-testing: stage: deploy script: + - cat $configfiledev > ./config/config.js - npm install - "pm2 delete --silent project || :" - pm2 start ./app.js --name=project @@ -10,9 +11,10 @@ pages-devel: only: - testing -pages-devel: +pages-production: stage: deploy script: + - cat $configfiledev > ./config/config.js - npm install - "pm2 delete --silent project || :" - pm2 start ./app.js --name=project diff --git a/app.js b/app.js index 762def574263678d14a3eb6155081b7e8e90085f..e7eeac48e3530e0d1a2e90dd208dc6cb74d01fc9 100644 --- a/app.js +++ b/app.js @@ -7,6 +7,8 @@ const bodyParser = require('body-parser') const session = require('express-session') const flash = require('express-flash') const fileUpload = require('express-fileupload') +const helmet = require('helmet') +const compression = require('compression') var env = process.env.NODE_ENV || 'testing' const config = require('./config/config')[env] @@ -15,13 +17,15 @@ var app = express() app.set('port', config.app.port) app.set('views', __dirname + '/views') -app.set('view engine', 'pug') +app.set('view engine', 'pug') + +app.use(helmet()) +app.use(compression()) app.use(morgan('combined')) app.use(cookieParser()) app.use(bodyParser.json()) app.use(bodyParser.urlencoded({extended: false})) app.use(express.static(path.join(__dirname, 'public'))) - app.use(session( { resave: true, @@ -29,10 +33,8 @@ app.use(session( secret: 'thisisasecret-thisisasecret-thisisasecret' } )) - app.use(passport.initialize()) app.use(passport.session()) - app.use(flash()) app.use((req, res, next) => { res.locals.errors = req.flash("error") @@ -46,7 +48,6 @@ app.use(fileUpload({ fileSize: 1000000 // 1 MB max. file size } })) - // caching disabled for every route // NOTE: Works in Firefox and Opera. Does not work in Edge app.use(function(req, res, next) { diff --git a/config/cert/cert.pem b/config/cert/cert.pem deleted file mode 100644 index 27ec0517deecd66be5fb8cf81e3e030d65958e7b..0000000000000000000000000000000000000000 --- a/config/cert/cert.pem +++ /dev/null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m9Froq7RB9z38 -dYbOQrrvvVVdKyxV1X+gXc/osOJeqeVsDLBbAcdw14oGFp8ydyMnRI7YNq6LHu7q -Nf8wbERInTd8VTjLvQ0XlMGHhNveqD3MLN5KOvlL5o4m/TzCGrGAmuQ+hbUd6L/a -vEMtMQIDAQABo1MwUTAdBgNVHQ4EFgQUkAaHOiBMs03JOGMj0LDDhhuJnKowHwYD -VR0jBBgwFoAUkAaHOiBMs03JOGMj0LDDhhuJnKowDwYDVR0TAQH/BAUwAwEB/zAN -BgkqhkiG9w0BAQsFAAOCAgEAa+Y879QnGd9Sd9YdjcpI6QYxJ4xvvVIY1WNncwjj -OTPhhlQIhf8krUfSb2logIZQhQuMvBW/oZ3BoLQ18x6gDoAGIlcbBsikRRsltCKG -z8Yn8HqGJROGyuB7vz5UZXos0OFPOSkC7VDF0DYaauCJlpn4MUI6o+PFtibflWQS -jSxGpV3b8MPQuiu4dxgmS2tqcFWhyUFoaMz3BZ4BGnAcTWxVuXqcRcp6C9F8a7pk -QI6n39mofChYuCD0OJQAoqrQHPZ77j/SI9GpX4U1qZJ5b8+bxWHoJ5frfGkXYWRM -bojAD9r8oEdYhOq/bSo4pn8TyEwTdQlNSRni3ZkfnOER91CDEJNORJWnY0WM6OZI -+iRQ0xLRcYNXuNxKhBfn1jHnY8EyphsZGPMkJiEarcE35jd9b8uPp5TLazy4TH2p -RisDYT45Q3Q4Z48/Ele5uQej+twOCZRKXDLBnsvom4ee6f6v4kVvB9Oxax2nghYO -rGIFXr6Khrx7JWCOiaF7/CzUdmUf8ieNqEWo8D0l2BqiUunUDZZuLd11X8cvTvqd -nvXPvLcIfgMJX9iLUDZxodb+2SGIlO4qnZ0ItSaYSAN58PJ/STpyV6IGlo8DfK// -kP6e28NsztY1/o01lAT7ymksvAkz4UB7v47u4CXyxioW/RP1R8MR5zT8c1GUpqJo -uno= ------END CERTIFICATE----- diff --git a/config/cert/cert_idp.pem b/config/cert/cert_idp.pem deleted file mode 100644 index 66211789a5bfd4b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gQUBiJg3KXaFUobk3xkDsueM4w7jrowHwYDVR0jBBgwFoAUBiJg3KXaFUobk3xkDsueM4w7jrowDAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQsFAAOCAQEAONBKzgy1b5/x0ijp7wZ3i/xlAOZ2Dy702lmsuyhSuQs+1xWFKgb0LkkNziZrq+xa2vAkEoMmqnqxze3VsAT0vek3x4uOo/ejJmxneGzTKMhAF0d/oIpjgJnxwyvF2w7SQNO8ggPNnrVd17+tX3MUb46amljSQnip7vA6Xl6ur5/pUuD2OPP6EQB3ExLB9CZkWSHXR2A7N6Di6PCuLXMPsw3MwXL3tuE2lEKUDjA8WV7NDvfXkFOTzqZZUO9LJ+NLDbnQ/GlkrYQfq3B0bPNXJtVUzSkpkxl8/gogRlvQbXxi+ZOn69yqMFghRcIsw0px0ds9m8wefwypz+O4DEHnrw== \ No newline at end of file diff --git a/config/cert/key.pem b/config/cert/key.pem deleted file mode 100644 index 51b5e9d526bea3737258a92d46ac60326b7b458f..0000000000000000000000000000000000000000 --- a/config/cert/key.pem +++ /dev/null @@ -1,52 +0,0 @@ ------BEGIN PRIVATE KEY----- -MIIJQQIBADANBgkqhkiG9w0BAQEFAASCCSswggknAgEAAoICAQDItceFnc0CMD3t -hIyRlGHoeaEOD6Zqxnso6DMGNrMxZxTDwrDouIEsL7aBMksgrlYSBb98nCOHmy3b -zreZ2qSalbxlnudLNWGVNhzHJmzhLbvOLVUPDVsMzNb7Yi/3Q95gEhRwCy/uOQ4x -lOChLn+maamtOZI1pRU7sRlpFAV34VTcfvxCzHPjy6cpUvkco6MBTuAx6zfXmeAh -ZR7PzDekU8aMvQVNIF2HzMHwIDShQsCemXgvQsRplc2+p3CY9IzGSvsXtLc7WJnS -weYuGnTj2W/NHDOihzmNcMa8wIloDqw0mxhTJUSn2PalxO5h8RDCLWWzuIyhAm1T -bb7SRn7wfLZEtXC7juiZTZKQniGF3Zh9Aotjj9Muq0I4oYSJRKR/DqL3pqn/Zm3C -KJ8c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/s -SfXRhKsgJWhdQzhVeXCBZD+bzn1caIDBPFc4a358XDNQsCgsr9fGcLEed6Z3u7Y1 -WSCVMkXQfspjtR0mruENF4gaoRzWr2qNArsOv9MFRwqgpPYatlIou63VQFoY7uJz -cFG+nSulJ9wDgP/SxNTbkTEUpaG0Z3p8leilxlKlcrsfVUYSkn20x5W2uXQcpZJy -cVWe6arsnK+JoL0rbcNjrBIVUmE4r1Vpy4YCXxQSybKmsQeV76xSSGIl+XPnvi0D -QQKCAQBZ5Mr0LuDmvk3BG49bIKEqyvfl86wetM1G6mDw1BZbeFceMhzqCl55ja37 -j3BJTTxWfLwu2pyPjGnQCT4RXmkwG53rAhTjV2ezNbhvYY/wMDhj7nThejt/tgdJ -ObuQPpYMBpUolSKmCxMDp8neZrfDE7bSUok4IslSOC/2UjCn5lSSwjZbh8EOJO8W -C12cUzsknXx3T4cWhyAzk9JOkaKC/oS4N58L+qpb7B/c++urFtd1zMmrXIdbIFRt -ecwrM25XHEutULh/h920jnn7w4mtYTTHuQ40bqsIEunfIfwZtufM/NA5oApyconY -ZRsv9lQ7diIpqcaPLK7OfxLqZahx ------END PRIVATE KEY----- diff --git a/config/config.js b/config/config.js index ae67f3136353f12b7383343768c4358bc8b121c2..8fa365a877e9a24f979909a28f3aba97a12faa18 100644 --- a/config/config.js +++ b/config/config.js @@ -8,27 +8,27 @@ module.exports = { strategy: 'saml', saml: { path: process.env.SAML_PATH || '/saml/SSO', - entryPoint: process.env.SAML_ENTRY_POINT || 'https://m4lab.hft-stuttgart.de/idp/saml2/idp/SSOService.php', - issuer: 'sp-project.m4lab.hft-stuttgart.de', - logoutUrl: 'https://m4lab.hft-stuttgart.de/idp/saml2/idp/SingleLogoutService.php' + entryPoint: process.env.SAML_ENTRY_POINT || 'saml entry URL', + issuer: 'saml issuer URL', + logoutUrl: 'saml Logout URL' } }, database: { - user: 'DBManager', // DB username - password: 'Stuttgart2019', // DB password + user: 'usernamedb', // DB username + password: 'passworddb', // DB password port: 3306, // MySQL port dbUser: 'userdb', // User DB host_project: 'localhost', // local - dbProject: 'projectDB' // Project DB + dbProject: 'projectdb' // Project DB }, mailer: { - host: 'mail.hft-stuttgart.de', // hostname + host: 'mailhost', // hostname secureConnection: false, // TLS requires secureConnection to be false port: 587, // port for secure SMTP - authUser: 'ad\\support-transfer', - authPass: '6laumri2', + authUser: 'usernamemail', + authPass: 'passwordmail', tlsCiphers: 'SSLv3', - from: 'support-transfer@hft-stuttgart.de', + from: 'email_from', } }, testing: { @@ -40,28 +40,27 @@ module.exports = { strategy: 'saml', saml: { path: process.env.SAML_PATH || '/saml/SSO', - entryPoint: process.env.SAML_ENTRY_POINT || 'https://m4lab.hft-stuttgart.de/idp/saml2/idp/SSOService.php', - issuer: 'sp-project-testing.m4lab.hft-stuttgart.de', - logoutUrl: 'https://m4lab.hft-stuttgart.de/idp/saml2/idp/SingleLogoutService.php' + entryPoint: process.env.SAML_ENTRY_POINT || 'saml entry URL', + issuer: 'saml issuer URL', + logoutUrl: 'saml Logout URL' } }, database: { - host: 'transfer.hft-stuttgart.de', // DB host - user: 'DBManager', // DB username - password: 'Stuttgart2019', // DB password + user: 'usernamedb', // DB username + password: 'passworddb', // DB password port: 3306, // MySQL port dbUser: 'userdb', // User DB - host_project: 'm4lab.hft-stuttgart.de', // DB host project db - dbProject: 'projectDB' // Project DB + host_project: 'localhost', // local + dbProject: 'projectdb' // Project DB }, mailer: { - host: 'mail.hft-stuttgart.de', // hostname + host: 'mailhost', // hostname secureConnection: false, // TLS requires secureConnection to be false port: 587, // port for secure SMTP - authUser: 'ad\\support-transfer', - authPass: '6laumri2', + authUser: 'usernamemail', + authPass: 'passwordmail', tlsCiphers: 'SSLv3', - from: 'support-transfer@hft-stuttgart.de', + from: 'email_from', } }, production: { diff --git a/package-lock.json b/package-lock.json index 084ad4a8ea6f753aeb4e1980ae61df350b86432f..e2cbdb81a8810a2dd120b265a1d13504d701bbf6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,5 +1,5 @@ { - "name": "passport-saml-example", + "name": "m4_lab-projects", "version": "0.0.1", "lockfileVersion": 1, "requires": true, @@ -133,6 +133,14 @@ "resolved": "https://registry.npmjs.org/atob/-/atob-2.1.2.tgz", "integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==" }, + "axios": { + "version": "0.20.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.20.0.tgz", + "integrity": "sha512-ANA4rr2BDcmmAQLOKft2fufrtuvlqR+cXNNinUmvfeSNCOF98PZL+7M/v1zIdGo7OLjEA9J2gXJL+j4zGsl0bA==", + "requires": { + "follow-redirects": "^1.10.0" + } + }, "babel-runtime": { "version": "6.26.0", "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz", @@ -154,9 +162,9 @@ }, "dependencies": { "lodash": { - "version": "4.17.15", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz", - "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==" + "version": "4.17.19", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", + "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==" } } }, @@ -230,15 +238,13 @@ } } }, - "base64-url": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/base64-url/-/base64-url-1.2.1.tgz", - "integrity": "sha1-GZ/WYXAqDnt9yubgaYuwicUvbXg=" - }, "basic-auth": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-1.0.4.tgz", - "integrity": "sha1-Awk1sB3nyblKgksp8/zLdQ06UpA=" + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-2.0.1.tgz", + "integrity": "sha512-NF+epuEdnUYVlGuhaxbbq+dvJttwLnGY+YixlXlME5KpQ5W3CnXA5cVTneY3SPbPDRkcjMbifrwmFYcClgOZeg==", + "requires": { + "safe-buffer": "5.1.2" + } }, "bignumber.js": { "version": "9.0.0", @@ -251,22 +257,27 @@ "integrity": "sha512-Un7MIEDdUC5gNpcGDV97op1Ywk748MpHcFTHoYs6qnj1Z3j7I53VG3nwZhKzoBZmbdRNnb6WRdFlwl7tSDuZGw==" }, "body-parser": { - "version": "1.15.1", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.15.1.tgz", - "integrity": "sha1-m87vBmm4+LlD8K2M5dlXFr10D9I=", - "requires": { - "bytes": "2.3.0", - "content-type": "~1.0.1", - "debug": "~2.2.0", - "depd": "~1.1.0", - "http-errors": "~1.4.0", - "iconv-lite": "0.4.13", + "version": "1.19.0", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.19.0.tgz", + "integrity": "sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==", + "requires": { + "bytes": "3.1.0", + "content-type": "~1.0.4", + "debug": "2.6.9", + "depd": "~1.1.2", + "http-errors": "1.7.2", + "iconv-lite": "0.4.24", "on-finished": "~2.3.0", - "qs": "6.1.0", - "raw-body": "~2.1.6", - "type-is": "~1.6.12" + "qs": "6.7.0", + "raw-body": "2.4.0", + "type-is": "~1.6.17" } }, + "bowser": { + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/bowser/-/bowser-2.9.0.tgz", + "integrity": "sha512-2ld76tuLBNFekRgmJfT2+3j5MIrP6bFict8WAIT3beq+srz1gcKNAdNKMqHqauQt63NmAa88HfP1/Ypa9Er3HA==" + }, "brace-expansion": { "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", @@ -295,9 +306,9 @@ } }, "bytes": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-2.3.0.tgz", - "integrity": "sha1-1baAoWW2IBc5rLYRVCqrwtjOsHA=" + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.0.tgz", + "integrity": "sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==" }, "cache-base": { "version": "1.0.1", @@ -327,6 +338,11 @@ "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-1.2.1.tgz", "integrity": "sha1-m7UwTS4LVmmLLHWLCKPqqdqlijk=" }, + "camelize": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/camelize/-/camelize-1.0.0.tgz", + "integrity": "sha1-FkpUg+Yw+kMh5a8HAg5TGDGyYJs=" + }, "center-align": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/center-align/-/center-align-0.1.3.tgz", @@ -430,6 +446,60 @@ "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", "integrity": "sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==" }, + "compressible": { + "version": "2.0.18", + "resolved": "https://registry.npmjs.org/compressible/-/compressible-2.0.18.tgz", + "integrity": "sha512-AF3r7P5dWxL8MxyITRMlORQNaOA2IkAFaTr4k7BUumjPtRpGDTZpl0Pb1XCO6JeDCBdp126Cgs9sMxqSjgYyRg==", + "requires": { + "mime-db": ">= 1.43.0 < 2" + }, + "dependencies": { + "mime-db": { + "version": "1.44.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz", + "integrity": "sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg==" + } + } + }, + "compression": { + "version": "1.7.4", + "resolved": "https://registry.npmjs.org/compression/-/compression-1.7.4.tgz", + "integrity": "sha512-jaSIDzP9pZVS4ZfQ+TzvtiWhdpFhE2RDHz8QJkpX9SIpLq88VueF5jJw6t+6CUQcAoA6t+x89MLrWAqpfDE8iQ==", + "requires": { + "accepts": "~1.3.5", + "bytes": "3.0.0", + "compressible": "~2.0.16", + "debug": "2.6.9", + "on-headers": "~1.0.2", + "safe-buffer": "5.1.2", + "vary": "~1.1.2" + }, + "dependencies": { + "bytes": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.0.0.tgz", + "integrity": "sha1-0ygVQE1olpn4Wk6k+odV3ROpYEg=" + }, + "debug": { + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", + "requires": { + "ms": "2.0.0" + } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + }, + "vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" + } + } + }, "concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", @@ -467,9 +537,17 @@ } }, "content-disposition": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.1.tgz", - "integrity": "sha1-h0dsamfI2qh+Muh2Ft+IO6f7Bxs=" + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-0.5.3.tgz", + "integrity": "sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==", + "requires": { + "safe-buffer": "5.1.2" + } + }, + "content-security-policy-builder": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-security-policy-builder/-/content-security-policy-builder-2.1.0.tgz", + "integrity": "sha512-/MtLWhJVvJNkA9dVLAp6fg9LxD2gfI6R2Fi1hPmfjYXSahJJzcfvoeDOxSyp4NvxMuwWv3WMssE9o31DoULHrQ==" }, "content-type": { "version": "1.0.4", @@ -510,17 +588,24 @@ "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.2.tgz", "integrity": "sha1-tf1UIgqivFq1eqtxQMlAdUUDwac=" }, - "crc": { - "version": "3.4.0", - "resolved": "https://registry.npmjs.org/crc/-/crc-3.4.0.tgz", - "integrity": "sha1-QljjUWE6dO8RU9/LBeggw+lxXX8=" + "dasherize": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/dasherize/-/dasherize-2.0.0.tgz", + "integrity": "sha1-bYCcnNDPe7iVLYD8hPoT1H3bEwg=" }, "debug": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.2.0.tgz", - "integrity": "sha1-+HBX6ZWxofauaklgZkE3vFbwOdo=", + "version": "2.6.9", + "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", + "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", "requires": { - "ms": "0.7.1" + "ms": "2.0.0" + }, + "dependencies": { + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=" + } } }, "decamelize": { @@ -587,9 +672,9 @@ "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" }, "kind-of": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==" } } }, @@ -616,6 +701,11 @@ "resolved": "https://registry.npmjs.org/doctypes/-/doctypes-1.1.0.tgz", "integrity": "sha1-6oCxBqh1OHdOijpKWv4pPeSJ4Kk=" }, + "dont-sniff-mimetype": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/dont-sniff-mimetype/-/dont-sniff-mimetype-1.1.0.tgz", + "integrity": "sha512-ZjI4zqTaxveH2/tTlzS1wFp+7ncxNZaIEWYg3lzZRHkKf5zPT/MnEG6WL0BhHMJUabkh8GeU5NL5j+rEUCb7Ug==" + }, "duplexer": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.1.tgz", @@ -642,6 +732,11 @@ "resolved": "https://registry.npmjs.org/ejs/-/ejs-0.8.8.tgz", "integrity": "sha1-/9xW3MNdApJt1QrRNDm7xUBh1Zg=" }, + "encodeurl": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-1.0.2.tgz", + "integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=" + }, "end-of-stream": { "version": "1.4.4", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", @@ -707,9 +802,9 @@ "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==" }, "etag": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/etag/-/etag-1.7.0.tgz", - "integrity": "sha1-A9MLX2fdbmMtKUXTDWZScxo01dg=" + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=" }, "event-stream": { "version": "3.3.4", @@ -742,60 +837,46 @@ } }, "express": { - "version": "4.13.4", - "resolved": "https://registry.npmjs.org/express/-/express-4.13.4.tgz", - "integrity": "sha1-PAt288d1kMg0VzkGHsC9O6Bn7CQ=", + "version": "4.17.1", + "resolved": "https://registry.npmjs.org/express/-/express-4.17.1.tgz", + "integrity": "sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==", "requires": { - "accepts": "~1.2.12", + "accepts": "~1.3.7", "array-flatten": "1.1.1", - "content-disposition": "0.5.1", - "content-type": "~1.0.1", - "cookie": "0.1.5", + "body-parser": "1.19.0", + "content-disposition": "0.5.3", + "content-type": "~1.0.4", + "cookie": "0.4.0", "cookie-signature": "1.0.6", - "debug": "~2.2.0", - "depd": "~1.1.0", + "debug": "2.6.9", + "depd": "~1.1.2", + "encodeurl": "~1.0.2", "escape-html": "~1.0.3", - "etag": "~1.7.0", - "finalhandler": "0.4.1", - "fresh": "0.3.0", + "etag": "~1.8.1", + "finalhandler": "~1.1.2", + "fresh": "0.5.2", "merge-descriptors": "1.0.1", "methods": "~1.1.2", "on-finished": "~2.3.0", - "parseurl": "~1.3.1", + "parseurl": "~1.3.3", "path-to-regexp": "0.1.7", - "proxy-addr": "~1.0.10", - "qs": "4.0.0", - "range-parser": "~1.0.3", - "send": "0.13.1", - "serve-static": "~1.10.2", - "type-is": "~1.6.6", - "utils-merge": "1.0.0", - "vary": "~1.0.1" + "proxy-addr": "~2.0.5", + "qs": "6.7.0", + "range-parser": "~1.2.1", + "safe-buffer": "5.1.2", + "send": "0.17.1", + "serve-static": "1.14.1", + "setprototypeof": "1.1.1", + "statuses": "~1.5.0", + "type-is": "~1.6.18", + "utils-merge": "1.0.1", + "vary": "~1.1.2" }, "dependencies": { - "accepts": { - "version": "1.2.13", - "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.2.13.tgz", - "integrity": "sha1-5fHzkoxtlf2WVYw27D2dDeSm7Oo=", - "requires": { - "mime-types": "~2.1.6", - "negotiator": "0.5.3" - } - }, "cookie": { - "version": "0.1.5", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.1.5.tgz", - "integrity": "sha1-armUiksa4hlSzSWIUwpHItQETXw=" - }, - "negotiator": { - "version": "0.5.3", - "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.5.3.tgz", - "integrity": "sha1-Jp1cR2gQ7JLtvntsLygxY4T5p+g=" - }, - "qs": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-4.0.0.tgz", - "integrity": "sha1-wx2bdOwn33XlQ6hseHKO2NRiNgc=" + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", + "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==" } } }, @@ -816,25 +897,34 @@ } }, "express-session": { - "version": "1.13.0", - "resolved": "https://registry.npmjs.org/express-session/-/express-session-1.13.0.tgz", - "integrity": "sha1-isO1wBiLSDgoUdiCB7jndG77QBE=", + "version": "1.17.1", + "resolved": "https://registry.npmjs.org/express-session/-/express-session-1.17.1.tgz", + "integrity": "sha512-UbHwgqjxQZJiWRTMyhvWGvjBQduGCSBDhhZXYenziMFjxst5rMV+aJZ6hKPHZnPyHGsrqRICxtX8jtEbm/z36Q==", "requires": { - "cookie": "0.2.3", + "cookie": "0.4.0", "cookie-signature": "1.0.6", - "crc": "3.4.0", - "debug": "~2.2.0", - "depd": "~1.1.0", - "on-headers": "~1.0.1", - "parseurl": "~1.3.0", - "uid-safe": "~2.0.0", - "utils-merge": "1.0.0" + "debug": "2.6.9", + "depd": "~2.0.0", + "on-headers": "~1.0.2", + "parseurl": "~1.3.3", + "safe-buffer": "5.2.0", + "uid-safe": "~2.1.5" }, "dependencies": { "cookie": { - "version": "0.2.3", - "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.2.3.tgz", - "integrity": "sha1-GllTavaFN6IReKATRvh8sFnSrlw=" + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.4.0.tgz", + "integrity": "sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==" + }, + "depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + }, + "safe-buffer": { + "version": "5.2.0", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.0.tgz", + "integrity": "sha512-fZEwUGbVl7kouZs1jCdMLdt95hdIv0ZeHg6L7qPeciMZhZ+/gdesW4wgTARkrFWEpspjEATAzUGPG8N2jJiwbg==" } } }, @@ -865,6 +955,11 @@ "is-extglob": "^1.0.0" } }, + "feature-policy": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/feature-policy/-/feature-policy-0.3.0.tgz", + "integrity": "sha512-ZtijOTFN7TzCujt1fnNhfWPFPSHeZkesff9AXZj+UEjYBynWNUIYpC87Ve4wHzyexQsImicLu7WsC2LHq7/xrQ==" + }, "filename-regex": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/filename-regex/-/filename-regex-2.0.1.tgz", @@ -883,16 +978,24 @@ } }, "finalhandler": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-0.4.1.tgz", - "integrity": "sha1-haF8bFmpRxfSYtYSMNSw6+PUoU0=", + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-1.1.2.tgz", + "integrity": "sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==", "requires": { - "debug": "~2.2.0", + "debug": "2.6.9", + "encodeurl": "~1.0.2", "escape-html": "~1.0.3", "on-finished": "~2.3.0", + "parseurl": "~1.3.3", + "statuses": "~1.5.0", "unpipe": "~1.0.0" } }, + "follow-redirects": { + "version": "1.13.0", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.13.0.tgz", + "integrity": "sha512-aq6gF1BEKje4a9i9+5jimNFIpq4Q1WiwBToeRK5NvZBd/TRsmW8BsJfOEGkr76TbOyPVD3OVDN910EcUNtRYEA==" + }, "for-in": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/for-in/-/for-in-1.0.2.tgz", @@ -920,9 +1023,9 @@ } }, "fresh": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.3.0.tgz", - "integrity": "sha1-ZR+DjiJCTnVm3hYdg1jKoZn4PU8=" + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz", + "integrity": "sha1-PYyt2Q2XZWn6g1qx+OSyOhBWBac=" }, "from": { "version": "0.1.7", @@ -1546,19 +1649,98 @@ } } }, - "http-errors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.4.0.tgz", - "integrity": "sha1-bAJC3qaz33r9oVPHEImzHG6Cqr8=", + "helmet": { + "version": "3.23.3", + "resolved": "https://registry.npmjs.org/helmet/-/helmet-3.23.3.tgz", + "integrity": "sha512-U3MeYdzPJQhtvqAVBPntVgAvNSOJyagwZwyKsFdyRa8TV3pOKVFljalPOCxbw5Wwf2kncGhmP0qHjyazIdNdSA==", + "requires": { + "depd": "2.0.0", + "dont-sniff-mimetype": "1.1.0", + "feature-policy": "0.3.0", + "helmet-crossdomain": "0.4.0", + "helmet-csp": "2.10.0", + "hide-powered-by": "1.1.0", + "hpkp": "2.0.0", + "hsts": "2.2.0", + "nocache": "2.1.0", + "referrer-policy": "1.2.0", + "x-xss-protection": "1.3.0" + }, + "dependencies": { + "depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + } + } + }, + "helmet-crossdomain": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/helmet-crossdomain/-/helmet-crossdomain-0.4.0.tgz", + "integrity": "sha512-AB4DTykRw3HCOxovD1nPR16hllrVImeFp5VBV9/twj66lJ2nU75DP8FPL0/Jp4jj79JhTfG+pFI2MD02kWJ+fA==" + }, + "helmet-csp": { + "version": "2.10.0", + "resolved": "https://registry.npmjs.org/helmet-csp/-/helmet-csp-2.10.0.tgz", + "integrity": "sha512-Rz953ZNEFk8sT2XvewXkYN0Ho4GEZdjAZy4stjiEQV3eN7GDxg1QKmYggH7otDyIA7uGA6XnUMVSgeJwbR5X+w==", "requires": { - "inherits": "2.0.1", - "statuses": ">= 1.2.1 < 2" + "bowser": "2.9.0", + "camelize": "1.0.0", + "content-security-policy-builder": "2.1.0", + "dasherize": "2.0.0" + } + }, + "hide-powered-by": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/hide-powered-by/-/hide-powered-by-1.1.0.tgz", + "integrity": "sha512-Io1zA2yOA1YJslkr+AJlWSf2yWFkKjvkcL9Ni1XSUqnGLr/qRQe2UI3Cn/J9MsJht7yEVCe0SscY1HgVMujbgg==" + }, + "hpkp": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/hpkp/-/hpkp-2.0.0.tgz", + "integrity": "sha1-EOFCJk52IVpdMMROxD3mTe5tFnI=" + }, + "hsts": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/hsts/-/hsts-2.2.0.tgz", + "integrity": "sha512-ToaTnQ2TbJkochoVcdXYm4HOCliNozlviNsg+X2XQLQvZNI/kCHR9rZxVYpJB3UPcHz80PgxRyWQ7PdU1r+VBQ==", + "requires": { + "depd": "2.0.0" + }, + "dependencies": { + "depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + } + } + }, + "http-errors": { + "version": "1.7.2", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.7.2.tgz", + "integrity": "sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==", + "requires": { + "depd": "~1.1.2", + "inherits": "2.0.3", + "setprototypeof": "1.1.1", + "statuses": ">= 1.5.0 < 2", + "toidentifier": "1.0.0" + }, + "dependencies": { + "inherits": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", + "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" + } } }, "iconv-lite": { - "version": "0.4.13", - "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.13.tgz", - "integrity": "sha1-H4irpKsLFQjoMSrMOTRfNumS4vI=" + "version": "0.4.24", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", + "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==", + "requires": { + "safer-buffer": ">= 2.1.2 < 3" + } }, "ignore-by-default": { "version": "1.0.1", @@ -1586,9 +1768,9 @@ "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==" }, "ipaddr.js": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.0.5.tgz", - "integrity": "sha1-X6eM8wG4JceKvDBC2BJyMEnqI8c=" + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==" }, "is-accessor-descriptor": { "version": "0.1.6", @@ -1980,9 +2162,9 @@ } }, "mime": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/mime/-/mime-1.3.4.tgz", - "integrity": "sha1-EV+eO2s9rylZmDyzjxSaLUDrXVM=" + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==" }, "mime-db": { "version": "1.40.0", @@ -2005,11 +2187,6 @@ "brace-expansion": "^1.1.7" } }, - "minimist": { - "version": "0.0.8", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", - "integrity": "sha1-hX/Kv8M5fSYluCKCYuhqp6ARsF0=" - }, "mixin-deep": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/mixin-deep/-/mixin-deep-1.3.2.tgz", @@ -2030,30 +2207,39 @@ } }, "mkdirp": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.1.tgz", - "integrity": "sha1-MAV0OOrGz3+MR2fzhkjWaX11yQM=", + "version": "0.5.5", + "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", + "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", "requires": { - "minimist": "0.0.8" + "minimist": "^1.2.5" + }, + "dependencies": { + "minimist": { + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" + } } }, "morgan": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/morgan/-/morgan-1.7.0.tgz", - "integrity": "sha1-6xDKjlDRq+D409rVwCAdBS2YHGI=", + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/morgan/-/morgan-1.10.0.tgz", + "integrity": "sha512-AbegBVI4sh6El+1gNwvD5YIck7nSA36weD7xvIxG4in80j/UoK8AEGaWnnz8v1GxonMCltmlNs5ZKbGvl9b1XQ==", "requires": { - "basic-auth": "~1.0.3", - "debug": "~2.2.0", - "depd": "~1.1.0", + "basic-auth": "~2.0.1", + "debug": "2.6.9", + "depd": "~2.0.0", "on-finished": "~2.3.0", - "on-headers": "~1.0.1" + "on-headers": "~1.0.2" + }, + "dependencies": { + "depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==" + } } }, - "ms": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/ms/-/ms-0.7.1.tgz", - "integrity": "sha1-nNE8A62/8ltl7/3nzoZO6VIBcJg=" - }, "mysql": { "version": "2.18.1", "resolved": "https://registry.npmjs.org/mysql/-/mysql-2.18.1.tgz", @@ -2121,9 +2307,9 @@ "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=" }, "kind-of": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==" } } }, @@ -2140,6 +2326,11 @@ "inherits": "~2.0.1" } }, + "nocache": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/nocache/-/nocache-2.1.0.tgz", + "integrity": "sha512-0L9FvHG3nfnnmaEQPjT9xhfN4ISk0A8/2j4M37Np4mcDesJjHgEUfgPhdCyZuFI954tjokaIj/A3NdpFNdEh4Q==" + }, "node-forge": { "version": "0.2.24", "resolved": "https://registry.npmjs.org/node-forge/-/node-forge-0.2.24.tgz", @@ -2434,12 +2625,12 @@ } }, "proxy-addr": { - "version": "1.0.10", - "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-1.0.10.tgz", - "integrity": "sha1-DUCoL4Afw1VWfS7LZe/j8HfxIcU=", + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.6.tgz", + "integrity": "sha512-dh/frvCBVmSsDYzw6n926jv974gddhkFPfiN8hPOi30Wax25QZyZEGveluCgliBnqmuM+UJmBErbAUFIoDbjOw==", "requires": { - "forwarded": "~0.1.0", - "ipaddr.js": "1.0.5" + "forwarded": "~0.1.2", + "ipaddr.js": "1.9.1" } }, "ps-tree": { @@ -2570,9 +2761,14 @@ "integrity": "sha1-Y1fikSBnAdmfGXq4TlforRlvKok=" }, "qs": { - "version": "6.1.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.1.0.tgz", - "integrity": "sha1-7B0WJrJCeNmfD99FSeUk4k7O6yY=" + "version": "6.7.0", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.7.0.tgz", + "integrity": "sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==" + }, + "random-bytes": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/random-bytes/-/random-bytes-1.0.0.tgz", + "integrity": "sha1-T2ih3Arli9P7lYSMMDJNt11kNgs=" }, "randomatic": { "version": "3.1.1", @@ -2590,32 +2786,26 @@ "integrity": "sha512-rSklcAIlf1OmFdyAqbnWTLVelsQ58uvZ66S/ZyawjWqIviTWCjg2PzVGw8WUA+nNuPTqb4wgA+NszrJ+08LlgQ==" }, "kind-of": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==" } } }, "range-parser": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.0.3.tgz", - "integrity": "sha1-aHKCNTXGkuLCoBA4Jq/YLC4P8XU=" + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.2.1.tgz", + "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==" }, "raw-body": { - "version": "2.1.7", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.1.7.tgz", - "integrity": "sha1-rf6s4uT7MJgFgBTQjActzFl1h3Q=", + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.4.0.tgz", + "integrity": "sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==", "requires": { - "bytes": "2.4.0", - "iconv-lite": "0.4.13", + "bytes": "3.1.0", + "http-errors": "1.7.2", + "iconv-lite": "0.4.24", "unpipe": "1.0.0" - }, - "dependencies": { - "bytes": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/bytes/-/bytes-2.4.0.tgz", - "integrity": "sha1-fZcZb51br39pNeJZhVSe3SpsIzk=" - } } }, "rc": { @@ -2630,9 +2820,9 @@ }, "dependencies": { "minimist": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.0.tgz", - "integrity": "sha1-o1AIsg9BOD7sH7kU9M1d95omQoQ=" + "version": "1.2.5", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", + "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==" } } }, @@ -2908,9 +3098,9 @@ "integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=" }, "kind-of": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.2.tgz", - "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==" + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-6.0.3.tgz", + "integrity": "sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==" }, "micromatch": { "version": "3.1.10", @@ -2939,6 +3129,11 @@ } } }, + "referrer-policy": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/referrer-policy/-/referrer-policy-1.2.0.tgz", + "integrity": "sha512-LgQJIuS6nAy1Jd88DCQRemyE3mS+ispwlqMk3b0yjZ257fI1v9c+/p6SD5gP5FGyXUIgrNOAfmyioHwZtYv2VA==" + }, "regenerator-runtime": { "version": "0.11.1", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz", @@ -3031,6 +3226,11 @@ "ret": "~0.1.10" } }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, "sax": { "version": "1.2.4", "resolved": "https://registry.npmjs.org/sax/-/sax-1.2.4.tgz", @@ -3050,83 +3250,41 @@ } }, "send": { - "version": "0.13.1", - "resolved": "https://registry.npmjs.org/send/-/send-0.13.1.tgz", - "integrity": "sha1-ow1fTILIqbrprQCh2bG9vm8Zntc=", + "version": "0.17.1", + "resolved": "https://registry.npmjs.org/send/-/send-0.17.1.tgz", + "integrity": "sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==", "requires": { - "debug": "~2.2.0", - "depd": "~1.1.0", + "debug": "2.6.9", + "depd": "~1.1.2", "destroy": "~1.0.4", + "encodeurl": "~1.0.2", "escape-html": "~1.0.3", - "etag": "~1.7.0", - "fresh": "0.3.0", - "http-errors": "~1.3.1", - "mime": "1.3.4", - "ms": "0.7.1", + "etag": "~1.8.1", + "fresh": "0.5.2", + "http-errors": "~1.7.2", + "mime": "1.6.0", + "ms": "2.1.1", "on-finished": "~2.3.0", - "range-parser": "~1.0.3", - "statuses": "~1.2.1" + "range-parser": "~1.2.1", + "statuses": "~1.5.0" }, "dependencies": { - "http-errors": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.3.1.tgz", - "integrity": "sha1-GX4izevUGYWF6GlO9nhhl7ke2UI=", - "requires": { - "inherits": "~2.0.1", - "statuses": "1" - } - }, - "statuses": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.2.1.tgz", - "integrity": "sha1-3e1FzBglbVHtQK7BQkidXGECbSg=" + "ms": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", + "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==" } } }, "serve-static": { - "version": "1.10.3", - "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.10.3.tgz", - "integrity": "sha1-zlpuzTEB/tXsCYJ9rCKpwpv7BTU=", + "version": "1.14.1", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.14.1.tgz", + "integrity": "sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==", "requires": { + "encodeurl": "~1.0.2", "escape-html": "~1.0.3", - "parseurl": "~1.3.1", - "send": "0.13.2" - }, - "dependencies": { - "http-errors": { - "version": "1.3.1", - "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-1.3.1.tgz", - "integrity": "sha1-GX4izevUGYWF6GlO9nhhl7ke2UI=", - "requires": { - "inherits": "~2.0.1", - "statuses": "1" - } - }, - "send": { - "version": "0.13.2", - "resolved": "https://registry.npmjs.org/send/-/send-0.13.2.tgz", - "integrity": "sha1-dl52B8gFVFK7pvCwUllTUJhgNt4=", - "requires": { - "debug": "~2.2.0", - "depd": "~1.1.0", - "destroy": "~1.0.4", - "escape-html": "~1.0.3", - "etag": "~1.7.0", - "fresh": "0.3.0", - "http-errors": "~1.3.1", - "mime": "1.3.4", - "ms": "0.7.1", - "on-finished": "~2.3.0", - "range-parser": "~1.0.3", - "statuses": "~1.2.1" - } - }, - "statuses": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.2.1.tgz", - "integrity": "sha1-3e1FzBglbVHtQK7BQkidXGECbSg=" - } + "parseurl": "~1.3.3", + "send": "0.17.1" } }, "set-value": { @@ -3150,6 +3308,11 @@ } } }, + "setprototypeof": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.1.tgz", + "integrity": "sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==" + }, "slide": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/slide/-/slide-1.1.6.tgz", @@ -3447,6 +3610,11 @@ } } }, + "toidentifier": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.0.tgz", + "integrity": "sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==" + }, "token-stream": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/token-stream/-/token-stream-0.0.1.tgz", @@ -3493,11 +3661,11 @@ "optional": true }, "uid-safe": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/uid-safe/-/uid-safe-2.0.0.tgz", - "integrity": "sha1-p/PGymSh9qXQTsDvPkw9U2cxcTc=", + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/uid-safe/-/uid-safe-2.1.5.tgz", + "integrity": "sha512-KPHm4VL5dDXKz01UuEd88Df+KzynaohSL9fBh096KWAxSKZQDI2uBrVqtvRM4rwrIrRRKsdLNML/lnaaVSRioA==", "requires": { - "base64-url": "1.2.1" + "random-bytes": "~1.0.0" } }, "undefsafe": { @@ -3601,9 +3769,9 @@ } }, "utils-merge": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz", - "integrity": "sha1-ApT7kiu5N1FTVBxPcJYjHyh8ivg=" + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.1.tgz", + "integrity": "sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=" }, "uuid": { "version": "2.0.3", @@ -3611,9 +3779,9 @@ "integrity": "sha1-Z+LoY3lyFVMN/zGOW/nc6/1Hsho=" }, "vary": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/vary/-/vary-1.0.1.tgz", - "integrity": "sha1-meSYFWaihhGN+yuBc1ffeZM3bRA=" + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=" }, "void-elements": { "version": "2.0.1", @@ -3654,6 +3822,11 @@ "slide": "^1.1.5" } }, + "x-xss-protection": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/x-xss-protection/-/x-xss-protection-1.3.0.tgz", + "integrity": "sha512-kpyBI9TlVipZO4diReZMAHWtS0MMa/7Kgx8hwG/EuZLiA6sg4Ah/4TRdASHhRRN3boobzcYgFRUFSgHRge6Qhg==" + }, "xdg-basedir": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/xdg-basedir/-/xdg-basedir-2.0.0.tgz", diff --git a/package.json b/package.json index 035d95e74fe5e8561e87b8fe3a9afc54cf1a72bd..bb0f7cf2a3a89d35d18f500cb53218bde872ad4e 100644 --- a/package.json +++ b/package.json @@ -1,40 +1,36 @@ { - "name": "passport-saml-example", + "name": "m4_lab-projects", "version": "0.0.1", - "description": "Example for PassportJS SAML strategy", + "description": "M4_LAB Projects Manager", "author": { - "name": "Gerard Braad", - "email": "me@gbraad.nl", - "url": "http://gbraad.nl" + "name": "Rosanny Sihombing", + "email": "rosanny.sihombing@hft-stuttgart.de" }, - "contributors": [ - { - "name": "Christian Kuster", - "email": "git@kusti.ch" - } - ], "keywords": [ - "saml", - "sso" + "m4_lab", + "prjects" ], "repository": { "type": "git", - "url": "https://github.com/gbraad/passport-saml-example.git" + "url": "https://transfer.hft-stuttgart.de/gitlab/m4lab_tv1/project-page.git" }, "scripts": { "start": "nodemon app.js", "test": "" }, "dependencies": { - "body-parser": "1.15.1", + "axios": "^0.20.0", + "body-parser": "^1.19.0", + "compression": "^1.7.4", "cookie-parser": "1.4.3", "errorhandler": "1.4.3", - "express": "4.13.4", + "express": "^4.17.1", "express-fileupload": "^1.1.7-alpha.2", "express-flash": "0.0.2", - "express-session": "1.13.0", + "express-session": "^1.17.1", "fs": "0.0.1-security", - "morgan": "1.7.0", + "helmet": "^3.23.3", + "morgan": "^1.10.0", "mysql": "^2.18.1", "nodemon": "1.9.2", "passport": "0.3.2", diff --git a/routes/routes-project.js b/routes/routes-project.js index a7a5389c06a4246febf54ce92309e08b00e0d6dc..89775cb3fc31da0fe799459ebf14a2b976863dc0 100644 --- a/routes/routes-project.js +++ b/routes/routes-project.js @@ -1,5 +1,5 @@ const fs = require('fs') -const SamlStrategy = require('passport-saml').Strategy +//const SamlStrategy = require('passport-saml').Strategy const dbconn = require('./dbconn') const methods = require('./methods') // pwd encryption @@ -13,6 +13,7 @@ const async = require('async') const helpers = require('./helpers') const pictSizeLimit = 1000000 // 1 MB +const axios = require('axios') module.exports = function (app) { @@ -355,4 +356,82 @@ module.exports = function (app) { ]) }) + async function getProjectsFromGitlab(perPage, idAfter) { + // public projects + return await axios.get('https://transfer.hft-stuttgart.de/gitlab/api/v4/projects?visibility=public&pagination=keyset&per_page='+ + perPage+'&order_by=id&sort=asc&id_after='+idAfter) + } + + app.get('/projectlist', async function(req, res){ + let projectArr = [] + let websiteArr = [] + let isProject = true + let firstId = 0 + let webname = ""; + + while (isProject == true) { + let projects = await getProjectsFromGitlab(10, firstId) + let projectData = projects.data + + if (projectData.length == 0) { + isProject = false + } + else { + for(let i = 0; i < projectData.length; i++){ + // skip template project + if (projectData[i].name == "template_gitlab_page") { + continue + } + + // M4_LAB logo for all projects that do not have logo + if (projectData[i].avatar_url == null) { + projectData[i].avatar_url = "https://m4lab.hft-stuttgart.de/img/footer/M4_LAB_LOGO_Graustufen.png" + } + + // websites + if (projectData[i].tag_list.includes('website')) { + // customize website name + if (projectData[i].name == "Visualization") { + webname = "https://transfer.hft-stuttgart.de/pages/visualization" + } + else if (projectData[i].name == "IN-Source") { + webname = "https://transfer.hft-stuttgart.de/pages/INsource" + } + else if (projectData[i].name == "3DS_Visualization_Cesium") { + webname = "https://transfer.hft-stuttgart.de/pages/3ds_visualization_cesium" + } + else { + webname = "https://transfer.hft-stuttgart.de/pages/"+projectData[i].name + } + let website = { + logo: projectData[i].avatar_url, + name: projectData[i].name, + weburl: webname, + desc: projectData[i].description + } + websiteArr.push(website) + } + // project repo + else { + let project = { + logo: projectData[i].avatar_url, + name: projectData[i].name, + weburl: projectData[i].web_url, + desc: projectData[i].description + } + projectArr.push(project) + } + } + + firstId = projectData[projectData.length-1].id + } + } + + res.render(lang+'/project/projectList', { + project: projectArr, + website: websiteArr + }) + }) + + }; \ No newline at end of file diff --git a/views/DE/project/project.html b/views/DE/project/project.html index 73cd0ee53cc11528b2806c7f66a7fa886b0bbdea..52026e837dd753bfee65dc8c5d3bd6f1b1733607 100644 --- a/views/DE/project/project.html +++ b/views/DE/project/project.html @@ -81,140 +81,7 @@
- Dann klicken Sie auf diesen - Link zu den Gitlab-Projekten - um die Liste aller im Gitlab erfassten Projekte zu sehen. Vor dort können Sie dann auf die einzelnen - Projekte zugreifen. - Ein Anmelden am Portal ist dazu nicht nötig. -
-- Sie können mittels Issues dem Projekteigentümer eine Rückmeldung geben bzw. einen Fehler melden. - Darüberhinaus können Sie sich auch aktiv beteiligen. Dazu müssen Sie im Portal als Nutzer - registriert sein. -
-- Wenn Sie noch kein Benutzerkonto haben, klicken Sie bitte oben auf den Link Benutzerkonto und folgen - Sie dem System durch die Registrierungsprozedur. -
-- Haben Sie ein Benutzerkonto, befolgen Sie bitte folgende Schritte: -
-- Vorraussetzung dazu ist, dass Sie aktives oder ehemaliges Mitglied der Hochschule für Technik sind, - d.h. eine (noch) gültige HFT-Emailadresse haben, und zudem im Portal als Nutzer registriert sein. -
-- Wenn Sie noch kein Benutzerkonto haben, klicken Sie bitte oben auf den Link Benutzerkonto und folgen - Sie dem System durch die Registrierungsprozedur. -
-- Haben Sie ein Benutzerkonto, befolgen Sie bitte folgende Schritte: -
-- Weitere Hilfestellung zum Anlegen von Projekten in Gitlab finden Sie in der Gitlab-Dokumentation. -
-- Hinweis: Um Inhalte zum Gitlab "pushen" zu können, verwendet die Gitlab-Instanz unseres Portals die - s.g. "SSH Keys". - Weitere Informationen dazu finden Sie in der - Gitlab-Dokumentation zu SSH Keys. -
-Falls Sie Hilfe zu Gitlab benötigen, besuchen Sie unseren Hilfebereich +
- \ No newline at end of file + diff --git a/views/DE/project/projectList.pug b/views/DE/project/projectList.pug new file mode 100644 index 0000000000000000000000000000000000000000..b21a0b0b4bc30a3aa0fd6b896b91d43f012b7038 --- /dev/null +++ b/views/DE/project/projectList.pug @@ -0,0 +1,69 @@ +doctype html +html(lang="de") + head + title= "Project List" + meta(charset="UTF-8") + meta(name="viewport", content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no") + link(rel="stylesheet", type="text/css", href="https://transfer.hft-stuttgart.de/css/bootstrap.min.css") + link(rel="stylesheet", type="text/css", href="https://transfer.hft-stuttgart.de/css/m4lab.css") + link(rel="stylesheet", href="https://use.fontawesome.com/releases/v5.8.2/css/all.css", integrity="sha384-oS3vJWv+0UjzBfQzYUhtDYW+Pj2yciDJxpsK1OYPAYjqT085Qq/1cq5FLXAZQ7Ay", crossorigin="anonymous") + + body + div(class="container") + div(class="pt-4 pb-4") + input(id="searchInput", class="form-control form-control-dark w-100", type="text", placeholder="Suchen Sie hier nach Themen und Projekten", onkeyup="searchFunction()") + h3(class="mb-3 font-weight-bold") Projekte + table(class="table table-striped") + tbody + for item in project + tr + td + img(src=item.logo, width="40", height="40") + td #{item.name} + td #{item.desc} + + if website.length > 0 + h3(class="mb-3 font-weight-bold") Websites + table(class="table table-striped") + for item in website + tr + td + img(src=item.logo, width="40", height="40") + td #{item.name} + td #{item.desc} + + // jQuery + script(src="https://code.jquery.com/jquery-3.3.1.min.js") + script(src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js", integrity="sha384-UO2eT0CpHqdSJQ6hJty5KVphtPhzWj9WO1clHTMGa3JDZwrnQq4sF86dIHNDz0W1", crossorigin="anonymous") + // Bootstrap + script(src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js" integrity="sha384-JjSmVgyd0p3pXB1rRibZUAYoIIy6OrQ6VrjIEaFf/nJGzIxFDsf4x0xIM+B07jRM" crossorigin="anonymous") + // Header + script(src="https://transfer.hft-stuttgart.de/js/headfoot.js") + script. + function searchFunction() { + var input, filter, rows, col, txtValue; + var isFound = true; + input = document.getElementById("searchInput"); + filter = input.value.toUpperCase(); + + rows = document.getElementsByTagName("tr"); + for (i = 0; i < rows.length; i++) { + cols = rows[i].getElementsByTagName("td"); + // check all cos + for (j = 0; j < cols.length; j++) { + txtValue = cols[j].textContent || cols[j].innerText; + if (txtValue.toUpperCase().indexOf(filter) > -1) { + isFound = true; + break; + } else { + isFound = false; + } + } + if (isFound) { + rows[i].style.display = "block"; + } + else { + rows[i].style.display = "none"; + } + } + } \ No newline at end of file