{"id":19141299,"url":"https://github.com/ans-group/fnm-webui","last_synced_at":"2025-05-06T23:40:34.775Z","repository":{"id":37961917,"uuid":"174179641","full_name":"ans-group/fnm-webui","owner":"ans-group","description":"A web-based UI to manage multiple Fastnetmon Advanced instances.","archived":false,"fork":false,"pushed_at":"2023-04-18T10:29:19.000Z","size":489,"stargazers_count":43,"open_issues_count":12,"forks_count":16,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-04-19T16:11:06.081Z","etag":null,"topics":["dashboard","fastnetmon","laravel","php"],"latest_commit_sha":null,"homepage":"https://fastnetmon.com/fastnetmon-advanced/","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ans-group.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-03-06T16:22:15.000Z","updated_at":"2025-03-22T11:10:27.000Z","dependencies_parsed_at":"2024-11-09T07:22:43.597Z","dependency_job_id":"77b45889-0af6-499e-a64c-00b755fcf32e","html_url":"https://github.com/ans-group/fnm-webui","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ans-group%2Ffnm-webui","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ans-group%2Ffnm-webui/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ans-group%2Ffnm-webui/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ans-group%2Ffnm-webui/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ans-group","download_url":"https://codeload.github.com/ans-group/fnm-webui/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252788376,"owners_count":21804280,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dashboard","fastnetmon","laravel","php"],"created_at":"2024-11-09T07:22:34.240Z","updated_at":"2025-05-06T23:40:34.751Z","avatar_url":"https://github.com/ans-group.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FastNetMon WebUI\n\nFastnetmon describes itself as follows:\n\n\u003e FastNetMon is a very high performance DDoS detector built on top of multiple packet capture engines: NetFlow, IPFIX, sFlow and SPAN/port mirror. \n\u003e It could detect malicious traffic in your network and immediately block it with BGP blackhole or BGP flow spec rules. \n\nThe [Fastnetmon Advanced](https://fastnetmon.com/fastnetmon-advanced/) offers a number of additional features over the community edition, one of which is an API that can be used to pull data from your running FNM instances, and update their settings.\n\nThis project builds on top of the [Fastnetmon API](https://fastnetmon.com/fastnetmon-advanced-configuration-options/) to give a single-pane-of-glass interface for monitoring and managing your running FNM instances.\n\nThe WebUI is written in PHP 8, using the Laravel framework.\n\n## Demo\n\nWe don't have a demo hosted of this application, but some screenshots are available on the wiki:\n\nhttps://github.com/ukfast/fnm-webui/wiki/Screenshots\n\n## Requirements\n\nTo run the WebUI, you'll need either a [LEMP](https://www.howtoforge.com/tutorial/ubuntu-laravel-php-nginx/) or [LAMP](https://medium.com/@lazycoding/how-to-install-lamp-php-7-and-laravel-5-5-from-scratch-on-ubuntu-16-04-lts-c99949e4319c) stack server with appropriate Laravel rewrite rules in place.\n\n- Apache or NGINX\n- PHP 8.0\n- MySQL 5.6+ / MariaDB 10.0+\n- Redis 3.2+\n- Postfix / Sendmail\n\nThis could also probably be run within a shared hosting environment if you so wish.\n\nAs the nature of this project is to provide centralised management to your blackhole system, it makes sense to host this in a separate location so you always have access to the dashboard.\n\nNaturally, you will also need an installed Fastnetmon Advanced server with the API enabled to add into the interface.\n\n## Installation\n\n1. Clone down the files to your document root. Your server will need to reference the `public/` directory for it's root.\n2. Create a database in MySQL.\n3. Create a `GRANT` in MySQL for the new database.\n4. Copy the `.env.example` file to `.env` and update the following items:\n - `APP_KEY` - Generate a random key and update this. This is used for encryption.\n - `APP_URL` - Update this to match the installed location of the WebUI.\n - `DB_*` - Set the database connection string with the details created above.\n - `REDIS_*` - If you're hosting Redis separately, update this here.\n - `MAIL_*` - Update the mail configuration for notifications from the dashboard.\n - `ACTION_CC` - *(optional)* Set this if you want a static list of emails to be CC'ed into all ban / unban action notifications.\n5. Migrate the blank database schema into MySQL: `# php artisan migrate --seed`\n - This should also \"seed\" the database with two demo users to get logged in for the first time: https://github.com/ukfast/fnm-webui/blob/master/database/seeds/UsersTableSeeder.php\n\nIf you'd like to have the FNM WebUI log attack history, and send out notification emails when ban/unban actions are performed, you'll need to configure Fastnetmon to use a webhook to:\n\n`https://fnm.domain.com/webhook`\n\n...with your domain for the installation of this project swapped in.\n\n## Resolving incorrect FNM licence warning\n\nThe FastNetMon service will request a license when the service starts up, and this will have a lifetime of 14 days. While at the end of the 14 days, the licensing backend will renew your license (assuming it's been paid for), this is not reflected in the FCLI calls to `show license`.\n\nAs a result, the logic in FNM WebUI will determine after 14 days that your license has now expired, and an error message will be displayed.\n\nExample:\nhttps://github.com/ukfast/fnm-webui/blob/b8077f73ca9c1810045b89dba480f137e5c1466c/resources/views/dc/show.blade.php#L35\n\nAfter discussing this with FastNetMon support *(ref 2726)*, it has been confirmed that despite the incorrect date shown, the FNM instance is still active and would usually request a new license next time the service is restarted (or a FCLI `commit` is performed).\n\nAs of FastNetMon version 2.0.138, an additional FCLI call has been added to perform an online update of the license:\n\n```\n# sudo fcli show license\n{ \"address_ipv4\": \"192.168.1.100\", \"total_memory_size\": 7973, \"logical_cpus_number\": 4, \"cpu_model\": \"Intel(R) Core(TM)2 Quad CPU    Q8200  @ 2.33GHz\", \"expiration_date\": \"2019-04-13\", \"licensed_bandwidth\": 10000, \"issuer_type\": \"automatic\" }\n\n# sudo fcli set renew_license \n\n# sudo fcli show license\n{ \"address_ipv4\": \"192.168.1.100\", \"total_memory_size\": 7973, \"logical_cpus_number\": 4, \"cpu_model\": \"Intel(R) Core(TM)2 Quad CPU    Q8200  @ 2.33GHz\", \"expiration_date\": \"2019-04-17\", \"licensed_bandwidth\": 10000, \"issuer_type\": \"automatic\" }\n```\n\nThe recommendation is to perform the `fcli set renew_license` within a CRON on the FastNetMon server itself. To be sure it's always up to date, this would be best done every 7 days.\n\n## SQLSTATE[22001]: String data, right truncated: 1406 Data too long for column 'api_password'\n\nDetails of fixes for this issue can be found in [github issue 4](https://github.com/ans-group/fnm-webui/issues/4)\n\nFirst logon to mysql via the CLI and run:\n```\nMariaDB [(none)]\u003e use fnm\nMariaDB [fnm]\u003e ALTER TABLE dc MODIFY api_password VARCHAR(255);\n```\nNote: this assumes your database is called `fnm`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fans-group%2Ffnm-webui","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fans-group%2Ffnm-webui","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fans-group%2Ffnm-webui/lists"}