added README.md and LICENSE
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-Make (push) Successful in 2m11s
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-CMake (push) Successful in 29s
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-Meson (push) Successful in 31s
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-Make (push) Successful in 2m11s
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-CMake (push) Successful in 29s
Prepare Build and Testing executable binary / Prepare-Build-Testing-With-Meson (push) Successful in 31s
This commit is contained in:
@@ -0,0 +1,21 @@
|
|||||||
|
MIT License
|
||||||
|
|
||||||
|
Copyright (c) 2025 Openrouter
|
||||||
|
|
||||||
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is
|
||||||
|
furnished to do so, subject to the following conditions:
|
||||||
|
|
||||||
|
The above copyright notice and this permission notice shall be included in all
|
||||||
|
copies or substantial portions of the Software.
|
||||||
|
|
||||||
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||||
|
SOFTWARE.
|
||||||
@@ -0,0 +1,158 @@
|
|||||||
|
# OpenRouter
|
||||||
|
|
||||||
|
A modern C++ router management application providing a web-based interface for configuring and managing network router settings.
|
||||||
|
|
||||||
|
## Features
|
||||||
|
|
||||||
|
- **Web-based Interface**: Modern web UI for easy router configuration
|
||||||
|
- **Network Configuration**:
|
||||||
|
- WiFi settings management (SSID, password, channel, QR code generation)
|
||||||
|
- DNS server configuration
|
||||||
|
- SSH server management with key handling
|
||||||
|
- Telnet server configuration
|
||||||
|
- FTP server settings
|
||||||
|
- **System Management**:
|
||||||
|
- System reboot functionality
|
||||||
|
- Uptime monitoring
|
||||||
|
- System log access
|
||||||
|
- Firmware updates
|
||||||
|
- **Security**:
|
||||||
|
- Authentication system
|
||||||
|
- CORS security headers
|
||||||
|
- SSH key management
|
||||||
|
- **Backup & Restore**: Configuration backup and restore capabilities
|
||||||
|
- **QR Code Generation**: Generate QR codes for WiFi credentials
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
- C++20 compatible compiler (GCC 10+ or Clang 10+)
|
||||||
|
- CMake 3.6 or higher
|
||||||
|
- Make build system
|
||||||
|
- Linux-based system (for installation paths)
|
||||||
|
|
||||||
|
## Building from Source
|
||||||
|
|
||||||
|
### Using CMake
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake ..
|
||||||
|
make
|
||||||
|
```
|
||||||
|
|
||||||
|
### Using Make
|
||||||
|
|
||||||
|
```bash
|
||||||
|
make
|
||||||
|
```
|
||||||
|
|
||||||
|
### Using Meson
|
||||||
|
|
||||||
|
```bash
|
||||||
|
meson setup builddir
|
||||||
|
cd builddir
|
||||||
|
meson compile
|
||||||
|
```
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
After building, install the application:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo make install
|
||||||
|
```
|
||||||
|
|
||||||
|
This will install:
|
||||||
|
- `openrouter` binary to `/usr/bin/`
|
||||||
|
- Web interface files to `/usr/share/openrouter/web/`
|
||||||
|
|
||||||
|
## Configuration
|
||||||
|
|
||||||
|
The application uses JSON configuration files:
|
||||||
|
|
||||||
|
- `config.json`: Main configuration file
|
||||||
|
- `config_default.json`: Default configuration template
|
||||||
|
|
||||||
|
### Basic Configuration
|
||||||
|
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"server": {
|
||||||
|
"ip": "0.0.0.0",
|
||||||
|
"port": 8080
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
### Starting the Server
|
||||||
|
|
||||||
|
```bash
|
||||||
|
openrouter
|
||||||
|
```
|
||||||
|
|
||||||
|
The web interface will be available at `http://localhost:8080` (or the configured IP and port).
|
||||||
|
|
||||||
|
### API Endpoints
|
||||||
|
|
||||||
|
The application provides RESTful API endpoints for:
|
||||||
|
|
||||||
|
- **WiFi Management**: Configure wireless settings
|
||||||
|
- **DNS Settings**: Manage DNS servers and local domains
|
||||||
|
- **SSH Configuration**: Enable/disable SSH, manage keys and ports
|
||||||
|
- **Telnet Settings**: Configure telnet access
|
||||||
|
- **FTP Server**: Manage FTP server settings
|
||||||
|
- **System Operations**: Reboot, view logs, check uptime
|
||||||
|
- **Authentication**: User authentication and session management
|
||||||
|
|
||||||
|
## Development
|
||||||
|
|
||||||
|
### Project Structure
|
||||||
|
|
||||||
|
```
|
||||||
|
src/
|
||||||
|
├── openrouter.cpp # Main application entry point
|
||||||
|
├── OpenRouter/ # Core router functionality
|
||||||
|
├── settings/ # Configuration modules
|
||||||
|
│ ├── wifi/ # WiFi management
|
||||||
|
│ ├── dns/ # DNS configuration
|
||||||
|
│ ├── ssh/ # SSH server settings
|
||||||
|
│ ├── telnet/ # Telnet configuration
|
||||||
|
│ └── ftp/ # FTP server settings
|
||||||
|
├── system/ # System management
|
||||||
|
├── auth/ # Authentication system
|
||||||
|
├── security/ # Security features (CORS, etc.)
|
||||||
|
├── libs/ # Third-party libraries
|
||||||
|
└── web/ # Web interface files
|
||||||
|
```
|
||||||
|
|
||||||
|
### Building for Development
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mkdir build
|
||||||
|
cd build
|
||||||
|
cmake -DCMAKE_BUILD_TYPE=Debug ..
|
||||||
|
make
|
||||||
|
```
|
||||||
|
|
||||||
|
## Contributing
|
||||||
|
|
||||||
|
1. Fork the repository
|
||||||
|
2. Create a feature branch (`git checkout -b feature/amazing-feature`)
|
||||||
|
3. Commit your changes (`git commit -m 'Add some amazing feature'`)
|
||||||
|
4. Push to the branch (`git push origin feature/amazing-feature`)
|
||||||
|
5. Open a Pull Request
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
||||||
|
|
||||||
|
## Security
|
||||||
|
|
||||||
|
If you discover any security vulnerabilities, please report them responsibly by contacting the maintainers directly rather than opening a public issue.
|
||||||
|
|
||||||
|
## Support
|
||||||
|
|
||||||
|
For support, please open an issue in the project repository or contact the maintainers.
|
||||||
Reference in New Issue
Block a user