Compare commits
3 Commits
2233b4a44c
...
96780223d2
Author | SHA1 | Date | |
---|---|---|---|
96780223d2 | |||
2118b1db99 | |||
27a1817595 |
10
.dockerignore
Normal file
10
.dockerignore
Normal file
@ -0,0 +1,10 @@
|
||||
node_modules
|
||||
npm-debug.log
|
||||
.git
|
||||
.gitignore
|
||||
.env
|
||||
*.md
|
||||
logs
|
||||
*.log
|
||||
cookiesecret.txt
|
||||
mysql_password.txt
|
18
Dockerfile
Normal file
18
Dockerfile
Normal file
@ -0,0 +1,18 @@
|
||||
FROM node:slim
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
# Copy package files
|
||||
COPY package*.json ./
|
||||
|
||||
# Install dependencies
|
||||
RUN npm install
|
||||
|
||||
# Copy application code
|
||||
COPY . .
|
||||
|
||||
# Expose ports
|
||||
EXPOSE 80
|
||||
|
||||
# Start the application
|
||||
CMD ["node", "server.js"]
|
35
docker-compose.yml
Normal file
35
docker-compose.yml
Normal file
@ -0,0 +1,35 @@
|
||||
services:
|
||||
app:
|
||||
build: .
|
||||
ports:
|
||||
- "23080:80"
|
||||
environment:
|
||||
- MYSQL_HOST=db
|
||||
- MYSQL_USER=ipost
|
||||
- MYSQL_PASSWORD=ipost_password
|
||||
- MYSQL_DATABASE=ipost
|
||||
depends_on:
|
||||
- db
|
||||
volumes:
|
||||
- ./logs:/app/logs
|
||||
- ./server_config.json:/app/server_config.json
|
||||
- ./cookiesecret.txt:/app/cookiesecret.txt
|
||||
- ./mysql_password.txt:/app/mysql_password.txt
|
||||
restart: unless-stopped
|
||||
|
||||
db:
|
||||
image: mysql:8.0
|
||||
environment:
|
||||
- MYSQL_ROOT_PASSWORD=root_password
|
||||
- MYSQL_DATABASE=ipost
|
||||
- MYSQL_USER=ipost
|
||||
- MYSQL_PASSWORD=ipost_password
|
||||
volumes:
|
||||
- mysql_data:/var/lib/mysql
|
||||
- ./createSchema.sql:/docker-entrypoint-initdb.d/createSchema.sql
|
||||
ports:
|
||||
- "3306:3306"
|
||||
restart: unless-stopped
|
||||
|
||||
volumes:
|
||||
mysql_data:
|
@ -56,9 +56,9 @@ const cape = m => unes[m];
|
||||
const unescape = un => replace.call(un, es, cape);
|
||||
|
||||
function escape_special(str) {
|
||||
return str.replace(/\\/g,"\\\\").replace(/`/g,"\\`")
|
||||
return str.replace(/\\/g,"\\\\").replace(/`/g,"\\`");
|
||||
}
|
||||
|
||||
function unescape_special(str) {
|
||||
return str.replace(/\\\\/g,"\\").replace(/\\`/,"`")
|
||||
return str.replace(/\\\\/g,"\\").replace(/\\`/,"`");
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
const warn_messages = [
|
||||
["%cDo not paste any text in here","background: red; color: yellow; font-size: x-large"],
|
||||
["Pasting anything in here may give others access to your account.",""]
|
||||
["Pasting anything in here may give others access to your account."]
|
||||
]
|
||||
function warnmessage() {
|
||||
for (let message of warn_messages) {
|
||||
|
4332
package-lock.json
generated
4332
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
35
package.json
35
package.json
@ -1,26 +1,23 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"body-parser": "^1.20.2",
|
||||
"clean-css": "^5.3.2",
|
||||
"compression": "^1.7.4",
|
||||
"cookie-parser": "^1.4.6",
|
||||
"ejs": "^3.1.9",
|
||||
"express": "^4.18.2",
|
||||
"express-fileupload": "^1.3.1",
|
||||
"express-useragent": "^1.0.15",
|
||||
"hcaptcha": "^0.1.1",
|
||||
"hsts": "^2.2.0",
|
||||
"newrelic": "^9.15.0",
|
||||
"body-parser": "^2.2",
|
||||
"clean-css": "^5.3",
|
||||
"compression": "^1.8",
|
||||
"cookie-parser": "^1.4",
|
||||
"ejs": "^3.1",
|
||||
"express": "^5.1",
|
||||
"express-fileupload": "^1.5",
|
||||
"express-useragent": "^1.0",
|
||||
"hcaptcha": "^0.2",
|
||||
"html-minifier-terser": "^7.2.0",
|
||||
"lru-cache": "^9.1.2",
|
||||
"mysql2": "^3.3.5",
|
||||
"newrelic": "^9.11.0",
|
||||
"sharp": "^0.30.7",
|
||||
"spdy": "^4.0.2",
|
||||
"swagger-autogen": "^2.23.1",
|
||||
"uglify-js": "^3.17.4",
|
||||
"lru-cache": "^11.1",
|
||||
"mysql2": "^3.14",
|
||||
"sharp": "^0.34",
|
||||
"swagger-autogen": "^2.23",
|
||||
"uglify-js": "^3.19",
|
||||
"unsafe_encrypt": "^1.0.4",
|
||||
"ws": "^8.13.0"
|
||||
"ws": "^8.13.0",
|
||||
"cookie-signature": "^1.2.2"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "node server.js",
|
||||
|
1474
pnpm-lock.yaml
generated
Normal file
1474
pnpm-lock.yaml
generated
Normal file
File diff suppressed because it is too large
Load Diff
2
pnpm-workspace.yaml
Normal file
2
pnpm-workspace.yaml
Normal file
@ -0,0 +1,2 @@
|
||||
onlyBuiltDependencies:
|
||||
- sharp
|
@ -1,38 +1,41 @@
|
||||
import fs from "fs";
|
||||
import {SHA256} from "../../extra_modules/SHA.js";
|
||||
import {unsign} from "../../extra_modules/unsign.js";
|
||||
import { SHA256 } from "../../extra_modules/SHA.js";
|
||||
import { unsign } from "../../extra_modules/unsign.js";
|
||||
const config = JSON.parse(fs.readFileSync("server_config.json"));
|
||||
const HASHES_DB = config.cookies.server_hashes;
|
||||
const HASHES_COOKIE = config.cookies.client_hashes;
|
||||
const HASHES_DIFF = HASHES_DB - HASHES_COOKIE;
|
||||
|
||||
export const setup = function (router, con, server) {
|
||||
router.use("/*", (req, res, next) => {
|
||||
router.use("/*path", (req, res, next) => {
|
||||
res.set("Access-Control-Allow-Origin", "*"); //we'll allow it for now
|
||||
let unsigned;
|
||||
if(typeof req.get("ipost-auth-token") === "string") {
|
||||
try{
|
||||
|
||||
req.body = req.body || {};
|
||||
|
||||
if (typeof req.get("ipost-auth-token") === "string") {
|
||||
try {
|
||||
req.body.auth = JSON.parse(req.get("ipost-auth-token"))
|
||||
} catch(err) {
|
||||
console.log("error parsing header",err)
|
||||
} catch (err) {
|
||||
console.log("error parsing header", err)
|
||||
}
|
||||
}
|
||||
if(req.body.auth !== undefined && req.originalUrl !== "/redeemauthcode") {
|
||||
if(typeof req.body.auth === "string") {
|
||||
try{
|
||||
if (req.body.auth !== undefined && req.originalUrl !== "/redeemauthcode") {
|
||||
if (typeof req.body.auth === "string") {
|
||||
try {
|
||||
req.body.auth = JSON.parse(req.body.auth)
|
||||
} catch(err) {
|
||||
console.log("error parsing",err)
|
||||
} catch (err) {
|
||||
console.log("error parsing", err)
|
||||
}
|
||||
} else
|
||||
if(
|
||||
if (
|
||||
typeof req.body.auth !== "object" ||
|
||||
typeof req.body.auth.secret !== "string" ||
|
||||
typeof req.body.auth.appid !== "number" ||
|
||||
typeof req.body.auth.auth_token !== "string" ||
|
||||
req.body.auth.secret.length !== 200 ||
|
||||
req.body.auth.auth_token.length !== 200 ||
|
||||
Buffer.from(req.body.auth.secret,"base64").length !== 150
|
||||
Buffer.from(req.body.auth.secret, "base64").length !== 150
|
||||
) {
|
||||
res.status(420).send("invalid authentication object")
|
||||
return;
|
||||
@ -41,10 +44,10 @@ export const setup = function (router, con, server) {
|
||||
//appid : number
|
||||
//auth_token: string(200 chars)
|
||||
let sql = "select User_ID,User_Name,User_Bio,User_Avatar,User_Settings from ipost.auth_tokens inner join ipost.application on auth_token_isfrom_application_id=application_id inner join ipost.users on auth_token_u_id=User_ID where auth_token=? and application_secret=? and application_id=?"
|
||||
con.query(sql,[SHA256(req.body.auth.auth_token,req.body.auth.appid, HASHES_DB),SHA256(req.body.auth.secret,req.body.auth.appid, HASHES_DB),req.body.auth.appid],(err,result) => {
|
||||
if(err) throw err;
|
||||
con.query(sql, [SHA256(req.body.auth.auth_token, req.body.auth.appid, HASHES_DB), SHA256(req.body.auth.secret, req.body.auth.appid, HASHES_DB), req.body.auth.appid], (err, result) => {
|
||||
if (err) throw err;
|
||||
|
||||
if(result.length !== 1) {
|
||||
if (result.length !== 1) {
|
||||
res.status(420).send("invalid authentication object (or server error?)")
|
||||
return;
|
||||
}
|
||||
@ -62,12 +65,12 @@ export const setup = function (router, con, server) {
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
if(!req.cookies.AUTH_COOKIE) {
|
||||
if (!req.cookies.AUTH_COOKIE) {
|
||||
next()
|
||||
return
|
||||
}
|
||||
unsigned = unsign(req.cookies.AUTH_COOKIE, req, res);
|
||||
if (!unsigned){
|
||||
if (!unsigned) {
|
||||
next()
|
||||
return
|
||||
}
|
||||
@ -94,13 +97,13 @@ export const setup = function (router, con, server) {
|
||||
});
|
||||
});
|
||||
|
||||
router.use("/api/*", (req, res, next) => {
|
||||
router.use("/api/*path", (req, res, next) => {
|
||||
res.set("Access-Control-Allow-Origin", "*"); //we'll allow it for now
|
||||
if (config["allow_getotheruser_without_cookie"] && req.originalUrl.split("\?")[0] === "/api/getotheruser") {
|
||||
next();
|
||||
return;
|
||||
}
|
||||
if (!server.increaseAPICall(req, res))return;
|
||||
if (!server.increaseAPICall(req, res)) return;
|
||||
|
||||
if (res.locals.username !== undefined) {
|
||||
next();
|
||||
|
@ -1,17 +1,17 @@
|
||||
import ejs from "ejs"
|
||||
import { LRUCache as LRU} from "lru-cache"
|
||||
import {minify as min_js} from "uglify-js"
|
||||
import { LRUCache as LRU } from "lru-cache"
|
||||
import { minify as min_js } from "uglify-js"
|
||||
import Clean from 'clean-css';
|
||||
import Minifier from 'html-minifier-terser';
|
||||
import { web_version } from "unsafe_encrypt";
|
||||
import {existsSync, readFileSync, readFile} from "fs"
|
||||
import { existsSync, readFileSync, readFile } from "fs"
|
||||
|
||||
export const setup = function (router, con, server) {
|
||||
|
||||
const increaseUSERCall = server.increaseUSERCall
|
||||
const dir = server.dirname + "/"
|
||||
|
||||
ejs.cache = new LRU({max:20})
|
||||
ejs.cache = new LRU({ max: 20 })
|
||||
|
||||
const load_var_cache = new LRU({
|
||||
max: 20,
|
||||
@ -31,7 +31,7 @@ export const setup = function (router, con, server) {
|
||||
}
|
||||
|
||||
if (!existsSync(filePath)) {
|
||||
console.log(1,'Tried loading non-existent file', filePath);
|
||||
console.log(1, 'Tried loading non-existent file', filePath);
|
||||
load_var_cache.set(filePath, '');
|
||||
return '';
|
||||
}
|
||||
@ -48,16 +48,16 @@ export const setup = function (router, con, server) {
|
||||
return output;
|
||||
}
|
||||
|
||||
function get_channels(){
|
||||
return new Promise(function(resolve, reject) {
|
||||
function get_channels() {
|
||||
return new Promise(function (resolve, reject) {
|
||||
let sql = `select post_receiver_name from ipost.posts where post_is_private = '0' group by post_receiver_name;`;
|
||||
con.query(sql, [], function (err, result) {
|
||||
if (err)reject(err)
|
||||
if (err) reject(err)
|
||||
|
||||
let out = []
|
||||
|
||||
for(let channel of result){
|
||||
if(channel.post_receiver_name === "")continue;
|
||||
for (let channel of result) {
|
||||
if (channel.post_receiver_name === "") continue;
|
||||
out[out.length] = channel.post_receiver_name
|
||||
}
|
||||
|
||||
@ -66,25 +66,25 @@ export const setup = function (router, con, server) {
|
||||
})
|
||||
}
|
||||
|
||||
const appId_Cache = new LRU({max:20,ttl: 1000 * 60 * 15}) //cache for 15 minutes
|
||||
const appId_Cache = new LRU({ max: 20, ttl: 1000 * 60 * 15 }) //cache for 15 minutes
|
||||
function getAppWithId(appid) {
|
||||
appid = Number(appid)
|
||||
return new Promise((res,rej) => {
|
||||
if(isNaN(appid)) {
|
||||
return new Promise((res, rej) => {
|
||||
if (isNaN(appid)) {
|
||||
res({})
|
||||
return
|
||||
}
|
||||
if(appId_Cache.has(appid)) {
|
||||
if (appId_Cache.has(appid)) {
|
||||
res(appId_Cache.get(appid) || {})
|
||||
return
|
||||
}
|
||||
con.query("SELECT * FROM ipost.application WHERE application_id=?",[appid],(err,result) => {
|
||||
if(err) {
|
||||
con.query("SELECT * FROM ipost.application WHERE application_id=?", [appid], (err, result) => {
|
||||
if (err) {
|
||||
console.error(err)
|
||||
rej({})
|
||||
return
|
||||
}
|
||||
appId_Cache.set(appid,result[0])
|
||||
appId_Cache.set(appid, result[0])
|
||||
res(result[0] || {})
|
||||
})
|
||||
})
|
||||
@ -101,7 +101,6 @@ export const setup = function (router, con, server) {
|
||||
getChannels: get_channels,
|
||||
encryptJS: min_js(web_version().toString()).code,
|
||||
cookiebanner: `<script id="cookieyes" type="text/javascript" src="https://cdn-cookieyes.com/client_data/3cf33f6b631f3587bf83813b/script.js" async></script>`,
|
||||
newrelic: load_var("./extra_modules/newrelic_monitor.html"),
|
||||
getPID: server.global_page_variables.getPID,
|
||||
getDMPID: server.global_page_variables.getDMPID,
|
||||
unauthorized_description: "Chat now by creating an account on IPost",
|
||||
@ -112,8 +111,8 @@ export const setup = function (router, con, server) {
|
||||
|
||||
|
||||
async function handleUserFiles(request, response, overrideurl) {
|
||||
if (!increaseUSERCall(request, response))return;
|
||||
if(typeof overrideurl !== "string")overrideurl = undefined;
|
||||
if (!increaseUSERCall(request, response)) return;
|
||||
if (typeof overrideurl !== "string") overrideurl = undefined;
|
||||
|
||||
let originalUrl = overrideurl
|
||||
|| request.params.file
|
||||
@ -123,10 +122,10 @@ export const setup = function (router, con, server) {
|
||||
if (existsSync(dir + "views/" + originalUrl)) {
|
||||
path = dir + "views/" + originalUrl
|
||||
//send .txt files as plaintext to help browsers interpret it correctly
|
||||
if(originalUrl.endsWith(".txt")) {
|
||||
if (originalUrl.endsWith(".txt")) {
|
||||
response.set('Content-Type', 'text/plain');
|
||||
readFile(path,(err,data)=> {
|
||||
if(err)return
|
||||
readFile(path, (err, data) => {
|
||||
if (err) return
|
||||
response.send(data)
|
||||
})
|
||||
return
|
||||
@ -142,25 +141,25 @@ export const setup = function (router, con, server) {
|
||||
path = dir + "views" + originalUrl + ".html"
|
||||
}
|
||||
|
||||
if(path !== "" && originalUrl !== "favicon.ico" && originalUrl !== "api_documentation" && originalUrl !== "api_documentation.html") {
|
||||
if (path !== "" && originalUrl !== "favicon.ico" && originalUrl !== "api_documentation" && originalUrl !== "api_documentation.html") {
|
||||
console.log(originalUrl)
|
||||
global_page_variables.user = { "username": response.locals.username, "bio": response.locals.bio, "avatar": response.locals.avatar }
|
||||
global_page_variables.query = request.query
|
||||
if(originalUrl === "authorize") {
|
||||
if (originalUrl === "authorize") {
|
||||
global_page_variables.application = await getAppWithId(request.query.id)
|
||||
}
|
||||
ejs.renderFile(path,global_page_variables,{async: true},async function(err,str){
|
||||
ejs.renderFile(path, global_page_variables, { async: true }, async function (err, str) {
|
||||
str = await str
|
||||
err = await err
|
||||
if(err) {
|
||||
console.log(1,err)
|
||||
if (err) {
|
||||
console.log(1, err)
|
||||
response.status(500)
|
||||
response.send("error")
|
||||
//TODO: make error page
|
||||
return
|
||||
}
|
||||
try {
|
||||
str = await Minifier.minify(str,{
|
||||
str = await Minifier.minify(str, {
|
||||
removeComments: true,
|
||||
removeCommentsFromCDATA: true,
|
||||
removeCDATASectionsFromCDATA: true,
|
||||
@ -171,36 +170,36 @@ export const setup = function (router, con, server) {
|
||||
useShortDoctype: true,
|
||||
removeEmptyAttributes: true
|
||||
})
|
||||
} catch(ignored){
|
||||
console.log(2,"error minifying",originalUrl);
|
||||
} catch (ignored) {
|
||||
console.log(2, "error minifying", originalUrl);
|
||||
}
|
||||
|
||||
try {
|
||||
response.send(str)
|
||||
} catch(err) {
|
||||
} catch (err) {
|
||||
console.error(err)
|
||||
}
|
||||
})
|
||||
return;
|
||||
}
|
||||
|
||||
if(originalUrl === "api_documentation" || originalUrl === "api_documentation.html") {
|
||||
if (originalUrl === "api_documentation" || originalUrl === "api_documentation.html") {
|
||||
response.set('Cache-Control', 'public, max-age=2592000');
|
||||
response.set('Content-Type', 'text/html')
|
||||
response.send(load_var("./views/api_documentation.html"))
|
||||
return
|
||||
}
|
||||
|
||||
if(originalUrl === "favicon.ico") {
|
||||
if (originalUrl === "favicon.ico") {
|
||||
response.set('Cache-Control', 'public, max-age=2592000');
|
||||
response.sendFile(dir + "/views/favicon.ico")
|
||||
return
|
||||
}
|
||||
|
||||
console.log(5,"no file found",originalUrl);
|
||||
console.log(5, "no file found", originalUrl);
|
||||
try {
|
||||
response.status(404).send("No file with that name found");
|
||||
} catch(err) {
|
||||
} catch (err) {
|
||||
console.error(err)
|
||||
}
|
||||
}
|
||||
@ -210,12 +209,12 @@ export const setup = function (router, con, server) {
|
||||
*/
|
||||
router.get("/", (req, res) => {
|
||||
req.params.file = "index"
|
||||
handleUserFiles(req,res,"/index")
|
||||
handleUserFiles(req, res, "/index")
|
||||
});
|
||||
|
||||
router.get("/:file", handleUserFiles);
|
||||
router.get("/:folder/:file", (req, res) => {
|
||||
req.params.file = req.params.folder+"/"+req.params.file
|
||||
handleUserFiles(req,res)
|
||||
req.params.file = req.params.folder + "/" + req.params.file
|
||||
handleUserFiles(req, res)
|
||||
});
|
||||
}
|
45
server.js
45
server.js
@ -1,5 +1,3 @@
|
||||
import "newrelic"
|
||||
|
||||
import http from "http";
|
||||
import express,{Router} from "express";
|
||||
import useragent from "express-useragent";
|
||||
@ -14,7 +12,6 @@ import { readFileSync, appendFile } from "fs";
|
||||
import { format } from "util";
|
||||
import { setup as SETUP_ROUTES} from "./routes/setup_all_routes.js"
|
||||
import { verify as verifyHCaptcha_int } from "hcaptcha"
|
||||
import hsts from "hsts"
|
||||
|
||||
import { ensureExists } from "./extra_modules/ensureExists.js"
|
||||
|
||||
@ -58,7 +55,7 @@ function log_info(level, ...info) {
|
||||
});
|
||||
}
|
||||
}
|
||||
console.log = log_info;
|
||||
//console.log = log_info;
|
||||
|
||||
|
||||
const hcaptcha_secret = config.hcaptcha_secret
|
||||
@ -263,24 +260,14 @@ app.use(fileUpload({
|
||||
}
|
||||
}));
|
||||
|
||||
const hstsMiddleware = hsts({
|
||||
maxAge: 31536000,
|
||||
includeSubDomains: true,
|
||||
preload: true
|
||||
})
|
||||
|
||||
app.use((req, res, next) => {
|
||||
app.use((_req, res, next) => {
|
||||
res.set("x-powered-by", "ipost");
|
||||
res.set("X-Frame-Options","DENY");
|
||||
res.set("X-XSS-Protection","1; mode=block");
|
||||
res.set("X-Content-Type-Options","nosniff");
|
||||
res.set("Referrer-Policy","no-referrer");
|
||||
|
||||
if (req.secure) {
|
||||
hstsMiddleware(req, res, next)
|
||||
} else {
|
||||
next()
|
||||
}
|
||||
})
|
||||
|
||||
app.use(bodyParser.default.json({ limit: "100mb" }));
|
||||
@ -312,19 +299,7 @@ app.use(function (_req, res, next) {
|
||||
next();
|
||||
});
|
||||
|
||||
//auto redirect to https
|
||||
app.use((req, res, next) => {
|
||||
if (req.secure) {
|
||||
//already secure
|
||||
next();
|
||||
}
|
||||
else {
|
||||
//redirect to https
|
||||
res.redirect('https://' + req.headers.host + req.url);
|
||||
}
|
||||
});
|
||||
|
||||
app.use("/*", function (req, res, next) {
|
||||
app.use("/*path", function (req, res, next) {
|
||||
for (let i = 0; i < blocked_headers.length; i++) {
|
||||
if (req.header(blocked_headers[i]) !== undefined) {
|
||||
res.json({ "error": "we don't allow proxies on our website." });
|
||||
@ -394,21 +369,9 @@ const httpServer = http.createServer(app);
|
||||
httpServer.listen(config["ports"]["http"], function () {
|
||||
console.log(5, "HTTP Server is listening");
|
||||
});
|
||||
const privateKey = readFileSync(config["ssl"]["privateKey"]).toString();
|
||||
const certificate = readFileSync(config["ssl"]["certificate"]).toString();
|
||||
const credentials = { key: privateKey, cert: certificate };
|
||||
var httpsServer;
|
||||
|
||||
import spdy from "spdy"
|
||||
|
||||
httpsServer = spdy.createServer(credentials,app)
|
||||
//httpsServer = https.createServer(credentials, app);
|
||||
httpsServer.listen(config["ports"]["https"], function () {
|
||||
console.log(5, "HTTPS Server is listening");
|
||||
});
|
||||
|
||||
wss = new WebSocket({
|
||||
server: httpsServer,
|
||||
server: httpServer,
|
||||
perMessageDeflate: {
|
||||
zlibDeflateOptions: {
|
||||
chunkSize: 1024,
|
||||
|
@ -4,8 +4,8 @@
|
||||
"only_prefer_when_ip": "::ffff:127.0.0.1",
|
||||
"mysql": {
|
||||
"connections":1000,
|
||||
"host":"localhost",
|
||||
"user":"root",
|
||||
"host":"db",
|
||||
"user":"ipost",
|
||||
"password_file":"mysql_password.txt"
|
||||
},
|
||||
"cookies": {
|
||||
@ -159,8 +159,8 @@
|
||||
"certificate" : "/etc/letsencrypt/live/ipost.rocks-0002/fullchain.pem"
|
||||
},
|
||||
"ports": {
|
||||
"http": 9999,
|
||||
"https": 9998
|
||||
"http": 80,
|
||||
"https": 443
|
||||
},
|
||||
"disallow_proxies_by_headers": true,
|
||||
"hcaptcha_secret": "0x0000000000000000000000000000000000000000",
|
||||
|
@ -4,7 +4,7 @@
|
||||
<meta charset="utf-8">
|
||||
<title>IPost Privacy Policy</title>
|
||||
<meta name="description" content="IPosts PrivacyPolicy">
|
||||
<%- newrelic %>
|
||||
|
||||
<script>
|
||||
<%- warnmessagejs %>
|
||||
</script>
|
||||
|
@ -3,7 +3,7 @@
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>IPost Terms of Service</title>
|
||||
<%- newrelic %>
|
||||
|
||||
<meta name="description" content="IPosts Terms of Service">
|
||||
<script src="/js/addnavbar.js" charset="utf-8"></script>
|
||||
<script src="/js/warn_message.js" charset="utf-8"></script>
|
||||
|
@ -11,7 +11,7 @@
|
||||
<% if(user.username === undefined) { %>
|
||||
<script> document.location.href = '/no_login?r='+encodeURIComponent(document.location.pathname) </script>
|
||||
<% } %>
|
||||
<%- newrelic %>
|
||||
|
||||
<style>
|
||||
<%- globalcss %>
|
||||
<%- loadfile("./css/posts.css") %>
|
||||
|
@ -4,7 +4,6 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>IPost</title>
|
||||
<meta name="description" content="<%-unauthorized_description%>">
|
||||
<%- newrelic %>
|
||||
<style>
|
||||
<%- globalcss %>
|
||||
<%- loadfile("./css/logon.css") %>
|
||||
|
@ -4,7 +4,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Login | IPost</title>
|
||||
<meta name="description" content="Chat on IPost by logging in today">
|
||||
<%- newrelic %>
|
||||
|
||||
<link rel="stylesheet" href="/css/logon.css">
|
||||
<script src="/js/warn_message.js" charset="utf-8"></script>
|
||||
<script src="/js/addnavbar.js" charset="utf-8"></script>
|
||||
|
@ -6,7 +6,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>USERS Page</title>
|
||||
<meta name="description" content="view other users pages on IPost today">
|
||||
<%- newrelic %>
|
||||
|
||||
<link rel="stylesheet" href="/css/style.css">
|
||||
<link rel="stylesheet" href="/css/global.css">
|
||||
<script src="/js/addnavbar.js" charset="utf-8"></script>
|
||||
|
@ -9,7 +9,7 @@
|
||||
<meta name="description" content="Chat on IPost now">
|
||||
<% } %>
|
||||
<title>Posts | IPost</title>
|
||||
<%- newrelic %>
|
||||
|
||||
<style>
|
||||
<%- globalcss %>
|
||||
<%- loadfile("./css/posts.css") %>
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en" dir="ltr">
|
||||
<head>
|
||||
<%- newrelic %>
|
||||
|
||||
<link rel="stylesheet" href="/css/logon.css">
|
||||
<script src="/js/warn_message.js" charset="utf-8"></script>
|
||||
<script src="/js/addnavbar.js" charset="utf-8"></script>
|
||||
|
@ -10,7 +10,7 @@
|
||||
<% } else { %>
|
||||
<meta name="description" content="search IPost now">
|
||||
<% } %>
|
||||
<%- newrelic %>
|
||||
|
||||
<link rel="stylesheet" href="/css/search.css">
|
||||
<script type="text/javascript" src="/js/htmlescape.js"></script>
|
||||
<link rel="stylesheet" href="/css/global.css">
|
||||
|
@ -13,7 +13,7 @@
|
||||
<% if(user.username === undefined) { %>
|
||||
<script> document.location.href = '/no_login?r='+encodeURIComponent(document.location.pathname) </script>
|
||||
<% } %>
|
||||
<%- newrelic %>
|
||||
|
||||
<link rel="stylesheet" href="/css/style.css">
|
||||
<link rel="stylesheet" href="/css/global.css">
|
||||
<script src="/js/addnavbar.js" charset="utf-8"></script>
|
||||
|
@ -13,7 +13,7 @@
|
||||
<% if(user.username === undefined) { %>
|
||||
<script> document.location.href = '/no_login?r='+encodeURIComponent(document.location.pathname) </script>
|
||||
<% } %>
|
||||
<%- newrelic %>
|
||||
|
||||
<style>
|
||||
<%- globalcss %>
|
||||
<%- loadfile("./css/style.css") %>
|
||||
|
Loading…
x
Reference in New Issue
Block a user