Giter Site home page Giter Site logo

delegated-ipv6-prefix's Introduction

Mikrotik is not taking the Delegated-IPv6-Prefix attribute when you use PPPoE and Radius. In some countries is mandatory to save this info.

I was able to do a dirty fix using a script in the Mikrotik, a php web page on the freeradius, and some changes in queries.conf of freeradius 3.

The idea is to save the PD in the attribute of the radreply table named Delegated-IPv6-Prefix , (I know should be used in the other way). And later, when the Mikrotik do the accounting, uodate the Delegated-IPv6-Prefix in the radacct table.

You must have mysql, a web server (tested in apache2), and php whith PDO support.

The Mikrotik Script should be placed in the PPPoE Profile, script section.

The php update-ipv6.php file in the same location you put in the fetch section in the Mikrotik Script.

And you must add this code to /etc/freeradius/3.0/mods-config/sql/main/mysql/queries.conf

in the interim-update section, query, before the WHERE line.

delegatedipv6prefix = (select value from radreply where attribute='Delegated-IPv6-Prefix' and username='%{SQL-User-Name}') \

You need to have added the Delegated-IPv6-Prefix attribute to radreply, and save a valid IPv6 Address, if not, the freeradius will not start.

I hope this can be usefull for someone.

Demian

delegated-ipv6-prefix's People

Contributors

dpecile avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.