audits

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	CommandAuditsGetEncodedResponse = "Audits.getEncodedResponse"
	CommandAuditsDisable            = "Audits.disable"
	CommandAuditsEnable             = "Audits.enable"
)
View Source
const (
	EventAuditsIssueAdded = "Audits.issueAdded"
)

Variables

View Source
var EventConstants = map[string]Unmarshaler{
	EventAuditsIssueAdded: func() json.Unmarshaler { return &IssueAddedReply{} },
}

Functions

func GetEventReply

func GetEventReply(event string) (json.Unmarshaler, bool)

Types

type AffectedCookie

type AffectedCookie struct {
	Name   string `json:"name"`   // The following three properties uniquely identify a cookie
	Path   string `json:"path"`   // No description.
	Domain string `json:"domain"` // No description.
}

AffectedCookie Information about a cookie that is affected by an inspector issue.

type AffectedRequest

type AffectedRequest struct {
	RequestID network.RequestID `json:"requestId"`     // The unique request id.
	URL       string            `json:"url,omitempty"` // No description.
}

AffectedRequest Information about a request that is affected by an inspector issue.

type DisableArgs

type DisableArgs struct {
}

DisableArgs represents the arguments for Disable in the Audits domain.

func (*DisableArgs) MarshalJSON

func (a *DisableArgs) MarshalJSON() ([]byte, error)

Marshall the byte array into a return value for Disable in the Audits domain.

func (*DisableArgs) UnmarshalJSON

func (a *DisableArgs) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for Disable in the Audits domain.

type DisableReply

type DisableReply struct {
}

DisableReply represents the return values for Disable in the Audits domain.

func (*DisableReply) GetFrameID

func (a *DisableReply) GetFrameID() string

DisableReply returns the FrameID value for Disable in the Audits domain.

func (*DisableReply) MatchFrameID

func (a *DisableReply) MatchFrameID(frameID string, m []byte) (bool, error)

DisableReply returns whether or not the FrameID matches the reply value for Disable in the Audits domain.

func (*DisableReply) UnmarshalJSON

func (a *DisableReply) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for Disable in the Audits domain.

type EnableArgs

type EnableArgs struct {
}

EnableArgs represents the arguments for Enable in the Audits domain.

func (*EnableArgs) MarshalJSON

func (a *EnableArgs) MarshalJSON() ([]byte, error)

Marshall the byte array into a return value for Enable in the Audits domain.

func (*EnableArgs) UnmarshalJSON

func (a *EnableArgs) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for Enable in the Audits domain.

type EnableReply

type EnableReply struct {
}

EnableReply represents the return values for Enable in the Audits domain.

func (*EnableReply) GetFrameID

func (a *EnableReply) GetFrameID() string

EnableReply returns the FrameID value for Enable in the Audits domain.

func (*EnableReply) MatchFrameID

func (a *EnableReply) MatchFrameID(frameID string, m []byte) (bool, error)

EnableReply returns whether or not the FrameID matches the reply value for Enable in the Audits domain.

func (*EnableReply) UnmarshalJSON

func (a *EnableReply) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for Enable in the Audits domain.

type GetEncodedResponseArgs

type GetEncodedResponseArgs struct {
	RequestID network.RequestID `json:"requestId"` // Identifier of the network request to get content for.
	// Encoding The encoding to use.
	//
	// Values: "webp", "jpeg", "png".
	Encoding string  `json:"encoding"`
	Quality  float64 `json:"quality,omitempty"`  // The quality of the encoding (0-1). (defaults to 1)
	SizeOnly bool    `json:"sizeOnly,omitempty"` // Whether to only return the size information (defaults to false).
}

GetEncodedResponseArgs represents the arguments for GetEncodedResponse in the Audits domain.

func (*GetEncodedResponseArgs) MarshalJSON

func (a *GetEncodedResponseArgs) MarshalJSON() ([]byte, error)

Marshall the byte array into a return value for GetEncodedResponse in the Audits domain.

func (*GetEncodedResponseArgs) UnmarshalJSON

func (a *GetEncodedResponseArgs) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for GetEncodedResponse in the Audits domain.

type GetEncodedResponseReply

type GetEncodedResponseReply struct {
	Body         string `json:"body,omitempty"` // The encoded body as a base64 string. Omitted if sizeOnly is true.
	OriginalSize int    `json:"originalSize"`   // Size before re-encoding.
	EncodedSize  int    `json:"encodedSize"`    // Size after re-encoding.
}

GetEncodedResponseReply represents the return values for GetEncodedResponse in the Audits domain.

func (*GetEncodedResponseReply) GetFrameID

func (a *GetEncodedResponseReply) GetFrameID() string

GetEncodedResponseReply returns the FrameID value for GetEncodedResponse in the Audits domain.

func (*GetEncodedResponseReply) MatchFrameID

func (a *GetEncodedResponseReply) MatchFrameID(frameID string, m []byte) (bool, error)

GetEncodedResponseReply returns whether or not the FrameID matches the reply value for GetEncodedResponse in the Audits domain.

func (*GetEncodedResponseReply) UnmarshalJSON

func (a *GetEncodedResponseReply) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for GetEncodedResponse in the Audits domain.

type InspectorIssue

type InspectorIssue struct {
	Code    InspectorIssueCode    `json:"code"`    // No description.
	Details InspectorIssueDetails `json:"details"` // No description.
}

InspectorIssue An inspector issue reported from the back-end.

type InspectorIssueCode

type InspectorIssueCode string

InspectorIssueCode A unique identifier for the type of issue. Each type may use one of the optional fields in InspectorIssueDetails to convey more specific information about the kind of issue.

