MCPcopy Create free account
hub / github.com/AandStep/ResultV / IsEncryptedSubscription

Function IsEncryptedSubscription

internal/proxy/subscription_decrypt.go:36–41  ·  view source on GitHub ↗

IsEncryptedSubscription reports whether s carries the RVSUB1 magic prefix.

(s string)

Source from the content-addressed store, hash-verified

34
35// IsEncryptedSubscription reports whether s carries the RVSUB1 magic prefix.
36func IsEncryptedSubscription(s string) bool {
37 s = strings.TrimSpace(s)
38 s = strings.TrimPrefix(s, utf8BOM)
39 s = strings.TrimSpace(s)
40 return strings.HasPrefix(s, subscriptionMagic)
41}
42
43// DecryptSubscription unwraps an RVSUB1-prefixed payload. For non-encrypted
44// input it returns the trimmed value unchanged.

Callers 2

ParseSubscriptionTextMethod · 0.92

Calls

no outgoing calls

Tested by

no test coverage detected