h*׽:      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~3.2.7.0 Safe-Inferred Safe-Inferred fnetwork6Returns the index corresponding to the interface name.Since 2.7.0.0.network6Returns the interface name corresponding to the index.Since 2.7.0.0.  Safe-Inferred jnetwork%Message flags. To combine flags, use .network8Wait until the requested number of bytes have been read.networkReceived control message is truncated. More control message exist.network,Received data is truncated. More data exist.networkEnd of record.network constants are widely used as synonyms for the corresponding PF_xxxxx protocol family values, to which they are numerically equal in mainstream socket API implementations.,Strictly correct usage would be to pass the PF_xxxxx2 constants as the first argument when creating a " , while the AF_xxxxx constants should be used as  addrFamily values with  getAddrInfo. For now only the AF_xxxxx constants are provided.Some of the defined patterns may be unsupported on some systems: see y. network Socket Types.Some of the defined patterns may be unsupported on some systems: see x.!networkProtocol number."networkBasic type for a socket.network8Converts the from network byte order to host byte order.network8Converts the from host byte order to network byte order.#networkController Area Network$networkbluetooth sockets%networkWanpipe API sockets&network PPPoX sockets'network IRDA sockets(networkATM SVCs)network Acorn Econet*networkAsh+network Packet family,networkSecurity callback pseudo AF-networkNetbeui 802.2LLC.networkAmateur Radio X.25 PLP/networkATM PVCs0networkmultiprotocol bridge1networkAmateur radio NetROM2network raw interface3networkLink layer interface4networkLink layer interface5networkENCAP6network/Used by BPF to not rewrite hdrs in iface output7network ARP (RFC 826)8networknative ATM access9network Internal key-management function:network#Integrated Services Digital Network;networkSimple Internet Protocol<networkHelp Identify PIP packets=networkHelp Identify RTIP packets>networkComputer Network Technology?network!connection-oriented IP, aka ST II@networkDebugging use onlyAnetworkNDDBnetworkNetwareCnetworkSGI Data Link for DLPIDnetworkWide Area Network protocolsEnetworkCommon Trace FacilityFnetwork!eXpress Transfer Protocol (no AF)GnetworkNovell Internet ProtocolHnetworkUS Government OSIInetworkAFIJnetworkAX25Knetwork CCITT X.25LnetworkDNA Network ManagementMnetwork$umbrella of all families used by OSINnetwork ISO protocolsOnetworkIEEE 802.2, also ISO 8802PnetworkNetwork Interface TapQnetworkNetBios-style addressesRnetwork*Internal Routing Protocol (aka AF_NETLINK)Snetwork Apple TalkTnetworkNSC HyperchannelUnetworkLATVnetworkDirect data link interfaceWnetworkDECnetXnetworkIBM SNAYnetworkCCITT protocols, X.25 etcZnetworkdatakit protocols[networkeuropean computer manufacturers\network nbs protocols]networkXEROX NS protocols^networkmit CHAOS protocols_networkpup protocols: e.g. BSP`networkArpanet imp addressesanetworkInternet Protocol version 6bnetworkInternet Protocol version 4cnetwork UNIX-domaindnetwork unspecifiedenetworkUnsupported address family, equal to any other families that are not supported on the system.fnetwork>Pattern for a general protocol family (a.k.a. address family).lnetwork'Used in getAddrInfo hints, for example.mnetworkUnsupported socket type, equal to any other types not supported on this system.nnetwork"Pattern for a general socket type.onetworkCurrently, this is an alias of p.pnetwork(Getting a file descriptor from a socket.If a "1 is shared with multiple threads and one uses p, unexpected issues may happen. Consider the following scenario:1) Thread A acquires a  from " by p.2) Thread B close the ".3) Thread C opens a new "!. Unfortunately it gets the same ( number which thread A is holding.0In this case, it is safer for Thread A to clone  by ?. But this would still suffer from a race condition between p and u.9If you use this function, you need to guarantee that the " does not get garbage-collected until after you finish using the file descriptor. q can be used for this purpose.A safer option is to use r instead.qnetworkEnsure that the given " stays alive (i.e. not garbage-collected) at the given place in the sequence of IO actions. This function can be used in conjunction with p to guarantee that the file descriptor is not prematurely freed. fd <- unsafeFdSocket sock -- using fd with blocking operations such as accept(2) touchSocket sockrnetworkGet a file descriptor from a "8. The socket will never be closed automatically before  withFdSocket? completes, but it may still be closed by an explicit call to u or v$, either before or during the call.+The file descriptor must not be used after  withFdSocket returns, because the " may have been garbage-collected, invalidating the file descriptor.Since: 3.1.0.0snetworkSocket is closed and a duplicated file descriptor is returned. The duplicated descriptor is no longer subject to the possibility of unexpectedly being closed if the socket is finalized. It is now the caller's responsibility to ultimately close the duplicated file descriptor.tnetwork)Creating a socket from a file descriptor.unetworkClose the socket. This function does not throw exceptions even if the underlying system call returns errors.5If multiple threads use the same socket and one uses p and the other use u, unexpected behavior may happen. For more information, please refer to the documentation of p.vnetworkClose the socket. This function throws exceptions if the underlying system call returns errors.wnetwork1This is the default protocol for a given service.defaultProtocol0xnetworkIs the  SOCK_xxxxx constant corresponding to the given SocketType known on this system? n4 values, not equal to any of the named patterns or m, will return % even when not known on this system.ynetworkDoes one of the AF_ constants correspond to a known address family on this system. f' values, not equal to any of the named AF_xxxxx patterns or e, will return % even when not known on this system.znetworkConvert  to .{networkDefault port number. defaultPort0|network4Is the socket address type supported on this system?network;Computes the storage requirements (in bytes) of the given . This function differs from $ in that the value of the argument is used.networkUse a + with a function requiring a pointer to a  and the length of that .networkWrite the given  to the given memory location.networkRead a  from the given memory location.}network Converts  to representation-independent IPv4 quadruple. For example for  127.0.0.1 the function will return (0x7f, 0, 0, 1) regardless of host endianness.~networkConverts IPv4 quadruple to .network Converts , to representation-independent IPv6 octuple.networkConverts IPv6 octuple to .networkZero a structure."rpqsotuv nmlkjihgxfedcba`_^]\[ZYXWVUTSRQPONMLKJIHGFEDCBA@?>=<;:9876543210/.-,+*)('&%$#yz|}~!w{ Safe-Inferred;dnetwork9STM action to wait until the socket is ready for reading.networkSTM action to wait until the socket is ready for reading and STM action to cancel the waiting.network9STM action to wait until the socket is ready for writing.networkSTM action to wait until the socket is ready for writing and STM action to cancel the waiting. Safe-Inferred %&?network,Network interface ID and local IPv4 address.network,Network interface ID and local IPv4 address.networkTraffic class of IPv6.network TOS of IPv4.networkHop limit of IPv6.networkTime to live of IPv4.networkControl message type class. Each control message type has a numeric $ and encode and decode functions.network/Identifier of control message (ancillary data).networkControl message (ancillary data) including a pair of level and type.networkThe identifier for Fds.networkThe identifier for .networkThe identifier for .networkThe identifier for .networkThe identifier for .networkThe identifier for .networkThe identifier for .networkUnsupported identifiernetworkLocate a control message of the given type in a list of control messages. The following shows an example usage: (lookupCmsg CmsgIdIPv4TOS cmsgs >>= decodeCmsg) :: Maybe IPv4TOSnetworkFiltering control message.%"(c) The University of Glasgow 20012BSD-style (see the file libraries/network/LICENSE)libraries@haskell.org provisionalportable Safe-InferredM network Throw an  corresponding to the current socket error if the IO action returns a result of -1, but retries in case of an interrupted operation. Discards the result of the IO action after error handling.network Throw an  corresponding to the current socket error if the IO action returns a result of -1, but retries in case of an interrupted operation. Checks for operations that would block and executes an alternative action before retrying in that case.network Throw an  corresponding to the current socket error if the IO action returns a result of -1, but retries in case of an interrupted operation. Checks for operations that would block and executes an alternative action before retrying in that case. If the error is one handled by the exempt filter then ignore it and return the error code.network Throw an  corresponding to the current socket error if the IO action returns a result of -13, but retries in case of an interrupted operation.network Throw an  corresponding to the current socket error if the IO action returns a result of -1>. Discards the result of the IO action after error handling.network Throw an + corresponding to the current socket error.networkLike 0, but the error code is supplied as an argument.?On Windows, do not use errno. Use a system error code instead.networkLike  , but if the action fails with  EWOULDBLOCK or similar, wait for the socket to be read-ready, and try again.networkLike  , but if the action fails with  EWOULDBLOCK or similar, wait for the socket to be read-ready, and try again. If it fails with the error the user was expecting then ignore the errornetworkLike  , but if the action fails with  EWOULDBLOCK or similar, wait for the socket to be write-ready, and try again.networkWith older versions of the network library (version 2.6.0.2 or earlier) on Windows operating systems, the networking subsystem must be initialised using 2 before any networking operations can be used. eg. main = withSocketsDo $ do {...}It is fine to nest calls to -, and to perform networking operations after  has returned. is not necessary for the current network library. However, for compatibility with older versions on Windows, it is good practice to always call  (it's very cheap).network#textual description of the locationnetworkthe  operation to be executednetwork#textual description of the locationnetworkaction to execute before retrying if an immediate retry would blocknetworkthe  operation to be executednetworkexception exempt filternetwork#textual description of the locationnetworkaction to execute before retrying if an immediate retry would blocknetworkthe  operation to be executednetwork#textual description of the locationnetworkthe  operation to be executednetwork#textual description of the locationnetworkthe  operation to be executednetwork)textual description of the error location   Safe-InferredN@ NoneNt Safe-Inferred %&()*X.networkTimeout in microseconds. This will be converted into struct timeval on Unix and DWORD (as milliseconds) on Windows.networkA type that can hold any  socket option value (e.g.  and )See setSocOptValuenetwork Low level  SO_LINGER& option value, which can be used with  or  . .networkSet the linger option on.networkLinger timeout.networkSocket options for use with  and .The existence of a constructor does not imply that the relevant option is supported on your system: see network,Receiving IPV6_PKTINFO (struct in6_pktinfo).networkReceiving IPv6 traffic class.networkReceiving IPv6 hop limit.network'IPV6_V6ONLY: don't use this on OpenBSD.network)Receiving IP_PKTINFO (struct in_pktinfo).networkReceiving IPv4 TOS.networkReceiving IPv4 TTL.networkIP_TTLnetworkTCP_CORKnetworkTCP_USER_TIMEOUTnetwork TCP_NODELAYnetwork TCP_MAXSEGnetworkSO_USELOOPBACKnetworkSO_SNDTIMEO: timeout in microseconds. This option is not useful in the normal case where sockets are non-blocking.networkSO_RCVTIMEO: timeout in microseconds. This option is not useful in the normal case where sockets are non-blocking.network SO_SNDLOWATnetwork SO_RCVLOWATnetwork SO_REUSEPORTnetwork:SO_LINGER: timeout in seconds, 0 means disabling/disabled.network SO_OOBINLINEnetwork SO_KEEPALIVEnetwork SO_RCVBUFnetwork SO_SNDBUFnetwork SO_BROADCASTnetwork SO_DONTROUTEnetworkSO_ERRORnetworkSO_PROTOCOL, read-onlynetworkSO_TYPE, read-onlynetworkSO_DOMAIN, read-onlynetwork SO_REUSEADDRnetworkSO_DEBUGnetworkSO_ACCEPTCONN, read-onlynetwork Does the  exist on this system?networkExecute the given action only when the specified socket option is supported. Any return value is ignored.network$Set a socket option that expects an  value.networkSet a socket option.networkSet a socket option valueThe existential  enables things like: mapM_ (uncurry $  sock) [ (,  @Int 1) , (,  ( 1 0)) ] network"Get a socket option that gives an  value.networkGet a socket option.networkGet the   of an active socket.Since: 3.0.1.0network Option Levelnetwork Option Name4 Safe-Inferred`CnetworkCreate a new socket using the given address family, socket type and protocol number. The address family is usually b, a, or c. The socket type is usually k or j". The protocol number is usually w. If a is used and the socket type is k or j, the  socket option is set to 0 so that both IPv4 and IPv6 can be handled with one socket.import Network.Socket)import qualified Data.List.NonEmpty as NElet hints = defaultHints { addrFlags = [AI_NUMERICHOST, AI_NUMERICSERV], addrSocketType = Stream }addr <- NE.head <$> getAddrInfo (Just hints) (Just "127.0.0.1") (Just "5000")sock <- socket (addrFamily addr) (addrSocketType addr) (addrProtocol addr)+Network.Socket.bind sock (addrAddress addr)getSocketName sock127.0.0.1:5000networkBind the socket to an address. The socket must not already be bound. The  passed to bind% must be the same as that passed to . If the special port number { is passed then the system assigns the next available use port.network&Connect to a remote socket at address.networkListen for connections made to the socket. The second argument specifies the maximum number of queued connections and should be at least 1; the maximum value is system-dependent (usually 5).networkAccept a connection. The socket must be bound to an address and listening for connections. The return value is a pair (conn, address) where conn is a new socket object usable to send and receive data on the connection, and address is the address bound to the socket on the other end of the connection. On Unix, FD_CLOEXEC is set to the new ".  Safe-InferredaanetworkGetting peer's socket address.networkGetting my socket address.networkGetting the port of socket. & is thrown if a port is not available.networkGetting the port of socket. Safe-Inferred%&{network>Resolve a host or service name to one or more addresses. The + values that this function returns contain ' values that you can pass directly to  or .This function calls getaddrinfo(3), which never successfully returns with an empty list. If the query fails,  throws an IO exception..For backwards-compatibility reasons, a hidden  class is used to make the result polymorphic. It only has instances for [] (lists) and  . Use of  is recommended.This function is protocol independent. It can return both IPv4 and IPv6 address information.The  argument specifies the preferred query behaviour, socket options, or protocol. You can override these conveniently using Haskell's record update syntax on , for example as follows:let hints = defaultHints { addrFlags = [AI_NUMERICHOST], addrSocketType = Stream }You must provide a  value for at least one of the  or  arguments.  can be either a numeric network address (dotted quad for IPv4, colon-separated hex for IPv6) or a hostname. In the latter case, its addresses will be looked up unless 3 is specified as a hint. If you do not provide a  value and do not set  as a hint, network addresses in the result will contain the address of the loopback interface.There are several reasons why a query might result in several values. For example, the queried-for host could be multihomed, or the service might be available via several protocols.Note: the order of arguments is slightly different to that defined for  getaddrinfo in RFC 2553. The ; parameter comes first to make partial application easier.)import qualified Data.List.NonEmpty as NEaddr <- NE.head <$> getAddrInfo (Just hints) (Just "127.0.0.1") (Just "http")addrAddress addr 127.0.0.1:80#Polymorphic version: @since 3.2.3.0network-Flags that control the querying behaviour of . For more information, see +https://tools.ietf.org/html/rfc3493#page-30networkResolve a datagram-based service name. This is required only for the few protocols that have different port numbers for their datagram-based versions than for their stream-based versions.network;If the hostname cannot be looked up, an IO error is thrown.network>If a host is local, return only the hostname part of the FQDN.networkThe name of the host is not looked up. Instead, a numeric representation of the host's address is returned. For an IPv4 address, this will be a dotted-quad string. For IPv6, it will be colon-separated hexadecimal.networkThe name of the service is not looked up. Instead, a numeric representation of the service is returned.network-Flags that control the querying behaviour of . For more information, see +https://tools.ietf.org/html/rfc3493#page-25networkThe list of returned  values will only contain IPv4 addresses if the local system has at least one IPv4 interface configured, and likewise for IPv6. (Only some platforms support this.)networkIf  is specified, return all matching IPv6 and IPv4 addresses. Otherwise, this flag has no effect. (Only some platforms support this.)networkThe  field of the first returned / will contain the "canonical name" of the host.networkThe  argument must be a numeric address in string form, and network name lookups will not be attempted.networkThe  argument must be a port number in string form, and service name lookups will not be attempted. (Only some platforms support this.)networkIf no 3 value is provided, the network address in each  will be left as a "wild card". This is useful for server applications that will accept connections from any client.networkIf an IPv6 lookup is performed, and no IPv6 addresses are found, IPv6-mapped IPv4 addresses will be returned. (Only some platforms support this.)networkEither a service name e.g., "http" or a numeric port number.networkEither a host name e.g.,  "haskell.org" or a numeric host address string consisting of a dotted decimal IPv4 address or an IPv6 address e.g.,  "192.168.0.1".networkIndicate whether the given & will have any effect on this system.network&Default hints for address lookup with .addrFlags defaultHints[]addrFamily defaultHints AF_UNSPECaddrSocketType defaultHints NoSocketTypeaddrProtocol defaultHints0networkResolve an address to a host or service name. This function is protocol independent. The list of ! values controls query behaviour.If a host or service's name cannot be looked up, then the numeric form of the address or service will be returned.9If the query fails, this function throws an IO exception.addr:_ <- getAddrInfo (Just defaultHints) (Just "127.0.0.1") (Just "http")getNameInfo [NI_NUMERICHOST, NI_NUMERICSERV] True True $ addrAddress addr(Just "127.0.0.1",Just "80")networkPack a list of values into a bitmask. The possible mappings from value to bit-to-set are given as the first argument. We assume that each value can cause exactly one bit to be set; unpackBits will break if this property is not true.network'Unpack a bitmask into a list of values.networkShow an IPv6 address in the most appropriate notation, based on recommended representation proposed by  "http://tools.ietf.org/html/rfc5952RFC 5952./The implementation is completely compatible with the current implementation of the  inet_ntop function in glibc./network)A utility function to open a socket with 1. This is a just wrapper for the following code: \addr -> socket (addrFamily addr) (addrSocketType addr) (addrProtocol addr)network,SockAddrInet6 80 0 (0,0,0xffff,0x01020304) 0[::ffff:1.2.3.4]:80network!preferred socket type or protocolnetworkhost name to look upnetworkservice name to look upnetwork%resolved addresses, with "best" firstnetwork!preferred socket type or protocolnetworkhost name to look upnetworkservice name to look upnetwork%resolved addresses, with "best" firstnetwork!flags to control lookup behaviournetworkwhether to look up a hostnamenetwork!whether to look up a service namenetworkthe address to look up. Safe-Inferred~networkTurns a Socket into an 1. By default, the new handle is unbuffered. Use  to change the buffering.Note that since a  is automatically closed by a finalizer when it is no longer referenced, you should avoid doing any more operations on the " after calling . To close the " after , call  on the .Caveat  is not recommended for network programming in Haskell, e.g. merely performing hClose. on a TCP socket won't cooperate with peer's  gracefulClose, i.e. proper shutdown sequence with appropriate handshakes specified by the protocol.(c) Johan Tibell 2007-2010 BSD-stylejohan.tibell@gmail.comstableportable Safe-Inferred< Safe-Inferred%networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkSend data to the socket. The socket must be connected to a remote socket. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkReceive data from the socket, writing it into buffer instead of creating a new string. The socket need not be in a connected state. Returns (nbytes, address) where nbytes& is the number of bytes received and address is a 1 representing the address of the sending socket.0If the first return value is zero, it means EOF.For k3 sockets, the second return value would be invalid.NOTE: blocking on Windows unless you compile with -threaded (see GHC ticket #1129)networkReceive data from the socket. The socket must be in a connected state. This function may return fewer bytes than specified. If the message is longer than the specified length, it may be discarded depending on the type of socket. This function may block until a message arrives.Considering hardware and network realities, the maximum number of bytes to receive should be a small power of 2, e.g., 4096.The return value is the length of received data. Zero means EOF. Historical note: Version 2.8.x.y or earlier, an EOF error was thrown. This was changed in version 3.0.networkReceive data from the socket. This function returns immediately even if data is not available. In other words, IO manager is NOT involved. The length of data is returned if received. -1 is returned in the case of EAGAIN or EWOULDBLOCK. -2 is returned in other error cases.network)Send data to the socket using sendmsg(2).networkReceive data from the socket using recvmsg(2). The supplied buffers are filled in order, with subsequent buffers used only after all the preceding buffers are full. If the message is short enough some of the supplied buffers may remain unused.networkSocketnetworkDestination addressnetworkData to be sentnetworkControl messagesnetwork Message flagsnetworkThe length actually sentnetworkSocketnetworkA list of (buffer, buffer-length) pairs. If the total length is not large enough,  is returnednetworkThe buffer size for control messages. If the length is not large enough,  is returnednetwork Message flagsnetworkSource address, total bytes received, control messages and message flags  Safe-Inferred networkGetting peer's .network Getting my .network&Connect to a remote socket at address.networkBind the socket to an address. The socket must not already be bound. The  passed to bind% must be the same as that passed to socket. If the special port number { is passed then the system assigns the next available use port.networkAccept a connection. The socket must be bound to an address and listening for connections. The return value is a pair (conn, address) where conn is a new socket object usable to send and receive data on the connection, and address is the address bound to the socket on the other end of the connection. On Unix, FD_CLOEXEC is set to the new ".networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkReceive data from the socket, writing it into buffer instead of creating a new string. The socket need not be in a connected state. Returns (nbytes, address) where nbytes& is the number of bytes received and address is a 1 representing the address of the sending socket.0If the first return value is zero, it means EOF.For k3 sockets, the second return value would be invalid.NOTE: blocking on Windows unless you compile with -threaded (see GHC ticket #1129)network)Send data to the socket using sendmsg(2).network.Receive data from the socket using recvmsg(2).networkSocketnetworkDestination addressnetworkData to be sentnetworkControl messagesnetwork Message flagsnetworkThe length actually sentnetworkSocketnetworkA list of a pair of buffer and its size. If the total length is not large enough,  is returnednetworkThe buffer size for control messages. If the length is not large enough,  is returnednetwork Message flagsnetworkSource address, received data, control messages and message flags ! Safe-InferrednetworkShut down one or both halves of the connection, depending on the second argument to the function. If the second argument is ., further receives are disallowed. If it is +, further sends are disallowed. If it is ,, further sends and receives are disallowed.networkClosing a socket gracefully. This sends TCP FIN and check if TCP FIN is received from the peer. The second argument is time out to receive TCP FIN in millisecond. In both normal cases and error cases, socket is deallocated finally.Since: 3.1.1.0"(c) Johan Tibell 2007-2010 BSD-stylejohan.tibell@gmail.comstableportable Safe-Inferred"%& networkSend data to the socket. The socket must be connected to a remote socket. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkSend data to the socket. The socket must be connected to a remote socket. Unlike , this function continues to send data until either all data has been sent or an error occurs. On error, an exception is raised, and there is no way to determine how much data, if any, was successfully sent.networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Unlike , this function continues to send data until either all data has been sent or an error occurs. On error, an exception is raised, and there is no way to determine how much data, if any, was successfully sent.networkSend data to the socket. The socket must be in a connected state. The data is sent as if the parts have been concatenated. This function continues to send data until either all data has been sent or an error occurs. On error, an exception is raised, and there is no way to determine how much data, if any, was successfully sent.networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. The data is sent as if the parts have been concatenated. This function continues to send data until either all data has been sent or an error occurs. On error, an exception is raised, and there is no way to determine how much data, if any, was successfully sent.networkSend data and file descriptors over a UNIX-domain socket in a single system call. This function does not work on Windows.networkReceive data from the socket. The socket must be in a connected state. This function may return fewer bytes than specified. If the message is longer than the specified length, it may be discarded depending on the type of socket. This function may block until a message arrives.Considering hardware and network realities, the maximum number of bytes to receive should be a small power of 2, e.g., 4096.For TCP sockets, a zero length return value means the peer has closed its half side of the connection.Currently, the  family is blocked on Windows because a proper IO manager is not implemented. To use with #$ on Windows, use % with & as well.networkReceive data from the socket. The socket need not be in a connected state. Returns (bytes, address) where bytes is a $ representing the data received and address is a 0 representing the address of the sending socket.0If the first return value is zero, it means EOF.network,Suppose we try to transmit a list of chunks cs0 via a gathering write operation and find that n bytes were sent. Then remainingChunks n cs) is list of chunks remaining to be sent.networkwithIOVecfromBS cs f executes the computation f, passing as argument a pair consisting of a pointer to a temporarily allocated array of pointers to IOVec made from cs and the number of pointers ( length cs).  Unix only.network)Send data to the socket using sendmsg(2).network.Receive data from the socket using recvmsg(2). networkConnected socketnetwork Data to sendnetworkNumber of bytes sentnetworkConnected socketnetwork Data to sendnetworkSocketnetwork Data to sendnetworkRecipient addressnetworkNumber of bytes sentnetworkSocketnetwork Data to sendnetworkRecipient addressnetworkConnected socketnetwork Data to sendnetworkSocketnetwork Data to sendnetworkRecipient addressnetworkSocketnetwork Data to sendnetworkFile descriptorsnetworkConnected socketnetwork"Maximum number of bytes to receivenetwork Data receivednetworkSocketnetwork"Maximum number of bytes to receivenetwork Data received and sender addressnetworkSocketnetworkDestination addressnetworkData to be sentnetworkControl messagesnetwork Message flagsnetworkThe length actually sentnetworkSocketnetworkThe maximum length of data to be received If the total length is not large enough,  is returnednetworkThe buffer size for control messages. If the length is not large enough,  is returnednetwork Message flagsnetworkSource address, received data, control messages and message flags' Safe-Inferred"wnetworkConnected socketnetwork Data to sendnetworkNumber of bytes sentnetworkConnected socketnetwork Data to send(c) Johan Tibell 2007-2010 BSD-stylejohan.tibell@gmail.comstableportable Safe-Inferred[networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Returns the number of bytes sent. Applications are responsible for ensuring that all data has been sent.networkSend data to the socket. The recipient can be specified explicitly, so the socket need not be in a connected state. Unlike , this function continues to send data until either all data has been sent or an error occurs. On error, an exception is raised, and there is no way to determine how much data, if any, was successfully sent.networkReceive data from the socket. The socket need not be in a connected state. Returns (bytes, address) where bytes is a $ representing the data received and address is a 0 representing the address of the sending socket.   Safe-Inferred( Safe-InferredVnetworkGetting process ID, user ID and group ID for UNIX-domain sockets.This is implemented with SO_PEERCRED on Linux and getpeereid() on BSD variants. Unfortunately, on some BSD variants getpeereid() returns unexpected results, rather than an error, for AF_INET sockets. It is the user's responsibility to make sure that the socket is a UNIX-domain socket. Also, on some BSD variants, getpeereid() does not return credentials for sockets created via , only separately created and then explicitly connected UNIX-domain sockets work on such systems.Since 2.7.0.0.networkReturns the processID, userID and groupID of the peer of a UNIX-domain socket.5Only available on platforms that support SO_PEERCRED.networkReturns the userID and groupID of the peer of a UNIX-domain socket.6Only available on platforms that support getpeereid().network5Whether or not UNIX-domain sockets are available. c is supported on Windows since 3.1.3.0. So, this variable is  on all platforms.Since 2.7.0.0.networkSend a file descriptor over a UNIX-domain socket. This function does not work on Windows.networkReceive a file descriptor over a UNIX-domain socket. Note that the resulting file descriptor may have to be put into non-blocking mode in order to be used safely. See  ,. This function does not work on Windows.networkBuild a pair of connected socket objects. On Windows, this function emulates socketpair() using c" and a temporary file will remain."(c) The University of Glasgow 20012BSD-style (see the file libraries/network/LICENSE)libraries@haskell.org provisionalportable Safe-Inferreduv"rpqsot nmlkjihgxfedcba`_^]\[ZYXWVUTSRQPONMLKJIHGFEDCBA@?>=<;:9876543210/.-,+*)('&%$#yz!w|}~{   uv"rpqsot nmlkjihgnmlkjihgxfedcba`_^]\[ZYXWVUTSRQPONMLKJIHGFEDCBA@?>=<;:9876543210/.-,+*)('&%$#fedcba`_^]\[ZYXWVUTSRQPONMLKJIHGFEDCBA@?>=<;:9876543210/.-,+*)('&%$#yz!w|}~{    (c) Bryan O'Sullivan 2009 BSD-stylebos@serpentine.com experimental POSIX, GHC Safe-Inferred"networkSend data and file descriptors over a UNIX-domain socket in a single system call. This function does not work on Windows.networkReceive data from the socket. The socket must be in a connected state. Data is received on demand, in chunks; each chunk will be sized to reflect the amount of data received by individual  calls.All remaining data from the socket is consumed. When there is no more data to be received, the receiving side of the socket is shut down. If there is an error and an exception is thrown, the socket is not shut down.networkReceive data from the socket. The socket must be in a connected state. This function may return fewer bytes than specified. If the received data is longer than the specified length, it may be discarded depending on the type of socket. This function may block until a message arrives.:If there is no more data to be received, returns an empty .networkSocketnetwork Data to sendnetworkFile descriptorsnetworkConnected socketnetwork Data receivednetworkConnected socketnetwork"Maximum number of bytes to receivenetwork Data received)* + , - . / 0 1 2 3 4 5 6 789:;<=>?@@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~&%         !!!!!!"""""""""""''(((((  +                             """((&network-3.2.7.0-AmdlM1SgMLbB028zdeDbX6Network.SocketNetwork.Socket.InternalNetwork.Socket.AddressNetwork.Socket.ByteStringNetwork.Socket.ByteString.LazynetworkNetwork.Socket.ImportsNetwork.Socket.IfNetwork.Socket.FlagNetwork.Socket.CbitsNetwork.Socket.FcntlNetwork.Socket.Posix.IOVecNetwork.Socket.ReadShowNetwork.Socket.TypesSystem.Posix.IOdupForeign.StorablesizeOfNetwork.Socket.STMNetwork.Socket.Posix.CmsgNetwork.Socket.Posix.MsgHdrNetwork.Socket.Posix.CmsgHdrNetwork.Socket.OptionsNetwork.Socket.SyscallNetwork.Socket.NameNetwork.Socket.InfoNetwork.Socket.Handle System.IOhClose"Network.Socket.ByteString.InternalNetwork.Socket.BufferNetwork.Socket.SockAddrNetwork.Socket.ShutdownNetwork.Socket.ByteString.IOSystem.TimeouttimeoutsetSocketOption RecvTimeOut$Network.Socket.ByteString.Lazy.PosixNetwork.Socket.Unix ifNameToIndex ifIndexToNameMsgFlag MSG_WAITALL MSG_CTRUNC MSG_TRUNCMSG_EORMSG_PEEK MSG_DONTROUTEMSG_OOBmaxListenQueuesetNonBlockIfNeededsetCloseOnExecIfNeededgetCloseOnExec getNonBlock HostAddress6 HostAddressSockAddr SockAddrInet SockAddrInet6 SockAddrUnixScopeIDFlowInfo NullSockAddr SocketAddresssizeOfSocketAddresspeekSocketAddresspokeSocketAddress PortNumberFamily packFamily SocketTypeProtocolNumberSocketAF_CAN AF_BLUETOOTH AF_WANPIPEAF_PPPOXAF_IRDA AF_ATMSVC AF_ECONETAF_ASH AF_PACKET AF_SECURITY AF_NETBEUIAF_ROSE AF_ATMPVC AF_BRIDGE AF_NETROMAF_RIFAF_RAWAF_LINKAF_ENCAPPseudo_AF_HDRCMPLTAF_ARPAF_NATM Pseudo_AF_KEYAF_ISDNAF_SIP Pseudo_AF_PIPPseudo_AF_RTIPAF_CNTAF_COIPAF_INTFAF_NDD AF_NETWAREAF_SDLAF_WANAF_CTF Pseudo_AF_XTPAF_IPX AF_GOSSIP AF_OSINETAF_AX25AF_X25 AF_NETMANAF_OSIAF_ISOAF_802AF_NIT AF_NETBIOSAF_ROUTE AF_APPLETALK AF_HYLINKAF_LATAF_DLI AF_DECnetAF_SNAAF_CCITT AF_DATAKITAF_ECMAAF_NBSAF_NSAF_CHAOSAF_PUP AF_IMPLINKAF_INET6AF_INETAF_UNIX AF_UNSPECUnsupportedFamily GeneralFamily SeqPacketRDMRawDatagramStream NoSocketTypeUnsupportedSocketTypeGeneralSocketTypefdSocketunsafeFdSocket touchSocket withFdSocket socketToFdmkSocketcloseclose'defaultProtocolisSupportedSocketTypeisSupportedFamily unpackFamily defaultPortisSupportedSockAddrhostAddressToTupletupleToHostAddresshostAddress6ToTupletupleToHostAddress6 zeroMemorywaitReadSocketSTMwaitAndCancelReadSocketSTMwaitWriteSocketSTMwaitAndCancelWriteSocketSTM IPv6PktInfo IPv4PktInfo IPv6TClassIPv4TOS IPv6HopLimitIPv4TTLControlMessagecontrolMessageId encodeCmsg decodeCmsgCmsgIdCmsgcmsgIdcmsgData CmsgIdFdsCmsgIdIPv6PktInfoCmsgIdIPv4PktInfoCmsgIdIPv6TClass CmsgIdIPv4TOSCmsgIdIPv6HopLimit CmsgIdIPv4TTLUnsupportedCmsgId lookupCmsg filterCmsgthrowSocketErrorIfMinus1Retry_%throwSocketErrorIfMinus1RetryMayBlockthrowSocketErrorIfMinus1RetrythrowSocketErrorIfMinus1_throwSocketErrorthrowSocketErrorCodethrowSocketErrorWaitReadthrowSocketErrorWaitReadButthrowSocketErrorWaitWrite withSocketsDo SocketTimeout SockOptValue StructLingersl_onoff sl_linger SocketOptionSockOptRecvIPv6PktInfoRecvIPv6TClassRecvIPv6HopLimitIPv6OnlyRecvIPv4PktInfo RecvIPv4TOS RecvIPv4TTL TimeToLiveCork UserTimeoutNoDelay MaxSegment UseLoopBack SendTimeOut SendLowWater RecvLowWater ReusePortLinger OOBInline KeepAlive RecvBuffer SendBuffer Broadcast DontRouteSoError SoProtocolTypeSoDomain ReuseAddrDebugUnsupportedSocketOptionisSupportedSocketOption whenSupported setSockOptsetSockOptValuegetSocketOption getSockOpt getSocketTypesocketbindconnectlistenaccept getPeerName getSocketName socketPortsocketPortSafe getAddrInfo NameInfoFlagNI_DGRAM NI_NAMEREQD NI_NOFQDNNI_NUMERICHOSTNI_NUMERICSERVAddrInfo addrFlags addrFamilyaddrSocketType addrProtocol addrAddress addrCanonName AddrInfoFlag AI_ADDRCONFIGAI_ALL AI_CANONNAMEAI_NUMERICHOSTAI_NUMERICSERV AI_PASSIVE AI_V4MAPPED ServiceNameHostNameaddrInfoFlagImplemented defaultHints getNameInfo openSocketsocketToHandle sendBufTosendBuf recvBufFromrecvBuf sendBufMsg recvBufMsg ShutdownCmdShutdownReceive ShutdownSend ShutdownBothshutdown gracefulClosesendsendAllsendTo sendAllTosendMany sendManyTosendManyWithFdsrecvrecvFromsendMsgrecvMsggetPeerCredentialisUnixDomainSocketAvailablesendFdrecvFd socketPair sendWithFds getContentsbaseGHC.Base Applicative<*>pure*>liftA2<* Alternativeempty<|>somemanyData.Functor.ConstConstgetConstControl.ApplicativeZipList getZipList WrappedArrow WrapArrow unwrapArrow WrappedMonad WrapMonad unwrapMonad Data.Functor<$>Functorfmap<$<**>liftAliftA3optional Data.Foldableasum MonadPlusmzeromplusMonad>>=return>>Control.Monad.Fail MonadFailfailData.TraversablemapMsequenceforM Control.MonadforeverliftMguardjoin=<<whenliftM2liftM3liftM4liftM5apvoidmapM_forM_ sequence_msumfilterM>=><=< mapAndUnzipMzipWithM zipWithM_foldMfoldM_ replicateM replicateM_unless<$!>mfilterGHC.Bits FiniteBits finiteBitSizecountLeadingZeroscountTrailingZerosBits.&..|.xor complementshiftrotatezeroBitsbitsetBitclearBit complementBittestBit bitSizeMaybebitSizeisSignedshiftL unsafeShiftLshiftR unsafeShiftRrotateLrotateRpopCount Data.BitsIffgetIffXorgetXorIorgetIorAndgetAnd bitDefaulttestBitDefaultpopCountDefaulttoIntegralSizedoneBits.^..>>..<<.!>>.!<<.ghc-prim GHC.TypesIntGHC.IntInt8Int16Int32Int64GHC.ListzipWith Data.OldListsortBy genericLength maximumBy minimumBygenericReplicate genericTake genericDropgenericSplitAt genericIndexlengthfoldlfoldrnullfoldl'foldl1sumproductfoldr1maximumminimumelemheadgroupgroupByfilterunfoldr transposesortOncycle++concatzipmapunconstaillastinitfoldl1'scanlscanl1scanl'scanrscanr1iterateiterate'repeat replicate takeWhile dropWhiletakedropsplitAtspanbreakreverseandoranyallnotElemlookup concatMap!!zip3zipWith3unzipunzip3find dropWhileEnd stripPrefix elemIndex elemIndices findIndex findIndices isPrefixOf isSuffixOf isInfixOfnubnubBydeletedeleteBy\\unionunionBy intersect intersectBy intersperse intercalate partition mapAccumL mapAccumRinsertinsertByzip4zip5zip6zip7zipWith4zipWith5zipWith6zipWith7unzip4unzip5unzip6unzip7deleteFirstsByinitstails subsequences permutationssort singletonlinesunlineswordsunwords Data.ListisSubsequenceOf GHC.MaybeMaybeNothingJust Data.MaybemaybeisJust isNothingfromJust fromMaybe maybeToList listToMaybe catMaybesmapMaybeData.Semigroup.InternalAnygetAnySumgetSumProduct getProduct Data.MonoidLastgetLastFirstgetFirstMonoidmemptymappendmconcatAltgetAltAllgetAllEndoappEndoDualgetDualApgetAp<>OrderingLTEQGT GHC.ClassesOrdcompare>=<<=>maxminData.OrdDowngetDownclamp comparingGHC.WordWord8WordWord64Word32Word16 byteSwap16 byteSwap32 byteSwap64 bitReverse8 bitReverse16 bitReverse32 bitReverse64 GHC.ForeignCString CStringLenForeign.C.String CWStringLenCWString peekCStringpeekCStringLen newCString newCStringLen withCStringwithCStringLencharIsRepresentablecastCCharToCharcastCharToCCharcastCUCharToCharcastCharToCUCharcastCSCharToCharcastCharToCSChar peekCAStringpeekCAStringLen newCAStringnewCAStringLen withCAStringwithCAStringLen peekCWStringpeekCWStringLen newCWStringnewCWStringLen withCWStringwithCWStringLenForeign.C.TypesCUIntMaxCIntMaxCUIntPtrCIntPtrCJmpBufCFposCFile CSUSeconds CUSecondsCTimeCClock CSigAtomicCWcharCSizeCPtrdiffCDoubleCFloatCBoolCULLongCLLongCULongCLongCUIntCIntCUShortCShortCUCharCSCharCCharGHC.PtrPtrFunPtr Foreign.PtrIntPtrWordPtrfreeHaskellFunPtrnullPtrcastPtrplusPtralignPtrminusPtr nullFunPtr castFunPtrcastFunPtrToPtrcastPtrToFunPtr ptrToWordPtr wordPtrToPtr ptrToIntPtr intPtrToPtrStorable alignment peekElemOff pokeElemOff peekByteOff pokeByteOffpeekpoke GHC.FloatFloatingpiexplogsqrt**logBasesincostanasinacosatansinhcoshtanhasinhacoshatanhlog1pexpm1log1pexplog1mexpGHC.Real showSigned showFloat floatToDigitsfromRatGHC.Read lexDigitsNumericreadIntreadBinreadOctreadDecreadHex readFloat readSignedshowInt showEFloat showFFloat showGFloat showFFloatAlt showGFloatAlt showHFloat showIntAtBaseshowHexshowOctshowBin fromMsgFlagfGetFdfGetFl fdCloexec oNonBlock sockNonBlock sockCloexecFalse c_fcntl_read withIOVecIOVeciovBaseiovLeneqFsteqSnd lookBetween namePrefixdefShowdefRead_showInt_readIntsafeInt showIntInt readIntInt BijectionPair expectPrefix bijectiveShow bijectiveReadapp_precIn6AddrntohlhtonlSystem.Posix.TypesFdTruesizeOfSockAddr withSockAddr pokeSockAddr peekSockAddrinvalidateSocketc_closepackSocketTypeunpackSocketTypewithSocketAddresswithNewSocketAddresshostAddressToTuple'cmsgType cmsgLevelencodeStorableCmsgdecodeStorableCmsgcmsgIdBijectionGHC.IO.ExceptionIOError(throwSocketErrorIfMinus1RetryMayBlockButIOMsgHdrmsgName msgNameLenmsgIov msgIovLenmsgCtrl msgCtrlLenmsgFlags withCmsgs parseCmsgs AcceptConn CustomSockOpt c_accept4c_listen c_connectc_bindc_socket connectLoop GetAddrInfoNonEmptypackBits unpackBitsshowHostAddress6$fShowSockAddr getAddrInfoNE c_getnameinfoc_gai_strerrorc_freeaddrinfo c_getaddrinfo aiFlagMapping niFlagMappinggetAddrInfoListfollowAddrInfo gai_strerror withCStringIfshowHostAddressshowHostAddress'GHC.IO.Handle.TypesHandle GHC.IO.Handle hSetBufferingmkInvalidRecvArgErrorc_writev c_sendmsg c_recvmsg recvBufNoWaitbytestring-0.11.5.2Data.ByteString.Internal.Type ByteStringremainingChunkswithIOVecfromBS waitWhen0 getPeerCred getPeerEidData.ByteString.Lazy.Internal