Download the PHP package ictsolutions/codeigniter-freeradius without Composer

On this page you can find all versions of the php package ictsolutions/codeigniter-freeradius. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package codeigniter-freeradius

Codeigniter FreeRADIUS

The CodeIgniter FreeRADIUS library provides a suite of tools designed to manage and interact with a FreeRADIUS server through the CodeIgniter framework. It offers functionality for database handling, configuring FreeRADIUS tables, manipulating username realms and characteristics, modifying PPPoE group settings, and managing IP ranges for Carrier-Grade NAT (CGNAT). This library significantly simplifies the process of working with a FreeRADIUS server by offering pre-defined and easily configurable settings.

Moreover, its seamless integration with the CodeIgniter framework makes it an exemplary toolset for developers requiring remote authentication and accounting in their PHP applications. This allows developers to focus more on their application's core features, assured in the knowledge that their FreeRADIUS server interaction is handled proficiently by this library.

PHP CodeIgniter

Installation

Installation is done through Composer.

Configuration

Tables: The FreeRADIUS tables are named as radacct, radcheck, radgroupcheck, radgroupreply, radreply, radusergroup, radpostauth, nas, nasreload, and userinfo. These are typically created when installing and configuring a FreeRADIUS server and are used to manage RADIUS accounts, user groups, authentication, and servers.

usernameRealm: The realm that's used to construct usernames is set to null by default, meaning that there's no realm added to the username.

usernameCharacters & usernameLength: Usernames are generated using the characters '0-9' and 'A-Z' and they have a length of 6 characters.

passwordCharacters & passwordLength: Passwords are generated using the characters '0-9' and 'A-Z' and they have a length of 12 characters.

pppoeGroupName & pppoeGroupPriority: The default Point-to-Point Protocol over Ethernet (PPPoE) group name is 'PPPoE' and it has a priority of 0.

ipStart & ipEnd: The IP address range for Carrier-Grade NAT (CGNAT) starts from '100.64.0.0' to '100.64.63.255'.

Enumerations

Attribute Enumeration

The Attribute enumeration consists of the following Enums, representing different RADIUS protocol attributes that can be used within this CodeIgniter FreeRADIUS Library:

Each Enum accompanies a comment, describing its purpose or function in the RADIUS protocol.

Operator Enumeration

The Operator enumeration consists of different operators that can be applied to the CodeIgniter FreeRADIUS Library attributes:

Each Enum is annotated with a comment, providing additional insights into the use of operators with attributes in RADIUS protocol.

Usage

Initialization

Instantiate your FreeRADIUS library using the provided services class. The CodeIgniter's service class provides a unified and direct way to access the library.

Bind A User

For example, if you want to bind a user with an attribute 'FramedIPAddress' in the RADIUS server:

This will bind the user to the provided IP address using the RADIUS protocol attribute for framed IP.

Check User's Binding

You can also check the user's binding status:

This method will check if the user has the 'Framed-IPAddress' correctly bound with the provided value.

Other Features

There are other features that allow you to work with FreeRADIUS server's advanced configurations. Set fall-through behavior, allow simultaneous logins, set service type, and other configurations via a simple syntax:

This will configure the FreeRADIUS server to not allow fall-through, limit simultaneous logins to one, and set the service type to 'Framed-User'.

Please note that for actual deployment, all attribute value, operator, user details etc. should be carefully managed and sanitized.

Example: Creating a CodeIgniter Project with FreeRADIUS

Step 1: Create New CodeIgniter Project

Start by creating a new CodeIgniter project if you haven't already. You can initiate a project using Composer:

Navigate to the newly created project:

Step 2: Install CodeIgniter FreeRADIUS library

Add the FreeRADIUS library to your project:

Step 3: Run the Migration

Now you can run your migration. This will create the necessary tables in your database for the FreeRADIUS to work:

Check your database to verify that the tables were created.

Step 5: Using the Library in Your Code

After the setup, you can utilize the FreeRadius library in the CodeIgniter project. For example, in your controller:

Please, ensure you replace 'JohnsPassword123' with a safe and hashed version of the password in a real-life scenario.

License

This project is licensed under the MIT License - see the LICENSE file for details.


All versions of codeigniter-freeradius with dependencies

PHP Build Version
Package Version
Requires php Version ^8.1
codeigniter4/settings Version ^2.2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package ictsolutions/codeigniter-freeradius contains the following files

Loading the files please wait ....