灵隙(synapse) v1.0.0 版本

This commit is contained in:
lychang
2026-06-27 22:16:05 +08:00
parent e0025a2563
commit 7b105ded96
23 changed files with 107 additions and 9926 deletions

View File

@@ -164,6 +164,18 @@ const (
GroupMemberBusy GroupMemberStatus = "busy"
)
// =============================================================================
// Signature Algorithm
// =============================================================================
// SignatureAlgorithm defines supported signature algorithms
type SignatureAlgorithm string
const (
AlgHMACSHA256 SignatureAlgorithm = "HMAC-SHA256" // 默认
AlgHMACSHA512 SignatureAlgorithm = "HMAC-SHA512"
)
// =============================================================================
// Priority
// =============================================================================
@@ -175,6 +187,7 @@ const (
PriorityHigh Priority = "high"
PriorityNormal Priority = "normal"
PriorityLow Priority = "low"
PriorityUrgent Priority = "urgent"
)
// =============================================================================
@@ -213,8 +226,9 @@ type UnifiedSynapseMessage struct {
Broadcast bool `json:"broadcast,omitempty"`
// Security
Signature string `json:"signature,omitempty"`
Encrypt bool `json:"encrypt,omitempty"`
Signature string `json:"signature,omitempty"`
SignatureAlgorithm string `json:"signature_algorithm,omitempty"`
Encrypt bool `json:"encrypt,omitempty"`
// Timestamps
Timestamp Timestamp `json:"timestamp"`