Documentation
¶
Index ¶
- Constants
- func DefaultCommitteeVerifierVersionTag() [4]byte
- func FilterRemoteSelectors(selectors []uint64, localSelector uint64) []uint64
- func FindStellarRoot() (string, error)
- func GenerateContractAddress(name, networkPassphrase string) []byte
- func MustGenerateMockContractID(deployerAddress, contractName string) string
- func ParseFeeAggregatorAddress(s string) (string, error)
- func ResolveSignersFromOffchainTopology(topology *offchain.EnvironmentTopology, sourceChainSelector uint64, ...) ([][32]byte, uint32)
- func ResolveSignersFromTopology(topology *ccvdeployment.EnvironmentTopology, sourceChainSelector uint64, ...) ([][32]byte, uint32)
- func ResolveUpgradeWasmPath(contractType string) (string, error)
- func StrkeyToHex(addr string) (string, error)
- func UpgradeWasmFilename(contractType string) (string, bool)
Constants ¶
const NoExecutionExecutorStrkey = "CDV2KF6SAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEJ6"
NoExecutionExecutorStrkey is the Stellar contract strkey of the no-execution sentinel executor: the 0xEBa517d2… EVM NoExecution address, strkey-encoded.
It mirrors the Rust NO_EXECUTION_STRKEY constant (contracts/common/message/src/lib.rs) so the shared lane sequence can apply the EVM SkipExecutorConfig semantics without a Rust dependency. Writing this value as an OnRamp dest-chain DefaultExecutor means "the destination chain does not support execution" — the onramp must not route to a real executor.
Keep in sync with the Rust constant; executor_sentinel_test.go pins the encoding so a drift fails tests rather than silently diverging.
Variables ¶
This section is empty.
Functions ¶
func DefaultCommitteeVerifierVersionTag ¶
func DefaultCommitteeVerifierVersionTag() [4]byte
DefaultCommitteeVerifierVersionTag returns the default bytes4 committee verifier version tag used when initializing the Stellar CommitteeVerifier. Matches bytes4(keccak256("CommitteeVerifier 2.0.0")) — same as EVM chains/evm/deployment/v2_0_0/verifier_tags.CommitteeVerifierV2 and ccvs-committee-verifier `DEFAULT_VERIFIER_VERSION_TAG`.
func FilterRemoteSelectors ¶
FilterRemoteSelectors returns selectors other than 0 and localSelector, deduplicated and sorted.
func FindStellarRoot ¶
FindStellarRoot locates the chainlink-stellar project root — the directory whose go.mod declares module github.com/smartcontractkit/chainlink-stellar — first via the CHAINLINK_STELLAR_ROOT environment variable, then by walking up from CWD. Matching by module path (rather than just "any go.mod") is required because tests/ and deployment/ are their own Go modules; a naive go.mod search started from tests/ would stop there and return the wrong directory.
This works whether the devenv CLI is run from the repo root directly or from a subdirectory (e.g. `cd tests && …`).
Cross-repo consumers whose process CWD is NOT a descendant of the chainlink-stellar checkout (notably the chainlink-deployments ccv staging pipelines, whose CWD is the chainlink-deployments repo — a SIBLING of chainlink-stellar) cannot reach the root by walking up. Such consumers set CHAINLINK_STELLAR_ROOT to the absolute path of a chainlink-stellar checkout (with its WASMs already built via `stellar contract build` / `make build`) to bypass the walk. The override is validated to declare the expected root module path. This matches the override convention already used by ResolveMCMSWasmPath / ResolveTimelockWasmPath / ResolveCREForwarderWasmPath.
func GenerateContractAddress ¶
GenerateContractAddress returns a deterministic Soroban contract address seed (32 bytes) from a logical name and network passphrase.
func MustGenerateMockContractID ¶
MustGenerateMockContractID returns a deterministic mock contract strkey (C…) for tests/devenv.
func ParseFeeAggregatorAddress ¶
ParseFeeAggregatorAddress normalizes a fee-aggregator address for Stellar OnRamp, VVR, and CommitteeVerifier. It accepts a Stellar strkey (G… account or C… contract) or 0x-prefixed 32-byte hex (raw address bytes). Hex input is encoded as an account strkey (G…); for a contract fee sink pass the C… strkey explicitly.
func ResolveSignersFromOffchainTopology ¶
func ResolveSignersFromOffchainTopology(topology *offchain.EnvironmentTopology, sourceChainSelector uint64, preferredFamily string) ([][32]byte, uint32)
ResolveSignersFromOffchainTopology is the same as ResolveSignersFromTopology but uses the chainlink-ccip offchain topology type carried on DeployChainContractsInput.
func ResolveSignersFromTopology ¶
func ResolveSignersFromTopology(topology *ccvdeployment.EnvironmentTopology, sourceChainSelector uint64, preferredFamily string) ([][32]byte, uint32)
ResolveSignersFromTopology extracts signer addresses and threshold for a given source chain selector from the environment topology.
Committee verifier contracts store 20-byte ETH-style ECDSA addresses, left-padded to 32 bytes on Soroban. Topology may record those under chainsel.FamilyEVM and/or chainsel.FamilyStellar (devenv enriches NOPs per impl factory family).
preferredFamily is tried first for each NOP (e.g. chainsel.FamilyStellar when the source lane is Stellar), then chainsel.FamilyEVM, then chainsel.FamilyStellar, without duplicates.
func ResolveUpgradeWasmPath ¶
ResolveUpgradeWasmPath returns the path to the freshly-compiled release WASM for the given contract type. Resolution order (mirrors ResolveMCMSWasmPath / ResolveTimelockWasmPath):
- STELLAR_<UPPER_TYPE>_WASM env var (full path override, e.g. STELLAR_FEEQUOTER_WASM=/tmp/fee_quoter.wasm).
- CHAINLINK_STELLAR_ROOT (module-validated) + releaseWasmDir/<name>.wasm.
- cwd-relative releaseWasmDir/<name>.wasm.
The override lets an operator point at a specific artifact (e.g. one built in a different checkout) without rebuilding in place.
func StrkeyToHex ¶
StrkeyToHex decodes a strkey address (C… contract or G… account) to a 0x-prefixed hex string.
func UpgradeWasmFilename ¶
UpgradeWasmFilename returns the release WASM filename for the given contract type, or false if the type is not an upgradeable CCIP contract.
Types ¶
This section is empty.