aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2021-01-13 22:31:48 -0800
committerAdam Soltys <[email protected]>2021-01-13 22:31:48 -0800
commitb605dd257984d3384c680de2cf64e44bfd3484ca (patch)
tree17b6f26bc981ac6a3ace0aaabb809fe4d0d1061c
parent5cd96cc027be811116b147e0614aca39ce164c6b (diff)
downloadcoinos-server-b605dd257984d3384c680de2cf64e44bfd3484ca.tar.gz
coinos-server-b605dd257984d3384c680de2cf64e44bfd3484ca.zip
disable insecure endpoints
-rw-r--r--lib/send.js1
-rw-r--r--routes/assets.js2
-rw-r--r--routes/send.js1
-rw-r--r--routes/swaps.js1
4 files changed, 5 insertions, 0 deletions
diff --git a/lib/send.js b/lib/send.js
index b4fc9ac9..733c3cfb 100644
--- a/lib/send.js
+++ b/lib/send.js
@@ -1,6 +1,7 @@
const bolt11 = require("bolt11");
send = async (amount, memo, hash, user) => {
+ return res.status(500).send("Internal payments are temporarily disabled");
let payreq = bolt11.decode(hash);
if (!amount) amount = payreq.satoshis;
diff --git a/routes/assets.js b/routes/assets.js
index c36f6d69..ea3e82ff 100644
--- a/routes/assets.js
+++ b/routes/assets.js
@@ -286,6 +286,8 @@ app.post(
"/loadFaucet",
auth,
ah(async (req, res) => {
+ return res.status(500).send("Faucet feature temporarily disabled");
+
const { user } = req;
const { asset, amount } = req.body;
amount = parseInt(amount);
diff --git a/routes/send.js b/routes/send.js
index c7c3c30f..8a183183 100644
--- a/routes/send.js
+++ b/routes/send.js
@@ -2,6 +2,7 @@ const axios = require("axios");
const uuidv4 = require("uuid/v4");
module.exports = ah(async (req, res, next) => {
+ return res.status(500).send("Internal payments are temporarily disabled");
let { amount, asset, memo, username } = req.body;
let { user } = req;
amount = parseInt(amount);
diff --git a/routes/swaps.js b/routes/swaps.js
index b4d75b60..7311629c 100644
--- a/routes/swaps.js
+++ b/routes/swaps.js
@@ -450,6 +450,7 @@ app.post(
"/orders",
auth,
ah(async (req, res) => {
+ return res.status(500).send("Trading temporarily disabled");
const { user } = req;
try {
await swap(user, req.body);