This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # Your network interface | |
| INTERFACE="end0" | |
| # Clear existing rules | |
| iptables -F | |
| iptables -t nat -F | |
| # Enable IP forwarding |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import crypto from 'crypto'; | |
| const validateTelegramAuth= async(authData) { | |
| const { hash, ...data } = authData; | |
| const dataCheckString = Object.keys(data) | |
| .sort() | |
| .map(k => `${k}=${data[k]}`) | |
| .join('\n'); | |
| console.log(dataCheckString,'dataCheckString') | |
| const secretKey = crypto.createHash('sha256') |