Skip to main content

Un serveur HTTP FastAPI pour récupérer les applications installées

Project description

Watchman HTTP Server

Watchman HTTP Server est un serveur FastAPI qui expose la liste des applications installées ainsi que des informations sur le système.

Installation

Installez le package via pip :

pip install watchman_http_server

Ou depuis le code source :

git clone https://github.com/votre-repo/watchman_http_server.git
cd watchman_http_server
pip install -e .

Utilisation

Lancer le serveur avec un port et une clé API spécifiés :

watchman-server --port 8000 --api-key "VOTRE_CLE_API"

Configuration

  • --port : Définit le port d'écoute du serveur (par défaut : 8001).
  • --api-key : Spécifie la clé API requise pour accéder aux endpoints.

Endpoints

GET /apps

Retourne la liste des applications installées et les informations du système.

Headers requis

WATCHMAN-API-KEY: VOTRE_CLE_API

Exemple de réponse

{
  "system_info": {
    "hostname": "mon-pc",
    "ip": "192.168.1.10",
    "mac": "A1:B2:C3:D4:E5:F6",
    "architecture": "x86_64",
    "os": "Windows 10"
  },
  "applications": [
    {
      "name": "Google Chrome",
      "version": "99.0.4844.84",
      "vendor": "Google LLC",
      "type": "application"
    }
  ]
}

Déploiement sur un réseau local

Pour rendre le serveur accessible sur un réseau local :

  1. Lancer le serveur avec 0.0.0.0 comme hôte :
    watchman-server --port 8000 --api-key "VOTRE_CLE_API"
    
  2. Assurez-vous que le port est ouvert dans le pare-feu :
    • Windows :
      netsh advfirewall firewall add rule name="Watchman" dir=in action=allow protocol=TCP localport=8000
      
    • Linux :
      sudo ufw allow 8000/tcp
      

Contributions

Les contributions sont les bienvenues ! Clonez le projet, créez une branche et proposez vos modifications via une pull request.

Licence

Ce projet est sous licence MIT.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

watchman_http_server-0.4.0.tar.gz (5.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

watchman_http_server-0.4.0-py3-none-any.whl (6.3 kB view details)

Uploaded Python 3

File details

Details for the file watchman_http_server-0.4.0.tar.gz.

File metadata

  • Download URL: watchman_http_server-0.4.0.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.4

File hashes

Hashes for watchman_http_server-0.4.0.tar.gz
Algorithm Hash digest
SHA256 5051dcd2b9a11ea4db92c992e6e9b5ccc106f9e32365449a33fdcc2112b7d3ae
MD5 ba4e2ad2ae02ceb2eab91a082afac6b2
BLAKE2b-256 76a6d253318b80c93dc3cb3294bff2994ec7a6335bccb7a0dd39a8f5bf93d46f

See more details on using hashes here.

File details

Details for the file watchman_http_server-0.4.0-py3-none-any.whl.

File metadata

File hashes

Hashes for watchman_http_server-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7414dffe4dae62bc7e19284aab13d397d95b5530d0eba7253208ee9cdfb0bcb7
MD5 3db291abb0250e56c9be25fbe34dc483
BLAKE2b-256 ae00f0911c03f1c6dd35dd0513c264cb54482bef318b04e8463aba9d7b879802

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page