Releases: a-sit-plus/cidre
Releases · a-sit-plus/cidre
Release list
0.4.0
- Add subnetting and supernetting helpers on
IpNetworksubnet(newPrefix: UInt)subnetRelative(prefixDiff: UInt)supernet(newPrefix: UInt)supernetRelative(prefixDiff: UInt)
- Add fixture-backed JVM tests for subnetting and supernetting (
subnetting.json,supernetting.json) - Add additional fixture-backed JVM coverage:
overlaps_containment.jsonpython_oracle.jsongenerated from Python stdlibipaddressset_operations.json(union collapse/covering, intersection, difference)
- Add Python-oracle fixture generator:
python-testgen/gen_python_oracle.py
- Add network set-operations on
IpNetwork:unionCollapseunionCoveringintersectiondifference
- Keep set-operation API surface explicit and unambiguous; no alias variants (
union,spanningUnion,intersect,minus) - Add range/relation APIs on
IpNetwork:toRange()fromRange(start, end)relationTo(other)withRelationenum (EQUAL,CONTAINS,WITHIN,ADJACENT,DISJOINT)
- Define canonical set-operation output contract (sorted, non-overlapping, maximally collapsed) and enforce it in operation results
- Add explicit runtime family guards for network operations/containment: mixed IPv4/IPv6 inputs now fail fast with
IllegalArgumentException(no implicit cross-family coercion) - Add randomized property-style JVM tests for set-operation invariants and range summarization roundtrips (IPv4 and IPv6)
- Add
IpAddress.V4.LeadingPrefixfor explicit bit-prefix modeling with:UByteconstructor (leadingPrefixLength,leadingPrefixValue)- signed-number constructor (
Int,Int) - bit-string constructor (
String, e.g."110") - canonical bit-string rendering via
toString()
- Clean up JVM fixture tests by removing noisy prints, tightening type handling to avoid broad unchecked-cast patterns, and renaming overlong test identifiers consistently
- Fix network flag semantics to use containment instead of exact-network equality:
isLoopbackisLinkLocalisMulticastisPrivate- IPv6 range flags (
isGlobalUnicast,isUniqueLocal,isUniqueLocalLocallyAssigned,isIpV4Mapped,isIpV4Compatible,isDocumentation,isDiscardOnly,isReserved)
- Fix IPv6 reserved special ranges initialization (
4000::/3,6000::/3) to avoid invalid-network initialization errors - Fix
IpNetwork.contains(IpInterface)to also validate that the interface address is inside the network - Fix
addressSpacefor/32and/128to avoid duplicate single-address emission - Fix
IpAddress.V6.toString(expanded = true)to emit fully padded 4-digit hextets - Tighten
IpAddress.V4.LeadingPrefix(Int, Int)validation to reject values outside0..255before conversion - Add
withSameFamilyscopes for unknown-familyIpAddressandIpNetworkvalues, exposing same-family arithmetic, bitwise, comparison, containment, overlap, adjacency, and merge operations, including network/address membership checks in both receiver directions. - Add generic
isSameFamilypredicates forIpAddressandIpAddressAndPrefix. - Fix generic
IpAddress.isV4()/IpAddress.isV6()checks. - Kotlin 2.4.0
0.3.1
Add hashCode() and equals() in IpInterface.
0.3.0
- Add methods in
IpAddressAndPrefixinterface for parsingByteArrayrepresenting address and subnet mask in X509IpAddressNamefromX509OctetstoX509Octets
0.2.0
- Revised generic type arguments
- Introduce
CidrNumberoptimized for CIDR operationsCidrNumber.V4for IPv4CidrNumber.V6for IPv6
- CIDR math helpers on IP Addresses:
toCidrNumberto get numeric representationplusminusshlshrandorxorinv
- More properties:
hostMasknumberOfHostBitslastAddressfirstAssignableHostlastAssignableHostassignableHostRangeaddressSpacelastAddressoverlapsisSubnetOfisSupernetOfisAdjacentToboradcastAddress(IPv4 only)
- Fix native interop package
0.1.0
- Data model:
- IP addresses, networks, netmasks and prefixes
- Type-safety: Never mix up IPv6 and IPv4!
- Generic properties (
isLoopback,isLinkLocal, etc…) - IPv4-specific properties (
isPrivate/isPublic) - IPv6-specific properties (
isGlobalUnicast,isIpV4Mapped, and many more)
- Parser
- Encoder (including IPv6 canonicalization)
- Masking
- Containment Checks
- Various
ByteArray-level OPs