package services import ( "encoding/json" "fmt" "qteam/app/http/entities/front" ) func DecryptXyData(data string) (info front.XyDecryptData) { // 先解Base64,再解Hex16进 decrypt, err := SM2Decrypt(data) if err != nil { return } err = json.Unmarshal([]byte(decrypt), &info) if err != nil { fmt.Println("解析JSON错误:", err) return } return }