const (
	InspectorIssueCodeNotSet              InspectorIssueCode = ""
	InspectorIssueCodeSameSiteCookieIssue InspectorIssueCode = "SameSiteCookieIssue"
)

InspectorIssueCode as enums.

func (InspectorIssueCode) String

func (e InspectorIssueCode) String() string

func (InspectorIssueCode) Valid

func (e InspectorIssueCode) Valid() bool

type InspectorIssueDetails

type InspectorIssueDetails struct {
	SameSiteCookieIssueDetails *SameSiteCookieIssueDetails `json:"sameSiteCookieIssueDetails,omitempty"` // No description.
}

InspectorIssueDetails This struct holds a list of optional fields with additional information specific to the kind of issue. When adding a new issue code, please also add a new optional field to this type.

type IssueAddedReply

type IssueAddedReply struct {
	Issue InspectorIssue `json:"issue"` // No description.
}

IssueAddedReply is the reply for IssueAdded events.

func (*IssueAddedReply) GetFrameID

func (a *IssueAddedReply) GetFrameID() string

IssueAddedReply returns the FrameID for IssueAdded in the Audits domain.

func (*IssueAddedReply) MatchFrameID

func (a *IssueAddedReply) MatchFrameID(frameID string, m []byte) (bool, error)

IssueAddedReply returns whether or not the FrameID matches the reply value for IssueAdded in the Audits domain.

func (*IssueAddedReply) UnmarshalJSON

func (a *IssueAddedReply) UnmarshalJSON(b []byte) error

Unmarshal the byte array into a return value for IssueAdded in the Audits domain.

type SameSiteCookieExclusionReason

type SameSiteCookieExclusionReason string

SameSiteCookieExclusionReason

const (
	SameSiteCookieExclusionReasonNotSet                                 SameSiteCookieExclusionReason = ""
	SameSiteCookieExclusionReasonExcludeSameSiteUnspecifiedTreatedAsLax SameSiteCookieExclusionReason = "ExcludeSameSiteUnspecifiedTreatedAsLax"
	SameSiteCookieExclusionReasonExcludeSameSiteNoneInsecure            SameSiteCookieExclusionReason = "ExcludeSameSiteNoneInsecure"
)

SameSiteCookieExclusionReason as enums.

func (SameSiteCookieExclusionReason) String

func (SameSiteCookieExclusionReason) Valid

type SameSiteCookieIssueDetails

type SameSiteCookieIssueDetails struct {
	Cookie                 AffectedCookie                  `json:"cookie"`                   // No description.
	CookieWarningReasons   []SameSiteCookieWarningReason   `json:"cookieWarningReasons"`     // No description.
	CookieExclusionReasons []SameSiteCookieExclusionReason `json:"cookieExclusionReasons"`   // No description.
	Operation              SameSiteCookieOperation         `json:"operation"`                // Optionally identifies the site-for-cookies and the cookie url, which may be used by the front-end as additional context.
	SiteForCookies         string                          `json:"siteForCookies,omitempty"` // No description.
	CookieURL              string                          `json:"cookieUrl,omitempty"`      // No description.
	Request                *AffectedRequest                `json:"request,omitempty"`        // No description.
}

SameSiteCookieIssueDetails This information is currently necessary, as the front-end has a difficult time finding a specific cookie. With this, we can convey specific error information without the cookie.

type SameSiteCookieOperation

type SameSiteCookieOperation string

SameSiteCookieOperation

const (
	SameSiteCookieOperationNotSet     SameSiteCookieOperation = ""
	SameSiteCookieOperationSetCookie  SameSiteCookieOperation = "SetCookie"
	SameSiteCookieOperationReadCookie SameSiteCookieOperation = "ReadCookie"
)

SameSiteCookieOperation as enums.

func (SameSiteCookieOperation) String

func (e SameSiteCookieOperation) String() string

func (SameSiteCookieOperation) Valid

func (e SameSiteCookieOperation) Valid() bool

type SameSiteCookieWarningReason

type SameSiteCookieWarningReason string

SameSiteCookieWarningReason

const (
	SameSiteCookieWarningReasonNotSet                                         SameSiteCookieWarningReason = ""
	SameSiteCookieWarningReasonWarnSameSiteUnspecifiedCrossSiteContext        SameSiteCookieWarningReason = "WarnSameSiteUnspecifiedCrossSiteContext"
	SameSiteCookieWarningReasonWarnSameSiteNoneInsecure                       SameSiteCookieWarningReason = "WarnSameSiteNoneInsecure"
	SameSiteCookieWarningReasonWarnSameSiteUnspecifiedLaxAllowUnsafe          SameSiteCookieWarningReason = "WarnSameSiteUnspecifiedLaxAllowUnsafe"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeSecureURLMethodUnsafe   SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeSecureUrlMethodUnsafe"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeSecureURLLax            SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeSecureUrlLax"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeSecureURLStrict         SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeSecureUrlStrict"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeInsecureURLMethodUnsafe SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeInsecureUrlMethodUnsafe"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeInsecureURLLax          SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeInsecureUrlLax"
	SameSiteCookieWarningReasonWarnSameSiteCrossSchemeInsecureURLStrict       SameSiteCookieWarningReason = "WarnSameSiteCrossSchemeInsecureUrlStrict"
)

SameSiteCookieWarningReason as enums.

func (SameSiteCookieWarningReason) String

func (SameSiteCookieWarningReason) Valid

type Unmarshaler

type Unmarshaler func() json.Unmarshaler

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL