Shitty-IP-grabber/index.js
2024-12-04 15:07:00 -06:00

15 lines
No EOL
393 B
JavaScript

const express = require("express")
const PORT = process.env.PORT || 8080
var app = express()
app.listen(PORT, () => {
console.log("Shit ass dumb ip grabber is on port " + PORT)
})
app.set('trust proxy', true)
app.get("*", (req, res) => {
console.log("This motherfucker's IP is " + req.ip || req.ips || req.headers['x-forwarded-for'] || req.socket.remoteAddress || req.hostname)
})