mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-12 11:20:27 +08:00
27 lines
619 B
Go
27 lines
619 B
Go
|
|
// Copyright 2022 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
|
||
|
|
|
||
|
|
package ocsp
|
||
|
|
|
||
|
|
import (
|
||
|
|
"github.com/TeaOSLab/EdgeAdmin/internal/web/actions/actionutils"
|
||
|
|
"github.com/TeaOSLab/EdgeCommon/pkg/rpc/pb"
|
||
|
|
)
|
||
|
|
|
||
|
|
type ResetAction struct {
|
||
|
|
actionutils.ParentAction
|
||
|
|
}
|
||
|
|
|
||
|
|
func (this *ResetAction) RunPost(params struct {
|
||
|
|
CertIds []int64
|
||
|
|
}) {
|
||
|
|
defer this.CreateLogInfo("重置一组证书的OCSP状态")
|
||
|
|
|
||
|
|
_, err := this.RPC().SSLCertRPC().ResetSSLCertsWithOCSPError(this.AdminContext(), &pb.ResetSSLCertsWithOCSPErrorRequest{SslCertIds: params.CertIds})
|
||
|
|
if err != nil {
|
||
|
|
this.ErrorPage(err)
|
||
|
|
return
|
||
|
|
}
|
||
|
|
|
||
|
|
this.Success()
|
||
|
|
}
|