Description
Ancillary data violates the one-byte, one-descriptor protocol.
Adopt
procedure Adopt
(Item : in out Handoff_Channel;
Socket : in out Flyology.IO.Sockets.Socket_Type;
Trust : Peer_Trust := Trusted_Peer)
Transfer a connected AF_UNIX stream socket into a closed channel.
Parameters
- Item
Closed destination channel
- Socket
Connected stream socket whose ownership is transferred
- Trust
Peer trust used for carrier and capability validation
Channel_Busy
Channel_Busy : exception;
A second operation attempted to use the serialized channel.
Close
procedure Close (Item : in out Handoff_Channel)
Close the carrier and consume channel ownership.
Parameters
- Item
Channel to close
Handoff_Channel
type Handoff_Channel is limited private;
Sole owner of one dedicated one-byte, one-descriptor protocol endpoint. No ordinary I/O or duplicate endpoint may share the stream. A transport, protocol, or received-capability failure poisons and closes the channel.
Is_Open
function Is_Open (Item : Handoff_Channel) return Boolean
Report whether the channel currently owns an open carrier.
Parameters
- Item
Channel to inspect
Return value
True when the carrier is open
Is_Poisoned
function Is_Poisoned (Item : Handoff_Channel) return Boolean
Report whether an earlier operation poisoned the channel.
Parameters
- Item
Channel to inspect
Return value
True when failure made the carrier unusable
Operating_System_Error
Operating_System_Error : exception;
A carrier, descriptor, or socket system call failed.
Peer_Trust
type Peer_Trust is (Trusted_Peer, Untrusted_Peer);
Trust applied while validating a carrier and received descriptor.
Enumeration literals
- Trusted_Peer
The peer belongs to the trusted coordinator protocol
- Untrusted_Peer
Apply supported hostile-peer descriptor checks
Protocol_Error
Protocol_Error : exception;
Ancillary data violates the one-byte, one-descriptor protocol.
Receive_Listener
procedure Receive_Listener
(Channel : in out Handoff_Channel; Item : in out Flyology.IO.Sockets.Socket_Type)
Receive, validate, prepare, and adopt exactly one stream listener. Item remains closed on failure.
Parameters
- Channel
Dedicated capability channel
- Item
Closed destination socket
Security_Error
Security_Error : exception;
The carrier or received capability fails the requested trust policy.
Send_Listener
procedure Send_Listener
(Channel : in out Handoff_Channel;
Item : in out Flyology.IO.Sockets.Socket_Type;
Ownership : Send_Ownership := Borrow)
Send one open listening socket. Borrow retains Item; Transfer closes it only after the kernel accepts the descriptor record locally.
Parameters
- Channel
Dedicated capability channel
- Item
Listening socket capability
- Ownership
Sender ownership after successful local acceptance
Send_Ownership
type Send_Ownership is (Borrow, Transfer);
Sender ownership after local kernel acceptance.
Enumeration literals
- Borrow
Retain the local listener
- Transfer
Close the local listener after successful send
Validation_Error
Validation_Error : exception;
A received descriptor is not a listening stream socket.