package security// Code generated by cdproto-gen. DO NOT EDIT.import ()// CertificateID an internal certificate ID value.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-CertificateIdtypeCertificateIDint64// Int64 returns the CertificateID as int64 value.func ( CertificateID) () int64 {returnint64()}// MixedContentType a description of mixed content (HTTP resources on HTTPS// pages), as defined by https://www.w3.org/TR/mixed-content/#categories.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-MixedContentTypetypeMixedContentTypestring// String returns the MixedContentType as string value.func ( MixedContentType) () string {returnstring()}// MixedContentType values.const (MixedContentTypeBlockableMixedContentType = "blockable"MixedContentTypeOptionallyBlockableMixedContentType = "optionally-blockable"MixedContentTypeNoneMixedContentType = "none")// MarshalEasyJSON satisfies easyjson.Marshaler.func ( MixedContentType) ( *jwriter.Writer) { .String(string())}// MarshalJSON satisfies json.Marshaler.func ( MixedContentType) () ([]byte, error) {returneasyjson.Marshal()}// UnmarshalEasyJSON satisfies easyjson.Unmarshaler.func ( *MixedContentType) ( *jlexer.Lexer) { := .String()switchMixedContentType() {caseMixedContentTypeBlockable: * = MixedContentTypeBlockablecaseMixedContentTypeOptionallyBlockable: * = MixedContentTypeOptionallyBlockablecaseMixedContentTypeNone: * = MixedContentTypeNonedefault: .AddError(fmt.Errorf("unknown MixedContentType value: %v", )) }}// UnmarshalJSON satisfies json.Unmarshaler.func ( *MixedContentType) ( []byte) error {returneasyjson.Unmarshal(, )}// State the security level of a page or resource.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-SecurityStatetypeStatestring// String returns the State as string value.func ( State) () string {returnstring()}// State values.const (StateUnknownState = "unknown"StateNeutralState = "neutral"StateInsecureState = "insecure"StateSecureState = "secure"StateInfoState = "info"StateInsecureBrokenState = "insecure-broken")// MarshalEasyJSON satisfies easyjson.Marshaler.func ( State) ( *jwriter.Writer) { .String(string())}// MarshalJSON satisfies json.Marshaler.func ( State) () ([]byte, error) {returneasyjson.Marshal()}// UnmarshalEasyJSON satisfies easyjson.Unmarshaler.func ( *State) ( *jlexer.Lexer) { := .String()switchState() {caseStateUnknown: * = StateUnknowncaseStateNeutral: * = StateNeutralcaseStateInsecure: * = StateInsecurecaseStateSecure: * = StateSecurecaseStateInfo: * = StateInfocaseStateInsecureBroken: * = StateInsecureBrokendefault: .AddError(fmt.Errorf("unknown State value: %v", )) }}// UnmarshalJSON satisfies json.Unmarshaler.func ( *State) ( []byte) error {returneasyjson.Unmarshal(, )}// CertificateSecurityState details about the security state of the page// certificate.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-CertificateSecurityStatetypeCertificateSecurityStatestruct { Protocol string`json:"protocol"`// Protocol name (e.g. "TLS 1.2" or "QUIC"). KeyExchange string`json:"keyExchange"`// Key Exchange used by the connection, or the empty string if not applicable. KeyExchangeGroup string`json:"keyExchangeGroup,omitempty"`// (EC)DH group used by the connection, if applicable. Cipher string`json:"cipher"`// Cipher name. Mac string`json:"mac,omitempty"`// TLS MAC. Note that AEAD ciphers do not have separate MACs. Certificate []string`json:"certificate"`// Page certificate. SubjectName string`json:"subjectName"`// Certificate subject name. Issuer string`json:"issuer"`// Name of the issuing CA. ValidFrom *cdp.TimeSinceEpoch`json:"validFrom"`// Certificate valid from date. ValidTo *cdp.TimeSinceEpoch`json:"validTo"`// Certificate valid to (expiration) date CertificateNetworkError string`json:"certificateNetworkError,omitempty"`// The highest priority network error code, if the certificate has an error. CertificateHasWeakSignature bool`json:"certificateHasWeakSignature"`// True if the certificate uses a weak signature aglorithm. CertificateHasSha1signature bool`json:"certificateHasSha1Signature"`// True if the certificate has a SHA1 signature in the chain. ModernSSL bool`json:"modernSSL"`// True if modern SSL ObsoleteSslProtocol bool`json:"obsoleteSslProtocol"`// True if the connection is using an obsolete SSL protocol. ObsoleteSslKeyExchange bool`json:"obsoleteSslKeyExchange"`// True if the connection is using an obsolete SSL key exchange. ObsoleteSslCipher bool`json:"obsoleteSslCipher"`// True if the connection is using an obsolete SSL cipher. ObsoleteSslSignature bool`json:"obsoleteSslSignature"`// True if the connection is using an obsolete SSL signature.}// SafetyTipStatus [no description].//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-SafetyTipStatustypeSafetyTipStatusstring// String returns the SafetyTipStatus as string value.func ( SafetyTipStatus) () string {returnstring()}// SafetyTipStatus values.const (SafetyTipStatusBadReputationSafetyTipStatus = "badReputation"SafetyTipStatusLookalikeSafetyTipStatus = "lookalike")// MarshalEasyJSON satisfies easyjson.Marshaler.func ( SafetyTipStatus) ( *jwriter.Writer) { .String(string())}// MarshalJSON satisfies json.Marshaler.func ( SafetyTipStatus) () ([]byte, error) {returneasyjson.Marshal()}// UnmarshalEasyJSON satisfies easyjson.Unmarshaler.func ( *SafetyTipStatus) ( *jlexer.Lexer) { := .String()switchSafetyTipStatus() {caseSafetyTipStatusBadReputation: * = SafetyTipStatusBadReputationcaseSafetyTipStatusLookalike: * = SafetyTipStatusLookalikedefault: .AddError(fmt.Errorf("unknown SafetyTipStatus value: %v", )) }}// UnmarshalJSON satisfies json.Unmarshaler.func ( *SafetyTipStatus) ( []byte) error {returneasyjson.Unmarshal(, )}// SafetyTipInfo [no description].//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-SafetyTipInfotypeSafetyTipInfostruct { SafetyTipStatus SafetyTipStatus`json:"safetyTipStatus"`// Describes whether the page triggers any safety tips or reputation warnings. Default is unknown. SafeURL string`json:"safeUrl,omitempty"`// The URL the safety tip suggested ("Did you mean?"). Only filled in for lookalike matches.}// VisibleSecurityState security state information about the page.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-VisibleSecurityStatetypeVisibleSecurityStatestruct { SecurityState State`json:"securityState"`// The security level of the page. CertificateSecurityState *CertificateSecurityState`json:"certificateSecurityState,omitempty"`// Security state details about the page certificate. SafetyTipInfo *SafetyTipInfo`json:"safetyTipInfo,omitempty"`// The type of Safety Tip triggered on the page. Note that this field will be set even if the Safety Tip UI was not actually shown. SecurityStateIssueIDs []string`json:"securityStateIssueIds"`// Array of security state issues ids.}// StateExplanation an explanation of an factor contributing to the security// state.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-SecurityStateExplanationtypeStateExplanationstruct { SecurityState State`json:"securityState"`// Security state representing the severity of the factor being explained. Title string`json:"title"`// Title describing the type of factor. Summary string`json:"summary"`// Short phrase describing the type of factor. Description string`json:"description"`// Full text explanation of the factor. MixedContentType MixedContentType`json:"mixedContentType"`// The type of mixed content described by the explanation. Certificate []string`json:"certificate"`// Page certificate. Recommendations []string`json:"recommendations,omitempty"`// Recommendations to fix any issues.}// CertificateErrorAction the action to take when a certificate error occurs.// continue will continue processing the request and cancel will cancel the// request.//// See: https://chromedevtools.github.io/devtools-protocol/tot/Security#type-CertificateErrorActiontypeCertificateErrorActionstring// String returns the CertificateErrorAction as string value.func ( CertificateErrorAction) () string {returnstring()}// CertificateErrorAction values.const (CertificateErrorActionContinueCertificateErrorAction = "continue"CertificateErrorActionCancelCertificateErrorAction = "cancel")// MarshalEasyJSON satisfies easyjson.Marshaler.func ( CertificateErrorAction) ( *jwriter.Writer) { .String(string())}// MarshalJSON satisfies json.Marshaler.func ( CertificateErrorAction) () ([]byte, error) {returneasyjson.Marshal()}// UnmarshalEasyJSON satisfies easyjson.Unmarshaler.func ( *CertificateErrorAction) ( *jlexer.Lexer) { := .String()switchCertificateErrorAction() {caseCertificateErrorActionContinue: * = CertificateErrorActionContinuecaseCertificateErrorActionCancel: * = CertificateErrorActionCanceldefault: .AddError(fmt.Errorf("unknown CertificateErrorAction value: %v", )) }}// UnmarshalJSON satisfies json.Unmarshaler.func ( *CertificateErrorAction) ( []byte) error {returneasyjson.Unmarshal(, )}
The pages are generated with Goldsv0.8.2. (GOOS=linux GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds.