PHPackages                             anafay/radius-server - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. anafay/radius-server

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

anafay/radius-server
====================

Implementation of RADIUS server: both authorization and accounting (RFC 2865, 2866, 2867)

1.0.2(4y ago)016Apache-2.0PHP

Since Apr 30Pushed 2y ago1 watchersCompare

[ Source](https://github.com/Anafay/radius-server)[ Packagist](https://packagist.org/packages/anafay/radius-server)[ RSS](/packages/anafay-radius-server/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (2)Versions (4)Used By (0)

Implementation of RADIUS server: both authorization and accounting (RFC 2865, 2866, 2867).

Usage
=====

[](#usage)

RADIUS server class:
--------------------

[](#radius-server-class)

```
class RadiusServer implements RadiusServerInterface {
    public function onAccessRequest(IncomingMessage $message) {
        if(check($message)){
            $message->replyAccept()
                ->addAttribute(Message::ATTR_FRAMED_IP_ADDRESS, '192.168.0.1')
                ->addAttribute(Message::ATTR_SESSION_TIMEOUT,180)
                ->send();
        }else{
            $message->replyReject()
                ->addAttribute(Message::ATTR_REPLY_MESSAGE,'Restricted')
                ->send();
        }
    }

    public function onAccountingStart(IncomingMessage $message, Session $session) {
        $this->log($session,'start');
    }

    public function onAccountingStop(IncomingMessage $message, Session $session) {
        $this->log($session,'stop');
        $this->save($session);
    }

    public function onInterimUpdate(IncomingMessage $message, Session $session) {
        $this->log($session,'interim');
    }
    ....
}
```

ReactPHP application:
---------------------

[](#reactphp-application)

```
$loop = React\EventLoop\Factory::create();
$radius = new Factory(new RadiusServer(),'secret');
$radius->listen($loop,'10.1.0.1');
$loop->run();
```

Requirements
============

[](#requirements)

The library requires PHP&gt;=7.0 and ReactPHP (event-loop&gt;=1.1, datagram&gt;=1.5).

###  Health Score

23

—

LowBetter than 26% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity51

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

3

Last Release

1521d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/515eb7e01ce3ebfc3e75f42b2594bd06740488d89d428672b8c42c1a7ab250b0?d=identicon)[Anafay](/maintainers/Anafay)

---

Top Contributors

[![Anafay](https://avatars.githubusercontent.com/u/53856325?v=4)](https://github.com/Anafay "Anafay (11 commits)")

### Embed Badge

![Health badge](/badges/anafay-radius-server/health.svg)

```
[![Health](https://phpackages.com/badges/anafay-radius-server/health.svg)](https://phpackages.com/packages/anafay-radius-server)
```

###  Alternatives

[friendsofphp/php-cs-fixer

A tool to automatically fix PHP code style

13.5k251.2M25.2k](/packages/friendsofphp-php-cs-fixer)[team-reflex/discord-php

An unofficial API to interact with the voice and text service Discord.

1.1k420.9k26](/packages/team-reflex-discord-php)[nightowl/agent

NightOwl monitoring agent — collects telemetry from laravel/nightwatch and writes to PostgreSQL

771.7k](/packages/nightowl-agent)[nativephp/mobile

NativePHP for Mobile

1.1k75.1k91](/packages/nativephp-mobile)[rector/rector-src

Instant Upgrade and Automated Refactoring of any PHP code

136406.3k14](/packages/rector-rector-src)[clue/connection-manager-extra

Extra decorators for creating async TCP/IP connections, built on top of ReactPHP's Socket component

2215.6k7](/packages/clue-connection-manager-extra)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
