public inbox for libc-help@sourceware.org
 help / color / mirror / Atom feed
* generate icmp checksum
@ 2021-03-02 20:45 Peng Yu
  2021-03-02 21:31 ` Christian Grothoff
  2021-03-02 21:31 ` Florian Weimer
  0 siblings, 2 replies; 3+ messages in thread
From: Peng Yu @ 2021-03-02 20:45 UTC (permalink / raw)
  To: libc-help

Hi,

https://github.com/bminor/glibc/blob/21c3f4b5368686ade28d90d8c7d79c4c95c72c1b/sysdeps/gnu/netinet/ip_icmp.h

I see there is a checksum field in the above file. Is there a function
that can generate the checksum? Thanks.

-- 
Regards,
Peng

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: generate icmp checksum
  2021-03-02 20:45 generate icmp checksum Peng Yu
@ 2021-03-02 21:31 ` Christian Grothoff
  2021-03-02 21:31 ` Florian Weimer
  1 sibling, 0 replies; 3+ messages in thread
From: Christian Grothoff @ 2021-03-02 21:31 UTC (permalink / raw)
  To: Peng Yu; +Cc: libc-help

You can find one here:

https://git.gnunet.org/gnunet.git/tree/src/util/tun.c

On 3/2/21 9:45 PM, Peng Yu via Libc-help wrote:
> Hi,
> 
> https://github.com/bminor/glibc/blob/21c3f4b5368686ade28d90d8c7d79c4c95c72c1b/sysdeps/gnu/netinet/ip_icmp.h
> 
> I see there is a checksum field in the above file. Is there a function
> that can generate the checksum? Thanks.
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: generate icmp checksum
  2021-03-02 20:45 generate icmp checksum Peng Yu
  2021-03-02 21:31 ` Christian Grothoff
@ 2021-03-02 21:31 ` Florian Weimer
  1 sibling, 0 replies; 3+ messages in thread
From: Florian Weimer @ 2021-03-02 21:31 UTC (permalink / raw)
  To: Peng Yu via Libc-help

* Peng Yu via Libc-help:

> Hi,
>
> https://github.com/bminor/glibc/blob/21c3f4b5368686ade28d90d8c7d79c4c95c72c1b/sysdeps/gnu/netinet/ip_icmp.h
>
> I see there is a checksum field in the above file. Is there a function
> that can generate the checksum? Thanks.

I do not think we have an implementation of the Internet checksum in
glibc, but it's a large library, so it's difficult to be sure.

Florian


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-03-02 21:31 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-02 20:45 generate icmp checksum Peng Yu
2021-03-02 21:31 ` Christian Grothoff
2021-03-02 21:31 ` Florian Weimer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).