findTrustPath

Find a trust path between two identities (first-class type).

Returns a sealed TrustPath type that makes trust relationships explicit.

Example:

when (val path = findTrustPath(verifier, issuer)) {
is TrustPath.Verified -> {
println("Trusted via path: ${path.anchors.map { it.did }}")
println("Path length: ${path.length}")
}
is TrustPath.NotFound -> {
println("No trust path found: ${path.reason}")
}
}

Return

TrustPath.Verified if a path exists, TrustPath.NotFound otherwise

Parameters

from

The verifier identity

to

The issuer identity