#1# Copyright (c) 2006-2025 Wade Alcorn - [email protected]2# Browser Exploitation Framework (BeEF) - https://beefproject.com3# See the file 'doc/COPYING' for copying permission4#5# BeEF Configuration file67beef:8version: '0.5.1.0'9# More verbose messages (server-side)10debug: false11# More verbose messages (client-side)12client_debug: false13# Used for generating secure tokens14crypto_default_value_length: 801516# Credentials to authenticate in BeEF.17# Used by both the RESTful API and the Admin interface18credentials:19user: "beef"20passwd: "beef"2122# Interface / IP restrictions23restrictions:24# subnet of IP addresses that can hook to the framework25permitted_hooking_subnet: ["0.0.0.0/0", "::/0"]26# subnet of IP addresses that can connect to the admin UI27#permitted_ui_subnet: ["127.0.0.1/32", "::1/128"]28permitted_ui_subnet: ["0.0.0.0/0", "::/0"]29# subnet of IP addresses that cannot be hooked by the framework30excluded_hooking_subnet: []31# slow API calls to 1 every api_attempt_delay seconds32api_attempt_delay: "0.05"3334# HTTP server35http:36debug: false #Thin::Logging.debug, very verbose. Prints also full exception stack trace.37host: "0.0.0.0"38port: "3000"3940# Decrease this setting to 1,000 (ms) if you want more responsiveness41# when sending modules and retrieving results.42# NOTE: A poll timeout of less than 5,000 (ms) might impact performance43# when hooking lots of browsers (50+).44# Enabling WebSockets is generally better (beef.websocket.enable)45xhr_poll_timeout: 10004647# Host Name / Domain Name48# If you want BeEF to be accessible via hostname or domain name (ie, DynDNS),49# set the public hostname below:50#public: "" # public hostname/IP address5152# Reverse Proxy / NAT53# If you want BeEF to be accessible behind a reverse proxy or NAT,54# set both the publicly accessible hostname/IP address and port below:55# NOTE: Allowing the reverse proxy will enable a vulnerability where the ui/panel can be spoofed56# by altering the X-FORWARDED-FOR ip address in the request header.57allow_reverse_proxy: false5859# Public settings60# These settings will be used to create a public facing URL61# This public facing URL will be used for all hook related calls62public:63host: "example.com"64port: 44365https: true # public hostname/IP address66#public_port: "" # public port (experimental)6768# Hook69hook_file: "/hook.js"70hook_session_name: "BEEFHOOK"7172# Allow one or multiple origins to access the RESTful API using CORS73# For multiple origins use: "http://browserhacker.com, http://domain2.com"74restful_api:75allow_cors: false76cors_allowed_origins: "http://browserhacker.com"7778# Prefer WebSockets over XHR-polling when possible.79websocket:80enable: false81port: 61985 # WS: good success rate through proxies82# Use encrypted 'WebSocketSecure'83# NOTE: works only on HTTPS domains and with HTTPS support enabled in BeEF84secure: true85secure_port: 61986 # WSSecure86ws_poll_timeout: 5000 # poll BeEF every x second, this affects how often the browser can have a command execute on it87ws_connect_timeout: 500 # useful to help fingerprinting finish before establishing the WS channel8889# Imitate a specified web server (default root page, 404 default error page, 'Server' HTTP response header)90web_server_imitation:91enable: true92type: "apache" # Supported: apache, iis, nginx93hook_404: false # inject BeEF hook in HTTP 404 responses94hook_root: false # inject BeEF hook in the server home page95# Experimental HTTPS support for the hook / admin / all other Thin managed web services96https:97enable: false98# Enabled this config setting if you're external facing uri is using https99public_enabled: false100# In production environments, be sure to use a valid certificate signed for the value101# used in beef.http.public (the domain name of the server where you run BeEF)102key: "beef_key.pem"103cert: "beef_cert.pem"104105database:106file: "beef.db"107108# Autorun Rule Engine109autorun:110# this is used when rule chain_mode type is nested-forward, needed as command results are checked via setInterval111# to ensure that we can wait for async command results. The timeout is needed to prevent infinite loops or eventually112# continue execution regardless of results.113# If you're chaining multiple async modules, and you expect them to complete in more than 5 seconds, increase the timeout.114result_poll_interval: 300115result_poll_timeout: 5000116117# If the modules doesn't return status/results and timeout exceeded, continue anyway with the chain.118# This is useful to call modules (nested-forward chain mode) that are not returning their status/results.119continue_after_timeout: true120121# Enables DNS lookups on zombie IP addresses122dns_hostname_lookup: false123124# IP Geolocation125# NOTE: requires MaxMind database. Run ./updated-geoipdb to install.126geoip:127enable: true128database: '/opt/GeoIP/GeoLite2-City.mmdb'129130# You may override default extension configuration parameters here131# Note: additional experimental extensions are available in the 'extensions' directory132# and can be enabled via their respective 'config.yaml' file133extension:134admin_ui:135enable: true136base_path: "/ui"137demos:138enable: true139events:140enable: true141evasion:142enable: false143requester:144enable: true145proxy:146enable: true147network:148enable: true149metasploit:150enable: false151social_engineering:152enable: true153xssrays:154enable: true155156157