Skip to main content

RADIUS Server

Project description

Tests python pre-commit Code style: ruff Checked with mypy

pyrad2 is an implementation of a RADIUS client/server as described in RFC2865 and of RADSEC client/server as described in RFC6614. It takes care of all the details like building RADIUS packets,sending them and decoding responses.

Documentation can be found here.

Introduction

pyrad2 is an implementation of a RADIUS client/server as described in RFC2865. It takes care of all the details like building RADIUS packets, sending them and decoding responses.

What this fork does:

  • Adds RadSec (RFC 6614) support (Experimental)
  • Supports only Python 3.12+
  • Extensive typing
  • Increased test coverage
  • New bug fixes

Note that this is not a stand-alone Radius implementation like FreeRadius. You are supposed to inherit the server classes and code your own behind-the-scenes implementation. This package allows you to code your business logic on top of it.

Requirements & Installation

pyrad2 requires Python 3.12 and uses uv. On a Mac, you can simply run brew install uv.

Examples

See the Getting Started guide for a better overview.

There are a few examples in the examples folder. You can either install pyrad2 and use the examples or clone the repo. If you clone the repo, make commands are useful.

The easiest way to start a server is by running make server. This will run the example server in examples/server_async.py.

If you want to see a request in action, leave the server running, open another terminal and type make auth. Several other commands are available such as make server_radsec, make server_coa, make_acct, etc.

Tests

Run make test.

Author, Copyright, Availability

pyrad2 is currently maintaned by Nicholas Amorim <<nicholas@santos.ee>.

pyrad was written by Wichert Akkerman <wichert@wiggy.net> and is maintained by Christian Giese (GIC-de) and Istvan Ruzman (Istvan91).

This project is licensed under a BSD license.

Copyright and license information can be found in the LICENSE.txt file.

The current version and documentation can be found on pypi: https://pypi.org/project/pyrad2/

Bugs and wishes can be submitted in the pyrad issue tracker on github: https://github.com/nicholasamorim/pyrad2/issues

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

pyrad2-1.2.0.tar.gz (47.1 kB view details)

Uploaded Source

Built Distribution

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

pyrad2-1.2.0-py3-none-any.whl (40.2 kB view details)

Uploaded Python 3

File details

Details for the file pyrad2-1.2.0.tar.gz.

File metadata

  • Download URL: pyrad2-1.2.0.tar.gz
  • Upload date:
  • Size: 47.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for pyrad2-1.2.0.tar.gz
Algorithm Hash digest
SHA256 b75721cf2e12486609693a9d1f21c24d3423033a2aedbf14b099303e22ac3570
MD5 9ea7ac132c5d0bc41e317a0e6ee5ce30
BLAKE2b-256 5f10081480deed08c534be2bb210c9b6f77577fc8abcb9f69bfc57a9feae5f92

See more details on using hashes here.

File details

Details for the file pyrad2-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: pyrad2-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 40.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for pyrad2-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ef16a29027bf57e02c6dfab0fce2a8da16cc1ec19a3d8011595e0a67508777d2
MD5 d6f3fdf565b48edce7d624e8262e6106
BLAKE2b-256 faa572646529766a61b3bde1d4bf57e56b03b014a94a916caabad11b15614fa4

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