Skip to main content

Sliver gRPC client library.

Project description

SliverPy

SliverPy is a Python gRPC client library for Sliver. SliverPy can be used to automate any operator interaction with Sliver and connects to servers using gRPC over Mutual TLS (i.e., multiplayer) using Sliver operator configuration files. For more details, please see the project documentation.

Not yet implemented:

  • website APIs
  • Realtime events / etc.

SliverPy Documentation Status License: GPL v3

Install

Install the package using pip, for best compatibility use Sliver Server v1.4.11 or later:

pip3 install sliver-py

Examples

For more examples please read the project documentation.

List Sessions / Async List Sessions

#!/usr/bin/env python3

import os
import asyncio
from sliver import SliverClientConfig, SliverClient, AsyncSliverClient

CONFIG_DIR = os.path.join(os.path.expanduser("~"), ".sliver-client", "configs")
DEFAULT_CONFIG = os.path.join(CONFIG_DIR, "default.cfg")


def main():
    ''' Client example '''
    config = SliverClientConfig.parse_config_file(DEFAULT_CONFIG)
    client = SliverClient(config)
    client.connect()
    print('Sessions: %r' % client.sessions())


async def run():
    ''' Async client example '''
    config = SliverClientConfig.parse_config_file(DEFAULT_CONFIG)
    client = AsyncSliverClient(config)
    await client.connect()
    sessions = await client.sessions()
    print('[async] Sessions: %r' % sessions)

if __name__ == '__main__':
    main()
    asyncio.run(run())

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

sliver-py-0.0.7.tar.gz (66.8 kB view details)

Uploaded Source

Built Distribution

sliver_py-0.0.7-py3-none-any.whl (68.2 kB view details)

Uploaded Python 3

File details

Details for the file sliver-py-0.0.7.tar.gz.

File metadata

  • Download URL: sliver-py-0.0.7.tar.gz
  • Upload date:
  • Size: 66.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.10.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for sliver-py-0.0.7.tar.gz
Algorithm Hash digest
SHA256 81be1fda74f6bc45929f039cf8a7f914a5fba388e8189f9449c406def2d4cfdd
MD5 d586be35b9c8071ee6742e0a7c1652ec
BLAKE2b-256 caad1762e2517b104b36a67b52652221a034c2efd7191a267e76f3e37506eadb

See more details on using hashes here.

File details

Details for the file sliver_py-0.0.7-py3-none-any.whl.

File metadata

  • Download URL: sliver_py-0.0.7-py3-none-any.whl
  • Upload date:
  • Size: 68.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.1 importlib_metadata/3.10.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4

File hashes

Hashes for sliver_py-0.0.7-py3-none-any.whl
Algorithm Hash digest
SHA256 3be837418a2a92525acf80fe0d3c24503335445c862bc779f318b4f68475b118
MD5 9d29bac98b275ce2688aa7f338256b38
BLAKE2b-256 fcbbf893a95494295cdebd37ffdc66650cffa6f40fc41a3976a58324458135c4

See more details on using hashes here.

Supported by

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