Library to parse and generate OpenFlow messages
Project description
python-openflow is a low level library to parse OpenFlow messages. If you want to read an OpenFlow packet from an open socket or send a message to an OpenFlow switch, this is your best friend. The main features are: high performance, latest specification compliance, short learning curve and free software license.
This library is part of Kytos project, a collaborative project between SPRACE (from São Paulo State University, Unesp) and Caltech (California Institute of Technology). python-openflow was developed to be used with Kytos controller, but feel free to use this simple and intuitive library in another project with another controller.
Overview
This is just an overview for you to check whether this project fits your needs. For a more detailed documentation, please check the python-openflow API Reference Manual.
Usage
For example, see how it is easy to create a feature request message with this library. You can use ipython3 to get the advantages of autocompletion:
>>> from pyof.v0x01.controller2switch.features_request import FeaturesRequest >>> request = FeaturesRequest(xid = 100) >>> print(request.header.message_type) Type.OFPT_FEATURES_REQUEST >>> print(request.header.xid) 100
If you need to send this message via socket, call the pack() method to get its binary representation:
>>> binary_msg = request.pack()
Installing
The easiest way to install is using pip3 (pip for Python 3):
sudo pip3 install python-openflow
Support
We are available in IRC and there is also a development mailing list. Details are available in the full documentation.
Contributing
Contributions are welcome either by creating issues in GitHub or in the form of pull requests. Before, please, read the contribution and hacking guides in the main documentation.
License
This software is under MIT-License. For more information please read the LICENSE file.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Hashes for python-openflow-1.1.0a2.post2.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6f3792929e2a326bec51761362cdf6f4de732db3a7d30a4c6ca848a5c6a374d6 |
|
MD5 | 2782ab6197fc248759f5ba63bffd2e26 |
|
BLAKE2b-256 | 5223e331ea61588d75e954733bae0b82a922e3f87194cac0803076ef788bf7cb |