# myst_connector

Small connector to select and connect to Mysterium providers securely.

Usage
- Configure your identity in `myst_connector/config.ini` under the `[app]` section. Example:

  ```ini
  [app]
  identity = 0xYOURIDENTITY
  ```

  Then run:

  ```bash
  python -m myst_connector
  # or
  python connect.py
  ```

Configuration
- The program reads `myst_connector/config.ini`. Recommended permissions:

  ```bash
  chmod 600 myst_connector/config.ini
  ```

 - The connector reads `identity` from `myst_connector/config.ini` by default. If you prefer not to store secrets in files, use a secure secret manager outside the repository.

Executables
- `myst_connector/config.ini` contains an `[executables]` section for external binaries (`myst`, `qrexec-client-vm`, `ip`). Prefer absolute paths to avoid ambiguity. The connector validates these at startup.

Security guidance
- The connector enforces strict identity handling; `MYST_IDENTITY` is required at runtime.
- Files written by the connector (locks, caches) should be stored in a directory with restrictive permissions. The default paths are in `myst_connector/config.ini` under `[paths]`.
- The code uses atomic writes and file locking to reduce TOCTOU and symlink risks.
