Fapro - Free, Cross-platform, Single-file mass network protocol server simulator

FaPro is a Fake Protocol Server tool, Can easily start or stop multiple network services.

The goal is to support as many protocols as possible, and support as many deep interactions as possible for each protocol.

  • Supported Running Modes:
    • Local Machine
    • Virtual Network
  • Supported Protocols:
    • DNS
    • DCE/RPC
    • EIP
    • Elasticsearch
    • FTP
    • HTTP
    • IEC 104
    • Memcached
    • Modbus
    • MQTT
    • MySQL
    • RDP
    • Redis
    • S7
    • SMB
    • SMTP
    • SNMP
    • SSH
    • Telnet
    • VNC
    • IMAP
    • POP3
  • Use TcpForward to forward network traffic
  • Support tcp syn logging

Protocol simulation demos


Support credssp ntlmv2 nla authentication.

Support to configure the image displayed when user login.


Support user login.

Support fake terminal commands, such as id, uid, whoami, etc.

Account format: username:password:home:uid


Support user login and interaction.


Support sql statement query interaction


Support website clone, You need to install the chrome browser and chrome driver to work.

Quick Start

Generate Config

The configuration of all protocols and parameters is generated by genConfig subcommand.

Use subnet to generate the configuration file:

fapro genConfig -n > fapro.json

Or use local address instead of the virtual network:

fapro genConfig > fapro.json

Run the protocol simulator

Run FaPro in verbose mode and start the web service on port 8080:

fapro run -v -l :8080

Tcp syn logging

For windows users, please install winpcap or npcap.

Log analysis

Use ELK to analyze protocol logs:


This section contains the sample configuration used by FaPro.

{     "version": "0.38",     "network": "",     "network_build": "localhost",     "storage": null,     "geo_db": "/tmp/geoip_city.mmdb",     "hostname": "fapro1",     "use_logq": true,     "cert_name": "unknown",     "syn_dev": "any",     "exclusions": [],     "hosts": [         {             "ip": "",             "handlers": [                 {                     "handler": "dcerpc",                     "port": 135,                     "params": {                         "accounts": [                             "administrator:123456",                         ],                         "domain_name": "DESKTOP-Q1Test"                     }                 }             ]         }     ]}
  • version: Configuration version.
  • network: The subnet used by the virtual network or the address bound to the local machine(Local mode).
  • network_build: Network mode(supported value: localhost, all, userdef)
    • localhost: Local mode, all services are listening on the local machine
    • all: Create all hosts in the subnet(i.e., Can ping all the host in the subnet)
    • userdef: Create only the hosts specified in the hosts configuration.
  • storage: Specify the storage used for log collection, support sqlite, mysql, elasticsearch. e.g.
  • geo_db: MaxMind geoip2 database file path, used to generate ip geographic location information. if you use Elasticsearch storage, never need this field, it will be automatically generated using the geoip processor of Elasticsearch.
  • hostname: Specify the host field in the log.
  • use_logq: Use local disk message queue to save logs, and then send it to remote mysql or Elasticsearch to prevent remote log loss.
  • cert_name: Common name of the generated certificate.
  • syn_dev: Specify the network interface used to capture tcp syn packets. If it is empty, the tcp syn packet will not be recorded. On windows, the device name is like "\Device\NPF_{xxxx-xxxx}".
  • exclusions: Exclude remote ips from logs.
  • hosts: Each item is a host configuration.
  • handlers: Service configuration, the service configured on the host, each item is a service configuration.
  • handler: Service name (i.e., protocol name)
  • params: Set the parameters supported by the service.


Create a virtual network, The subnet is, include 2 hosts, run dns, ssh service,

and run rpc, rdp service,

protocol access logs are saved to elasticsearch, exclude the access log of

{    "version": "0.38",    "network": "",    "network_build": "userdef",    "storage": "es://",    "use_logq": true,    "cert_name": "unknown",    "syn_dev": "any",    "geo_db": "",    "exclusions": [""],    "hosts": [        {            "ip": "",            "handlers": [               {                    "handler": "dns",                    "port": 53,                    "params": {                        "accounts": [                            "admin:123456"                        ],                        "appname": "domain"                    }                },                {                    "handler": "ssh",                    "port": 22,                    "params": {                        "accounts": [                            "root:5555555:/root:0"                        ],                        "prompt": "$ ",                        "server_version": "SSH-2.0-OpenSSH_7.4"                    }                }            ]        },        {            "ip": "",            "handlers": [                {                    "handler": "dcerpc",                    "port": 135,                    "params": {                        "accounts": [                            "administrator:123456"                        ],                        "domain_name": "DESKTOP-Q1Test"                    }                },                {                    "handler": "rdp",                    "port": 3389,                    "params": {                        "accounts": [                              "administrator:123456"                        ],                        "auth": false,                        "domain_name": "DESKTOP-Q1Test",                        "image": "rdp.jpg",                        "sec_layer": "auto"                    }                }            ]        }    ]}


We have collected some frequently asked questions. Before reporting an issue, please search if the FAQ has the answer to your problem.

  • Issues are welcome.

Disqus Comments