OSDN Git Service

2013.10.24
[uclinux-h8/uClinux-dist.git] / freeswan / doc / manpage.d / ipsec_hostof.3.html
1 Content-type: text/html
2
3 <HTML><HEAD><TITLE>Manpage of IPSEC_SUBNETOF</TITLE>
4 </HEAD><BODY>
5 <H1>IPSEC_SUBNETOF</H1>
6 Section: C Library Functions (3)<BR>Updated: 11 June 2001<BR><A HREF="#index">Index</A>
7 <A HREF="http://localhost/cgi-bin/man/man2html">Return to Main Contents</A><HR>
8
9
10 <A NAME="lbAB">&nbsp;</A>
11 <H2>NAME</H2>
12
13 ipsec subnetof - given Internet address and subnet mask, return subnet number
14 <BR>
15
16 ipsec hostof - given Internet address and subnet mask, return host part
17 <BR>
18
19 ipsec broadcastof - given Internet address and subnet mask, return broadcast address
20 <A NAME="lbAC">&nbsp;</A>
21 <H2>SYNOPSIS</H2>
22
23 <B>#include &lt;<A HREF="file:/usr/include/freeswan.h">freeswan.h</A>&gt;</B>
24
25 <P>
26 <B>struct in_addr subnetof(struct in_addr addr,</B>
27
28 <BR>
29 &nbsp;
30 <B>struct in_addr mask);</B>
31
32 <BR>
33
34 <B>struct in_addr hostof(struct in_addr addr,</B>
35
36 <BR>
37 &nbsp;
38 <B>struct in_addr mask);</B>
39
40 <BR>
41
42 <B>struct in_addr broadcastof(struct in_addr addr,</B>
43
44 <BR>
45 &nbsp;
46 <B>struct in_addr mask);</B>
47
48 <A NAME="lbAD">&nbsp;</A>
49 <H2>DESCRIPTION</H2>
50
51 These functions are obsolete; see
52 <I><A HREF="ipsec_networkof.3.html">ipsec_networkof</A></I>(3)
53
54 for their replacements.
55 <P>
56
57 <I>Subnetof</I>
58
59 takes an Internet
60 <I>address</I>
61
62 and a subnet
63 <I>mask</I>
64
65 and returns the network part of the address
66 (all in network byte order).
67 <I>Hostof</I>
68
69 similarly returns the host part, and
70 <I>broadcastof</I>
71
72 returns the broadcast address (all-1s convention) for the network.
73 <P>
74
75 These functions are provided to hide the Internet bit-munging inside
76 an API, in hopes of easing the eventual transition to IPv6.
77 <A NAME="lbAE">&nbsp;</A>
78 <H2>SEE ALSO</H2>
79
80 <A HREF="inet.3.html">inet</A>(3), <A HREF="ipsec_atosubnet.3.html">ipsec_atosubnet</A>(3)
81 <A NAME="lbAF">&nbsp;</A>
82 <H2>HISTORY</H2>
83
84 Written for the FreeS/WAN project by Henry Spencer.
85 <A NAME="lbAG">&nbsp;</A>
86 <H2>BUGS</H2>
87
88 Calling functions for this is more costly than doing it yourself.
89 <P>
90
91 <HR>
92 <A NAME="index">&nbsp;</A><H2>Index</H2>
93 <DL>
94 <DT><A HREF="#lbAB">NAME</A><DD>
95 <DT><A HREF="#lbAC">SYNOPSIS</A><DD>
96 <DT><A HREF="#lbAD">DESCRIPTION</A><DD>
97 <DT><A HREF="#lbAE">SEE ALSO</A><DD>
98 <DT><A HREF="#lbAF">HISTORY</A><DD>
99 <DT><A HREF="#lbAG">BUGS</A><DD>
100 </DL>
101 <HR>
102 This document was created by
103 <A HREF="http://localhost/cgi-bin/man/man2html">man2html</A>,
104 using the manual pages.<BR>
105 Time: 05:09:31 GMT, June 19, 2001
106 </BODY>
107 </HTML>