You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
410 B
15 lines
410 B
const express = require('express') |
|
const request = require('request'); |
|
const app = express() |
|
const port = 3000 |
|
|
|
app.listen(port, () => console.log(`Ushio-proxy listening at http://localhost:${port}`)) |
|
app.use(express.static(__dirname + '/public')); |
|
|
|
app.get('/get/', (req, res) => { |
|
|
|
if(req.query.hasOwnProperty('url')){ |
|
request(new Buffer(req.query.url, 'base64').toString()).pipe(res); |
|
} |
|
|
|
})
|
|
|