at_lookup_io library

at_lookup on a native socket: everything in at_lookup.dart, plus the transport that reaches an atServer over TLS on TCP.

The split exists so that naming the native transport is what pulls the native imports in. A caller that imports only at_lookup.dart and injects its own transport does not acquire dart:io through a default it never asked for — which is the way a transport swap otherwise fails silently instead of failing to compile.

Both halves are here: the transport that carries the atServer session, and CacheableSecondaryAddressFinder, which resolves an atSign to a host by asking the atDirectory over raw TLS. A caller that imports at_lookup.dart alone supplies both — its own AtTransportFactory, and a SecondaryAddressFinder such as FixedSecondaryAddressFinder.

Classes

AtCommandExecutor
The narrow view of a connection that an AtAuthenticator is given: enough to run a challenge-response, and nothing else.
AtLookUp
AtLookUpExceptionUtil
AtLookUpExceptionUtil to get ErrorCode and ErrorDescription
AtLookupImpl
AtLookupMessageListenerFactory
Builds the listener that reads an open connection, over any transport.
AtLookupMuxable
An AtLookUp that also carries the atServer's asynchronous notification stream, so one class reads every kind of message the atServer sends.
AtLookupOutboundConnectionFactory
AtLookupSecureSocketFactory
Opens the raw TLS socket SecondaryUrlFinder asks the atDirectory over.
AtLookupTransport
How an AtLookupMuxable makes connections: the three factories AtLookupImpl has always accepted, bundled into one value.
AtSignServerCheck
What checkAtSignServer found: the state, and for the two unreachable states the cause the lookup failed with.
AtTransport
A bidirectional byte channel to an atServer, opened by an AtTransportFactory.
AtTransportFactory
Opens AtTransports.
CacheableSecondaryAddressFinder
Finds an atSign's atServer by asking the atDirectory at a root domain and port, and keeps each answer for an hour, or the duration it is given.
FixedSecondaryAddressFinder
Resolves every atSign to one fixed address, without touching the network.
OutboundConnection
OutboundConnectionImpl
OutboundConnectionMetadata
Metadata information for OutboundConnection
SecondaryAddress
SecondaryAddressCacheEntry
An atServer address CacheableSecondaryAddressFinder keeps, and when it stops being used.
SecondaryAddressFinder
SecondaryUrlFinder
When SecondaryUrlFinder tries to lookup the atServer's address from an atDirectory, it may encounter intermittent failures for various reasons - 'network weather', service glitches, etc.
SecureSocketConfig
class to store configuration to create a security context while creating secure sockets
SecureSocketTransport
TLS over TCP: the AtTransport a native program connects with.
SecureSocketTransportFactory
Opens SecureSocketTransports, carrying the TLS settings they are opened with.
SecureSocketUtil
Opens the TLS sockets at_lookup connects to an atServer or atDirectory over.

Enums

AtSignServerState
Where an atSign stands, as the atDirectory and its atServer report it.

Functions

checkAtSignServer(AtLookUp lookUp, String atSign, {Duration? timeout}) → Future<AtSignServerCheck>
Asks, over lookUp, whether atSign is in the atDirectory, whether its atServer answers, and whether the atSign has been activated.
secureSocketLookUps({SecureSocketConfig? config, Future<void> onConnect(AtCommandExecutor connection)?}) → AtLookUpFactory
The default AtLookUpFactory: every connection over TLS on TCP, under config (the TLS defaults with none), through AtLookUp.withSecureSocket.
secureSocketTransport(SecureSocketConfig secureSocketConfig) → AtLookupTransport
TLS over TCP — the transport to pass to AtLookUp.withSecureSocket unless you are supplying your own.
validatedFromChallenge(String challenge, String atSign) → String
Returns challenge when it is a well-formed from: challenge issued to atSign; throws UnAuthenticatedException otherwise.

Typedefs

AtAuthenticator = Future<bool> Function(AtCommandExecutor executor)
Performs one authentication on a connection that is already open, using executor to speak to the atServer, and returns whether it succeeded.
AtLookUpFactory = AtLookupMuxable Function({required String atSign, required AtAuthenticator? authenticator, required AtRootDomain rootDomain, SecondaryAddressFinder? secondaryAddressFinder})
Builds the connection a client uses to reach an atServer: what an application hands the entry points so that every connection the client opens - its own, its sync's, its monitor's - travels the way the application chose.

Exceptions / Errors

AtLookUpException
AtLookUpException class