最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

node.js - How to set mikrotik firewall setting through the API with NodeRed? - Stack Overflow

programmeradmin0浏览0评论

I would like to set firewall setting into Mikrotik with NodeRed. I installed Mikrotik extension, communication with Mikrotik is working, I'm able to read parameters or logs from Mikrotik, but I'm not able to write settings into the Mikrotik (for example some firewall settings).

Am I setting the parameters in the right way and is my input JSON in the right format?

Example of input JSON, which is comming into "mikrotik" NodeRed element:

const message = {
    "username": "*****",
    "password": "*****",
    "host": "****",
    "payload": {
        "command": [
        "ip/firewall/mangle/add",
        "=action=mark-packet",
        "=chain=postrouting",
        "=dst-address=****",
        "=new-packet-mark=dw-112233"
]}};

return message;

发布评论

评论列表(0)

  1. 暂无评论