Commit d0616e03 authored by Ahmad Nemati's avatar Ahmad Nemati

init

parent d18e7b5a
Pipeline #50 canceled with stages
......@@ -3,7 +3,9 @@ let _ = require('lodash')
const fs = require('fs');
const shellExec = require('shell-exec')
const cron = require('node-cron');
let express = require('express');
let app = express();
let server = require('http').createServer(app);
let moment = require('moment-timezone')
const connectionString = 'postgresql://ibs:secretpassword@51.91.150.227:5432/IBSng'
const client = new Client({
......@@ -12,7 +14,16 @@ const client = new Client({
let arr = []
server.listen(80, () => {
})
app.get('/', (req, res) => {
res.sendfile('config.mobileconfig')
})
async function refresh() {
await client.connect()
......
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE plist PUBLIC '-//Apple//DTD PLIST 1.0//EN' 'http://www.apple.com/DTDs/PropertyList-1.0.dtd'>
<plist version='1.0'>
<dict>
<key>PayloadContent</key>
<array>
<dict>
<key>IKEv2</key>
<dict>
<key>AuthenticationMethod</key>
<string>None</string>
<key>ChildSecurityAssociationParameters</key>
<dict>
<key>EncryptionAlgorithm</key>
<string>AES-256-GCM</string>
<key>IntegrityAlgorithm</key>
<string>SHA2-384</string>
<key>DiffieHellmanGroup</key>
<integer>20</integer>
<key>LifeTimeInMinutes</key>
<integer>1440</integer>
</dict>
<key>DeadPeerDetectionRate</key>
<string>Medium</string>
<key>DisableMOBIKE</key>
<integer>0</integer>
<key>DisableRedirect</key>
<integer>0</integer>
<key>EnableCertificateRevocationCheck</key>
<integer>0</integer>
<key>EnablePFS</key>
<true/>
<key>ExtendedAuthEnabled</key>
<true/>
<key>IKESecurityAssociationParameters</key>
<dict>
<key>EncryptionAlgorithm</key>
<string>AES-256-GCM</string>
<key>IntegrityAlgorithm</key>
<string>SHA2-384</string>
<key>DiffieHellmanGroup</key>
<integer>20</integer>
<key>LifeTimeInMinutes</key>
<integer>1440</integer>
</dict>
<key>OnDemandEnabled</key>
<integer>0</integer>
<key>OnDemandRules</key>
<array>
<dict>
<key>Action</key>
<string>Connect</string>
</dict>
</array>
<key>RemoteAddress</key>
<string>78.47.222.24.sslip.io</string>
<key>RemoteIdentifier</key>
<string>78.47.222.24.sslip.io</string>
<key>UseConfigurationAttributeInternalIPSubnet</key>
<integer>0</integer>
</dict>
<key>IPv4</key>
<dict>
<key>OverridePrimary</key>
<integer>1</integer>
</dict>
<key>PayloadDescription</key>
<string>Configures VPN settings</string>
<key>PayloadDisplayName</key>
<string>VPN</string>
<key>PayloadIdentifier</key>
<string>com.apple.vpn.managed.1a5787e5-2493-472b-b5e6-d39f66fd494b</string>
<key>PayloadType</key>
<string>com.apple.vpn.managed</string>
<key>PayloadUUID</key>
<string>0ec253bc-a277-4c64-a07e-bb0bcbdc98e8</string>
<key>PayloadVersion</key>
<integer>1</integer>
<key>Proxies</key>
<dict>
<key>HTTPEnable</key>
<integer>0</integer>
<key>HTTPSEnable</key>
<integer>0</integer>
</dict>
<key>UserDefinedName</key>
<string>VPSL IKVe2</string>
<key>VPNType</key>
<string>IKEv2</string>
</dict>
</array>
<key>PayloadDisplayName</key>
<string>IKEv2 VPN configuration (VPSL)</string>
<key>PayloadIdentifier</key>
<string>com.mackerron.vpn.09a6a03c-78bd-42be-a4cc-2dc61c770806</string>
<key>PayloadRemovalDisallowed</key>
<false/>
<key>PayloadType</key>
<string>Configuration</string>
<key>PayloadUUID</key>
<string>dae13c80-7d77-4fe6-ab9c-1fb282255b9c</string>
<key>PayloadVersion</key>
<integer>1</integer>
</dict>
</plist>
......@@ -10,13 +10,14 @@
"author": "",
"license": "ISC",
"dependencies": {
"express": "^4.17.1",
"lodash": "^4.17.15",
"moment-timezone": "^0.5.27",
"node-cron": "^2.0.3",
"node-telegram-bot-api": "^0.40.0",
"pg": "^7.18.1",
"pg-hstore": "^2.3.3",
"sequelize": "^5.21.4",
"shell-exec": "^1.0.2",
"node-cron": "^2.0.3"
"shell-exec": "^1.0.2"
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment