[Kea-users] kea SubClass equivalent

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

[Kea-users] kea SubClass equivalent

sven.roehrig

Hi,

 

on our old isc-dhcp config we are using subclasses to allow CPE´s that are connected behind a CableModem to get a public IP only if the CableModem  has a valid host-reservation configured.

In isc-dhcp we have a client class like this:

class "privileged" {

match option agent.remote-id;

}

set as subclass in host-reservation for the CableModem.

 

Only CPE´s that match the class privileged are allowed to get a public IP.

 

Since subclasses are not implemented in KEA could someone guide me how to solve this in KEA 1.4?

 

I need something like:

 

"client-classes": [

                    {

                        "name": "PRIVILEGED",                       

                        "test": "relay4[2].member(KNOWN)"

                    }

 

Thank you in advance

Sven


_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

Francis Dupont
Very busy these days but as I worked on a ISC DHCP to Kea migration
assistant I remember I have a code handling subclasses.
BTW there is a built-in class named KNOWN (with its opposite UNKNOWN)
which is set when a client has a host reservation so perhaps tools
you need are already there. Shall look at this later...

Regards

Francis Dupont <[hidden email]>
_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

sven.roehrig
Hi,

thanks for responding. I would like to use the built-in class KNOWN but I
don´t have a host-reservation for the CPE, only for the CableModem the CPE
is connected to.
I would need a lookup like this using the MAC in relay4[2] to find a
host-reservation for the corresponding CableModem.

Since this is an essential feature for us it would be very very nice if you
could assist finding a working code for this.

Thanks
Sven


-----Ursprüngliche Nachricht-----
Von: Francis Dupont <[hidden email]>
Gesendet: Donnerstag, 25. Oktober 2018 23:04
An: [hidden email]
Cc: [hidden email]
Betreff: Re: [Kea-users] kea SubClass equivalent

Very busy these days but as I worked on a ISC DHCP to Kea migration
assistant I remember I have a code handling subclasses.
BTW there is a built-in class named KNOWN (with its opposite UNKNOWN) which
is set when a client has a host reservation so perhaps tools you need are
already there. Shall look at this later...

Regards

Francis Dupont <[hidden email]>

_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

Francis Dupont
[hidden email] writes:

> thanks for responding. I would like to use the built-in class KNOWN
> but I don't have a host-reservation for the CPE, only for the
> CableModem the CPE is connected to.
>
> I would need a lookup like this using the MAC in relay4[2] to find a
> host-reservation for the corresponding CableModem.
>
> Since this is an essential feature for us it would be very very nice if
> you could assist finding a working code for this.

=> I am afraid you need to write a hook as each time the expression feature
is not enough to classify a received message.

Regards

Francis Dupont <[hidden email]>
_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

sven.roehrig
Hi,

do you have something I can start with? Would be the first hook for me.

Regards

-----Ursprüngliche Nachricht-----
Von: Francis Dupont <[hidden email]>
Gesendet: Freitag, 26. Oktober 2018 09:23
An: [hidden email]
Cc: 'Francis Dupont' <[hidden email]>; [hidden email]
Betreff: Re: AW: [Kea-users] kea SubClass equivalent

[hidden email] writes:

> thanks for responding. I would like to use the built-in class KNOWN
> but I don't have a host-reservation for the CPE, only for the
> CableModem the CPE is connected to.
>
> I would need a lookup like this using the MAC in relay4[2] to find a
> host-reservation for the corresponding CableModem.
>
> Since this is an essential feature for us it would be very very nice
> if you could assist finding a working code for this.

=> I am afraid you need to write a hook as each time the expression feature
is not enough to classify a received message.

Regards

Francis Dupont <[hidden email]>

_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

sven.roehrig
How about this ?

https://github.com/Olen/kea_hooks

could this be used?

-----Ursprüngliche Nachricht-----
Von: Kea-users <[hidden email]> Im Auftrag von
[hidden email]
Gesendet: Freitag, 26. Oktober 2018 09:34
An: 'Francis Dupont' <[hidden email]>
Cc: [hidden email]
Betreff: Re: [Kea-users] kea SubClass equivalent

Hi,

do you have something I can start with? Would be the first hook for me.

Regards

-----Ursprüngliche Nachricht-----
Von: Francis Dupont <[hidden email]>
Gesendet: Freitag, 26. Oktober 2018 09:23
An: [hidden email]
Cc: 'Francis Dupont' <[hidden email]>; [hidden email]
Betreff: Re: AW: [Kea-users] kea SubClass equivalent

[hidden email] writes:

> thanks for responding. I would like to use the built-in class KNOWN
> but I don't have a host-reservation for the CPE, only for the
> CableModem the CPE is connected to.
>
> I would need a lookup like this using the MAC in relay4[2] to find a
> host-reservation for the corresponding CableModem.
>
> Since this is an essential feature for us it would be very very nice
> if you could assist finding a working code for this.

=> I am afraid you need to write a hook as each time the expression feature
is not enough to classify a received message.

Regards

Francis Dupont <[hidden email]>

_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users

_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users
Reply | Threaded
Open this post in threaded view
|

Re: [Kea-users] kea SubClass equivalent

Ola Thoresen
On 26/10/2018 10:18, [hidden email] wrote:

> How about this ?
>
> https://github.com/Olen/kea_hooks
>
> could this be used?


I am so glad this is mentioned, however, be aware that I have not
maintained it for quite a few versions of KEA, and that I am in no way a
C++-developer.

But I would be thrilled if someone more experienced than me would adopt
the concept, and improve it and bring it into KEA in a better shape.


Rgds.

Ola (T)



> -----Ursprüngliche Nachricht-----
> Von: Kea-users <[hidden email]> Im Auftrag von
> [hidden email]
> Gesendet: Freitag, 26. Oktober 2018 09:34
> An: 'Francis Dupont' <[hidden email]>
> Cc: [hidden email]
> Betreff: Re: [Kea-users] kea SubClass equivalent
>
> Hi,
>
> do you have something I can start with? Would be the first hook for me.
>
> Regards
>
> -----Ursprüngliche Nachricht-----
> Von: Francis Dupont <[hidden email]>
> Gesendet: Freitag, 26. Oktober 2018 09:23
> An: [hidden email]
> Cc: 'Francis Dupont' <[hidden email]>; [hidden email]
> Betreff: Re: AW: [Kea-users] kea SubClass equivalent
>
> [hidden email] writes:
>
>> thanks for responding. I would like to use the built-in class KNOWN
>> but I don't have a host-reservation for the CPE, only for the
>> CableModem the CPE is connected to.
>>
>> I would need a lookup like this using the MAC in relay4[2] to find a
>> host-reservation for the corresponding CableModem.
>>
>> Since this is an essential feature for us it would be very very nice
>> if you could assist finding a working code for this.
> => I am afraid you need to write a hook as each time the expression feature
> is not enough to classify a received message.
>
> Regards
>
> Francis Dupont <[hidden email]>
>
> _______________________________________________
> Kea-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/kea-users
>
> _______________________________________________
> Kea-users mailing list
> [hidden email]
> https://lists.isc.org/mailman/listinfo/kea-users
_______________________________________________
Kea-users mailing list
[hidden email]
https://lists.isc.org/mailman/listinfo/kea-users