Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- [
- {
- "id": "4d5b1b3eb1517a78",
- "type": "tab",
- "label": "Beispiele socat per NodeRed steuern ",
- "disabled": false,
- "info": "",
- "env": []
- },
- {
- "id": "876dee6ba2d35660",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": "nslookup <DynDNS Fritzbox> 8.8.8.8 | grep Address | sed '/2a/!d' | cut -f2 -d\" \"",
- "addpay": "",
- "append": "",
- "useSpawn": "false",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "DNS Abfrage 8.8.8.8 <DynDNS Fritzbox> (anpassen)",
- "x": 400,
- "y": 160,
- "wires": [
- [
- "11beb8016d0b5e26"
- ],
- [],
- []
- ]
- },
- {
- "id": "cac41083a5adb355",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "Stimmt DNS Eintrag mit DynDNS Adresse überein?",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "",
- "payloadType": "date",
- "x": 230,
- "y": 60,
- "wires": [
- [
- "876dee6ba2d35660"
- ]
- ]
- },
- {
- "id": "8c914d77f76f3f6e",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": " ping -c 1 <DynDNS Fritzbox> | grep 64 | cut -f4 -d\" \"",
- "addpay": "",
- "append": "",
- "useSpawn": "false",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "anpassen",
- "x": 360,
- "y": 320,
- "wires": [
- [
- "0e14328f0895e5fd"
- ],
- [],
- []
- ]
- },
- {
- "id": "0e14328f0895e5fd",
- "type": "string",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "methods": [
- {
- "name": "trim",
- "params": []
- },
- {
- "name": "delRightMost",
- "params": [
- {
- "type": "str",
- "value": ":"
- }
- ]
- }
- ],
- "prop": "payload",
- "propout": "payload",
- "object": "msg",
- "objectout": "msg",
- "x": 710,
- "y": 340,
- "wires": [
- [
- "131976dd082b3dce"
- ]
- ]
- },
- {
- "id": "11beb8016d0b5e26",
- "type": "change",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "rules": [
- {
- "t": "move",
- "p": "payload",
- "pt": "msg",
- "to": "payload.dns",
- "tot": "msg"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 760,
- "y": 140,
- "wires": [
- [
- "e6f0ce50c00330dc"
- ]
- ]
- },
- {
- "id": "131976dd082b3dce",
- "type": "change",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "rules": [
- {
- "t": "move",
- "p": "payload",
- "pt": "msg",
- "to": "payload.ping",
- "tot": "msg"
- }
- ],
- "action": "",
- "property": "",
- "from": "",
- "to": "",
- "reg": false,
- "x": 920,
- "y": 340,
- "wires": [
- [
- "ed5c4e8d1225733f",
- "11965dd6ecbde4fe"
- ]
- ]
- },
- {
- "id": "e6f0ce50c00330dc",
- "type": "string",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "methods": [
- {
- "name": "trim",
- "params": []
- },
- {
- "name": "toString",
- "params": []
- }
- ],
- "prop": "payload.dns",
- "propout": "payload.dns",
- "object": "msg",
- "objectout": "msg",
- "x": 970,
- "y": 140,
- "wires": [
- [
- "1f4a0ff1dfa845f5",
- "8c914d77f76f3f6e"
- ]
- ]
- },
- {
- "id": "1f4a0ff1dfa845f5",
- "type": "persist in",
- "z": "4d5b1b3eb1517a78",
- "name": "dns",
- "storageNode": "0b7396de8c7b10ea",
- "x": 1150,
- "y": 140,
- "wires": []
- },
- {
- "id": "11965dd6ecbde4fe",
- "type": "persist out",
- "z": "4d5b1b3eb1517a78",
- "name": "dns",
- "storageNode": "0b7396de8c7b10ea",
- "x": 1130,
- "y": 280,
- "wires": [
- [
- "ed5c4e8d1225733f"
- ]
- ]
- },
- {
- "id": "ed5c4e8d1225733f",
- "type": "join",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "mode": "custom",
- "build": "merged",
- "property": "payload",
- "propertyType": "msg",
- "key": "topic",
- "joiner": "\\n",
- "joinerType": "str",
- "useparts": false,
- "accumulate": true,
- "timeout": "",
- "count": "2",
- "reduceRight": false,
- "reduceExp": "",
- "reduceInit": "",
- "reduceInitType": "",
- "reduceFixup": "",
- "x": 1270,
- "y": 340,
- "wires": [
- [
- "a840f80d2f87193a"
- ]
- ]
- },
- {
- "id": "5ba5fd2de3382e1b",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "Adressen identisch",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 1890,
- "y": 300,
- "wires": []
- },
- {
- "id": "a840f80d2f87193a",
- "type": "switch",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "property": "payload.dns",
- "propertyType": "msg",
- "rules": [
- {
- "t": "eq",
- "v": "payload.ping",
- "vt": "msg"
- },
- {
- "t": "neq",
- "v": "payload.ping",
- "vt": "msg"
- }
- ],
- "checkall": "true",
- "repair": false,
- "outputs": 2,
- "x": 1470,
- "y": 340,
- "wires": [
- [
- "73682970992de318"
- ],
- [
- "ab8e91c439e145bc"
- ]
- ]
- },
- {
- "id": "61bdc285efd8d6aa",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "Adressen nicht identisch",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 1910,
- "y": 380,
- "wires": []
- },
- {
- "id": "73682970992de318",
- "type": "delay",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "pauseType": "rate",
- "timeout": "5",
- "timeoutUnits": "seconds",
- "rate": "1",
- "nbRateUnits": "10",
- "rateUnits": "second",
- "randomFirst": "1",
- "randomLast": "5",
- "randomUnits": "seconds",
- "drop": true,
- "allowrate": false,
- "outputs": 1,
- "x": 1650,
- "y": 300,
- "wires": [
- [
- "5ba5fd2de3382e1b"
- ]
- ]
- },
- {
- "id": "ab8e91c439e145bc",
- "type": "delay",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "pauseType": "rate",
- "timeout": "5",
- "timeoutUnits": "seconds",
- "rate": "1",
- "nbRateUnits": "10",
- "rateUnits": "second",
- "randomFirst": "1",
- "randomLast": "5",
- "randomUnits": "seconds",
- "drop": true,
- "allowrate": false,
- "outputs": 1,
- "x": 1650,
- "y": 380,
- "wires": [
- [
- "61bdc285efd8d6aa"
- ]
- ]
- },
- {
- "id": "5633222dd0518f66",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": "ss | grep <Wireguardport>",
- "addpay": "",
- "append": "",
- "useSpawn": "false",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "anpassen",
- "x": 460,
- "y": 640,
- "wires": [
- [
- "866be17aabd72bb2"
- ],
- [],
- [
- "c4cbb2f39d591359"
- ]
- ]
- },
- {
- "id": "1dd18e8d20d47eb9",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "Welche externe IPv4 ist mit der Weiterleitung verbunden?",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "",
- "payloadType": "date",
- "x": 270,
- "y": 540,
- "wires": [
- [
- "5633222dd0518f66"
- ]
- ]
- },
- {
- "id": "866be17aabd72bb2",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 22",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "payload",
- "targetType": "msg",
- "statusVal": "",
- "statusType": "auto",
- "x": 900,
- "y": 620,
- "wires": []
- },
- {
- "id": "c4cbb2f39d591359",
- "type": "switch",
- "z": "4d5b1b3eb1517a78",
- "name": "",
- "property": "payload.code",
- "propertyType": "msg",
- "rules": [
- {
- "t": "eq",
- "v": "0",
- "vt": "num"
- },
- {
- "t": "eq",
- "v": "1",
- "vt": "num"
- }
- ],
- "checkall": "true",
- "repair": false,
- "outputs": 2,
- "x": 710,
- "y": 700,
- "wires": [
- [
- "976a74b6c5ca1686"
- ],
- [
- "0f82f97f65912977"
- ]
- ]
- },
- {
- "id": "d10a60c5aeca5896",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": "ps -e | grep socat",
- "addpay": "",
- "append": "",
- "useSpawn": "false",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "",
- "x": 1450,
- "y": 620,
- "wires": [
- [
- "f7a17d871374e112"
- ],
- [],
- []
- ]
- },
- {
- "id": "c6f5ef6e407708ad",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "Wieviele socatinstanzen laufen?",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "",
- "payloadType": "date",
- "x": 1210,
- "y": 500,
- "wires": [
- [
- "d10a60c5aeca5896"
- ]
- ]
- },
- {
- "id": "976a74b6c5ca1686",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 23",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 920,
- "y": 680,
- "wires": []
- },
- {
- "id": "0f82f97f65912977",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 24",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 920,
- "y": 720,
- "wires": []
- },
- {
- "id": "f7a17d871374e112",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 25",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 1660,
- "y": 600,
- "wires": []
- },
- {
- "id": "e9d78837d3b0c9da",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": "",
- "addpay": "payload",
- "append": "",
- "useSpawn": "true",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "",
- "x": 1610,
- "y": 740,
- "wires": [
- [
- "7ec7c921f85e56e3"
- ],
- [
- "28adc4ff04072698"
- ],
- [
- "5c2b31536a6964e4"
- ]
- ]
- },
- {
- "id": "7ec7c921f85e56e3",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 26",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "statusVal": "",
- "statusType": "auto",
- "x": 1860,
- "y": 720,
- "wires": []
- },
- {
- "id": "488c9cf0f75de5d9",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "socat stop",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "killall -9 socat",
- "payloadType": "str",
- "x": 1220,
- "y": 780,
- "wires": [
- [
- "e9d78837d3b0c9da"
- ]
- ]
- },
- {
- "id": "086d1081f65d72c6",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "socat start UDP <Wireguardport> anpassen",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "socat UDP4-LISTEN:<Wireguardport>,fork,reuseaddr UDP6:[IPv6 der Fritzbox]:<Wireguardport>",
- "payloadType": "str",
- "x": 1310,
- "y": 720,
- "wires": [
- [
- "e9d78837d3b0c9da"
- ]
- ]
- },
- {
- "id": "28adc4ff04072698",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 27",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "statusVal": "",
- "statusType": "auto",
- "x": 1860,
- "y": 760,
- "wires": []
- },
- {
- "id": "5c2b31536a6964e4",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 28",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "false",
- "statusVal": "",
- "statusType": "auto",
- "x": 1860,
- "y": 800,
- "wires": []
- },
- {
- "id": "3b9efd9110859db1",
- "type": "exec",
- "z": "4d5b1b3eb1517a78",
- "command": "ip addr show <z,B, ens6 muss angepasst werden> | grep inet",
- "addpay": "",
- "append": "",
- "useSpawn": "false",
- "timer": "",
- "winHide": false,
- "oldrc": false,
- "name": "Name der Netzwerkkarte muss angepasst werden (z.B. \"eth0\", \"ens6\" etc)",
- "x": 640,
- "y": 880,
- "wires": [
- [
- "3677de3b8bd5cb58"
- ],
- [],
- []
- ]
- },
- {
- "id": "3677de3b8bd5cb58",
- "type": "debug",
- "z": "4d5b1b3eb1517a78",
- "name": "debug 29",
- "active": true,
- "tosidebar": true,
- "console": false,
- "tostatus": false,
- "complete": "true",
- "targetType": "full",
- "statusVal": "",
- "statusType": "auto",
- "x": 1180,
- "y": 880,
- "wires": []
- },
- {
- "id": "5e1b950bc36fcccf",
- "type": "inject",
- "z": "4d5b1b3eb1517a78",
- "name": "IP Adressen vServer abfragen",
- "props": [
- {
- "p": "payload"
- },
- {
- "p": "topic",
- "vt": "str"
- }
- ],
- "repeat": "",
- "crontab": "",
- "once": false,
- "onceDelay": 0.1,
- "topic": "",
- "payload": "",
- "payloadType": "date",
- "x": 180,
- "y": 880,
- "wires": [
- [
- "3b9efd9110859db1"
- ]
- ]
- },
- {
- "id": "0b7396de8c7b10ea",
- "type": "persist-store",
- "filename": "dns.json",
- "interval": "60"
- }
- ]
Advertisement
Add Comment
Please, Sign In to add comment