directory-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sherman Lilly <sherman.li...@gmail.com>
Subject Re: DHCPOption problem
Date Tue, 15 Dec 2015 18:18:35 GMT
Can I do it with Apache Directory Studio
On Dec 15, 2015 11:29 AM, "Emmanuel Lécharny" <elecharny@gmail.com> wrote:

> Le 15/12/15 16:40, Sherman Lilly a écrit :
> > I am trying to Apache Directory server for a DHCP backend. I have got a
> lot
> > of it working but I have hit wall and need help. I am trying to add an
> > attribute the "dhcpOption". When I try to add it, it ask for a binary
> value
> > but I don't how to add it. Let us say that I am trying to add
> "dhcpOption"
> > with a value of "broadcast 10.50.255.255". That is a string and will not
> > work. After lots of research apparently the value needed for that
> attribute
> > has to an encoded value of the string. How do I make this encoded value?
>
> It depends on the tool you are using.
>
> Basically, if you are using Java, you need to get the UTF-8 form for the
> String you want to inject into the server. That's done with :
>
> "Your data".getBytes( StandardCharsets.UTF_8 );
>
> You can also use the Apache LDAP API
> org.apache.directory.api.util.Strings method :
>    public static byte[] getBytesUtf8( String string )
>
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message