GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - hyperboria/python-cjdns: A python cjdns admin library, with Python 2 and Python 3 support

BranchesTags
Open more actions menu

Latest commit

 

History

91 Commits
91 Commits

Folders and files

NameName
Last commit message
Last commit date
cjdns
cjdns
 
 
tests
tests
 
 
util
util
 
 
.gitignore
.gitignore
 
 
.travis.yml
.travis.yml
 
 
LICENSE
LICENSE
 
 
MANIFEST.in
MANIFEST.in
 
 
README.rst
README.rst
 
 
pep8.ini
pep8.ini
 
 
setup.py
setup.py
 
 
tox.ini
tox.ini
 
 

Repository files navigation

python-cjdns For Python 2 & 3

Bulid Status Code Health PyPI

The cjdns python library doesn't support python3 and is a PITA to install, due to it's use of a modified bencode library which is still called "bencode", among other things, so I'm cleaning it up.

Installation

The easiest way to install it is:

pip install cjdns

But you could also clone it and run:

python setup.py install

Once it's installed, you'll find peerStats and cexec installed in your $PATH, and the cjdns library available for import.

Usage

Usage is simple. First, import:

import cjdns

Then, connect to the running cjdns instance. There are two ways to do this. The normal way is to use the ~/.cjdnsadmin file:

cjdns = cjdns.connectWithAdminInfo()

Or, if you have the IP, port and password and wish to ignore the ~/.cjdnsadmin file for whatever reason:

cjdns = cjdns.connect(ip, port, password)

Once connected, you may call any of the cjdns admin interface functions:

peerStats = cjdns.InterfaceController_peerStats()

Finally, there is a helper function that allows one to convert a cjdns public key into an IP address:

from cjdns import key_utils
key_utils.to_ipv6('1rfp3guz4jjhfu4dsu5mrz68f7fyp502wcttq6b78xdrjhd4ru80.k')

License

Same as cjdns, this is a GPLv3 project. Full text of the license is available [here](LICENSE)

Contributing

I welcome pull requests, please make sure that everything you contribute is pep8 compliant and works on python 2.6, 2.7, 3.3, 3.4, 3.5. There are some basic tests in place for these things via Travis, but they're not complete by any means.

About

A python cjdns admin library, with Python 2 and Python 3 support

pypi.python.org/pypi/cjdnsadmin

Resources

Readme
GPL-3.0 license
Activity
Custom properties

Stars

25 stars

Watchers

6 watching

Forks

20 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.