mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* constructing IPv6 in6_addr structure from ipv6
@ 2004-12-06 22:04 Steve French
  0 siblings, 0 replies; only message in thread
From: Steve French @ 2004-12-06 22:04 UTC (permalink / raw)
  To: linux-kernel; +Cc: xma

Is there a recommended way to construct a struct sockaddr_in6 in kernel
which is the format the connect function on a socket requires for ipv6
addresses?

Basically this boils down to how to best construct a struct in6_addr
starting with a IPv6 network address represented as a familiar dotted
address character string.   I would prefer to convert this in kernel via
something like inet_pton(AF_INET6,original_address_string,
converted_to_in6_add_form) but I could convert in userspace and pass the
16 byte array down to the kernel mangled as a string, via a mount
option.

Is it better to mangle the address and pass it down, or do something
similar to inet_pton?   This can't be the first time that someone has
wanted to deal with an ipv6 address coming from userspace ...






^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-12-06 22:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-12-06 22:04 constructing IPv6 in6_addr structure from ipv6 Steve French

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®