| | 1 | = Build Instructions = |
| | 2 | |
| | 3 | == Development environment description == |
| | 4 | |
| | 5 | The prototype is implemented as a web application. |
| | 6 | |
| | 7 | Required software: |
| | 8 | |
| | 9 | * Python 3.11 or newer |
| | 10 | * SQLite 3 |
| | 11 | * Git |
| | 12 | * Visual Studio Code or PyCharm (recommended) |
| | 13 | * Modern web browser (Google Chrome, Microsoft Edge or Mozilla Firefox) |
| | 14 | |
| | 15 | Python libraries: |
| | 16 | |
| | 17 | * Flask |
| | 18 | * Flask-CORS |
| | 19 | * Requests |
| | 20 | * python-dotenv |
| | 21 | * Grafana client libraries (if configured) |
| | 22 | |
| | 23 | The database used by the prototype is ''lan_logs_sysmon.db''. |
| | 24 | |
| | 25 | ---- |
| | 26 | |
| | 27 | == Build instructions == |
| | 28 | |
| | 29 | 1. Clone the project repository. |
| | 30 | |
| | 31 | {{{ |
| | 32 | git clone https://github.com/istevanoska/NETIntel |
| | 33 | cd Proekt_Wazuh |
| | 34 | }}} |
| | 35 | |
| | 36 | 2. Create and activate a virtual environment. |
| | 37 | |
| | 38 | Windows: |
| | 39 | |
| | 40 | {{{ |
| | 41 | python -m venv .venv |
| | 42 | .venv\Scripts\activate |
| | 43 | }}} |
| | 44 | |
| | 45 | Linux/macOS: |
| | 46 | |
| | 47 | {{{ |
| | 48 | python3 -m venv .venv |
| | 49 | source .venv/bin/activate |
| | 50 | }}} |
| | 51 | |
| | 52 | 3. Install all required dependencies. |
| | 53 | |
| | 54 | {{{ |
| | 55 | pip install -r requirements.txt |
| | 56 | }}} |
| | 57 | |
| | 58 | 4. Start the server. |
| | 59 | |
| | 60 | {{{ |
| | 61 | python server.py |
| | 62 | }}} |
| | 63 | |
| | 64 | The server starts on: |
| | 65 | |
| | 66 | {{{ |
| | 67 | http://localhost:5555 |
| | 68 | }}} |
| | 69 | |
| | 70 | If the database does not exist, it is automatically created when the server starts. |
| | 71 | |
| | 72 | 5. Start the frontend. |
| | 73 | |
| | 74 | {{{ |
| | 75 | cd lan-frontend |
| | 76 | npm run dev |
| | 77 | }}} |
| | 78 | |
| | 79 | Starts on: |
| | 80 | {{{ |
| | 81 | http://localhost:5173 |
| | 82 | }}} |
| | 83 | |
| | 84 | |
| | 85 | |
| | 86 | 6. Start the client. |
| | 87 | |
| | 88 | {{{ |
| | 89 | python sctry.py |
| | 90 | }}} |
| | 91 | |
| | 92 | You should enter the ip address from the server, provived in the terminal where you started the server. |
| | 93 | Enter the token you have generated, from the admin panel for the environment. |
| | 94 | |
| | 95 | {{{ |
| | 96 | http://localhost:5555 |
| | 97 | }}} |
| | 98 | |
| | 99 | |
| | 100 | |
| | 101 | ---- |
| | 102 | |
| | 103 | == Testing instructions == |
| | 104 | |
| | 105 | Open the application in a web browser: |
| | 106 | |
| | 107 | {{{ |
| | 108 | http://localhost:5555 |
| | 109 | }}} |
| | 110 | |
| | 111 | Login using a valid user account. |
| | 112 | |
| | 113 | After successful login the following prototype functionalities can be tested: |
| | 114 | |
| | 115 | * Dashboard – overview of all monitored computers |
| | 116 | * Computer Details – detailed information about a selected computer |
| | 117 | * Environment Management – create and manage environments and generate tokens |
| | 118 | * Agent Communication – send monitoring data from the client application |
| | 119 | * RAG / Chat – generate SQL queries from natural language questions |
| | 120 | |
| | 121 | Example questions for the Chat module: |
| | 122 | |
| | 123 | * Show all active processes for Ilina-laptop. |
| | 124 | * Show all security alerts. |
| | 125 | * Show the latest Sysmon events. |
| | 126 | * List all monitored computers. |
| | 127 | |
| | 128 | Mini guide: |
| | 129 | |
| | 130 | 1. Login to the application. |
| | 131 | 2. Open the Dashboard. |
| | 132 | 3. Select a monitored computer. |
| | 133 | 4. View system metrics, running processes and security events. |
| | 134 | 5. Open Environment Management if administrator privileges are available. |
| | 135 | 6. Open the Chat page and ask a question in natural language. |
| | 136 | 7. Review the generated SQL query and the returned results. |
| | 137 | |
| | 138 | ---- |
| | 139 | |
| | 140 | == Source code == |
| | 141 | |
| | 142 | The repository contains: |
| | 143 | |
| | 144 | * Complete application source code |
| | 145 | * Flask backend |
| | 146 | * Frontend source code |
| | 147 | * SQL scripts for creating the database schema |
| | 148 | * SQL scripts containing sample data |
| | 149 | * Documentation for the project |
| | 150 | |
| | 151 | All source code required to build and run the prototype is available in the DEVELOP repository. |