logs
logs
¶
NIP-66 operation log models.
Defines log classes for each NIP-66 monitoring test. Most tests use the standard BaseLogs success/reason pattern via Nip66BaseLogs. The RTT test uses a custom Nip66RttMultiPhaseLogs class with three separate success/reason pairs for the open, read, and write probe phases.
See Also
bigbrotr.nips.base.BaseLogs: Base class with success/reason semantic validation. bigbrotr.nips.nip66.data: Corresponding data models for each test type.
Classes¶
Nip66RttMultiPhaseLogs
¶
Bases: BaseModel
RTT probe results with multi-phase validation.
Unlike other log models, RTT probes track three separate phases (open, read, write), each with its own success/reason pair.
The open_success field is mandatory; read and write are optional.
If open_success is False, read and write must also be False
(cascading failure). For each phase, success=True requires
reason=None; success=False requires a non-None reason string.
Note
This class does not inherit from BaseLogs because the multi-phase structure requires a different validation model. The cascading failure constraint ensures that if the connection cannot be opened, read and write phases are automatically marked as failed.
See Also
bigbrotr.nips.nip66.rtt.Nip66RttMetadata: Container that pairs these logs with Nip66RttData.
Functions¶
validate_semantic
¶
Enforce success/reason consistency and phase dependency constraints.
Source code in src/bigbrotr/nips/nip66/logs.py
from_dict
classmethod
¶
to_dict
¶
Nip66BaseLogs
¶
Bases: BaseLogs
Standard NIP-66 operation log with single success/reason pair.
Inherits success/reason validation from BaseLogs. Used as the base class for all non-RTT NIP-66 log models.
See Also
Nip66RttMultiPhaseLogs: The multi-phase alternative used by RTT probes.
Nip66SslLogs
¶
Bases: Nip66BaseLogs
Log record for SSL/TLS certificate inspection.
See Also
bigbrotr.nips.nip66.ssl.Nip66SslMetadata: Container that pairs this log with Nip66SslData.
Nip66GeoLogs
¶
Bases: Nip66BaseLogs
Log record for geolocation lookup.
See Also
bigbrotr.nips.nip66.geo.Nip66GeoMetadata: Container that pairs this log with Nip66GeoData.
Nip66NetLogs
¶
Bases: Nip66BaseLogs
Log record for network/ASN lookup.
See Also
bigbrotr.nips.nip66.net.Nip66NetMetadata: Container that pairs this log with Nip66NetData.
Nip66DnsLogs
¶
Bases: Nip66BaseLogs
Log record for DNS resolution.
See Also
bigbrotr.nips.nip66.dns.Nip66DnsMetadata: Container that pairs this log with Nip66DnsData.
Nip66HttpLogs
¶
Bases: Nip66BaseLogs
Log record for HTTP header extraction.
See Also
bigbrotr.nips.nip66.http.Nip66HttpMetadata: Container that pairs this log with Nip66HttpData.