@@ -71,11 +71,11 @@ func V3DecryptNotifyCipherText(ciphertext, nonce, additional, apiV3Key string) (
71
71
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
72
72
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
73
73
if err != nil {
74
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
74
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
75
75
}
76
76
result = & V3DecryptResult {}
77
77
if err = json .Unmarshal (decrypt , result ); err != nil {
78
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
78
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
79
79
}
80
80
return result , nil
81
81
}
@@ -85,11 +85,11 @@ func V3DecryptPartnerNotifyCipherText(ciphertext, nonce, additional, apiV3Key st
85
85
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
86
86
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
87
87
if err != nil {
88
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
88
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
89
89
}
90
90
result = & V3DecryptPartnerResult {}
91
91
if err = json .Unmarshal (decrypt , result ); err != nil {
92
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
92
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
93
93
}
94
94
return result , nil
95
95
}
@@ -99,11 +99,11 @@ func V3DecryptRefundNotifyCipherText(ciphertext, nonce, additional, apiV3Key str
99
99
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
100
100
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
101
101
if err != nil {
102
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
102
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
103
103
}
104
104
result = & V3DecryptRefundResult {}
105
105
if err = json .Unmarshal (decrypt , result ); err != nil {
106
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
106
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
107
107
}
108
108
return result , nil
109
109
}
@@ -113,11 +113,11 @@ func V3DecryptPartnerRefundNotifyCipherText(ciphertext, nonce, additional, apiV3
113
113
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
114
114
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
115
115
if err != nil {
116
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
116
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
117
117
}
118
118
result = & V3DecryptPartnerRefundResult {}
119
119
if err = json .Unmarshal (decrypt , result ); err != nil {
120
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
120
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
121
121
}
122
122
return result , nil
123
123
}
@@ -127,11 +127,11 @@ func V3DecryptCombineNotifyCipherText(ciphertext, nonce, additional, apiV3Key st
127
127
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
128
128
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
129
129
if err != nil {
130
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
130
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
131
131
}
132
132
result = & V3DecryptCombineResult {}
133
133
if err = json .Unmarshal (decrypt , result ); err != nil {
134
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
134
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
135
135
}
136
136
return result , nil
137
137
}
@@ -141,11 +141,11 @@ func V3DecryptProfitShareNotifyCipherText(ciphertext, nonce, additional, apiV3Ke
141
141
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
142
142
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
143
143
if err != nil {
144
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
144
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
145
145
}
146
146
result = & V3DecryptProfitShareResult {}
147
147
if err = json .Unmarshal (decrypt , result ); err != nil {
148
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
148
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
149
149
}
150
150
return result , nil
151
151
}
@@ -155,11 +155,11 @@ func V3DecryptScoreNotifyCipherText(ciphertext, nonce, additional, apiV3Key stri
155
155
cipherBytes , _ := base64 .StdEncoding .DecodeString (ciphertext )
156
156
decrypt , err := aes .GCMDecrypt (cipherBytes , []byte (nonce ), []byte (additional ), []byte (apiV3Key ))
157
157
if err != nil {
158
- return nil , fmt .Errorf ("aes.GCMDecrypt, err:%+v " , err )
158
+ return nil , fmt .Errorf ("aes.GCMDecrypt, err:%w " , err )
159
159
}
160
160
result = & V3DecryptScoreResult {}
161
161
if err = json .Unmarshal (decrypt , result ); err != nil {
162
- return nil , fmt .Errorf ("json.Unmarshal(%s), err:%+v " , string (decrypt ), err )
162
+ return nil , fmt .Errorf ("json.Unmarshal(%s), err:%w " , string (decrypt ), err )
163
163
}
164
164
return result , nil
165
165
}
0 commit comments