_id
stringlengths
2
7
text
stringlengths
6
2.61k
title
stringclasses
1 value
c15800
// notify a non-recoverable error that terminates the scanning.
c15801
// convert the reader to a rune reader if required.
c15802
// clone and return parser current state.
c15803
// init is a Visitor, which is used with the Walk function // The purpose of this function is to initialize the reference // maps rules, ruleUsesRules and ruleUsedByRules.
c15804
// Add element to map of maps, initialize the inner map // if necessary.
c15805
// Parse parses the data from the reader r and generates the AST // or returns an error if it fails. The filename is used as information // in the error messages.
c15806
// NewLogger returns a new zap logger that implements the Logger interface.
c15807
// NewHealthcheck creates a handler that responds to healthcheck requests. // If userAgent is set to a non-empty string, it will use that user agent to // differentiate between healthcheck requests and non-healthcheck requests. // Otherwise, it will treat all requests as healthcheck requests.
c15808
// NewAccessLog creates a new handler that handles logging requests to the // access log
c15809
// NewRouteService creates a handler responsible for handling route services
c15810
// NewZipkin creates a new handler that sets Zipkin headers on requests
c15811
// BuildB3SingleHeader assembles the B3 single header based on existing trace // values
c15812
// HeadersToLog returns headers that should be logged in the access logs and // includes Zipkin headers in this set if necessary
c15813
// WriteIntValue writes an int to the buffer
c15814
// WriteDashOrStringValue writes an int or a "-" to the buffer if the int is // equal to 0
c15815
// WriteDashOrStringValue writes a float or a "-" to the buffer if the float is // 0 or lower
c15816
// WriteStringValues always writes quoted strings to the buffer
c15817
// WriteDashOrStringValue writes quoted strings or a "-" if the string is empty
c15818
// WriteTo allows the AccessLogRecord to implement the io.WriterTo interface
c15819
// ApplicationID returns the application ID that corresponds with the access log
c15820
// ForwardIO sets up websocket forwarding with a backend // // It returns after one of the connections closes. // // If the backend response code is not 101 Switching Protocols, then // ForwardIO will return immediately, allowing the caller to close the connections.
c15821
// NewLookup creates a handler responsible for looking up a route.
c15822
// Trim time slots up to and including time t.
c15823
// Session returns a new logger with a nested session.
c15824
// Debug logs a message at the debug log level.
c15825
// Error logs a message at the error log level.
c15826
// WithData returns a logger with newly added data.
c15827
// NewReporter creates a new handler that handles reporting backend // responses to metrics
c15828
// ServeHTTP handles reporting the response after the request has been completed
c15829
// connLock must be locked
c15830
// Classify returns true on errors that are retryable
c15831
// ServeHTTP wraps the responseWriter in a ProxyResponseWriter
c15832
// Returns true if endpoint was added or updated, false otherwise
c15833
// Returns true if the endpoint was removed from the Pool, false otherwise.
c15834
// ValidateMessage checks to ensure the registry message is valid
c15835
// Prefer TLS Port instead of HTTP Port in Registrty Message
c15836
// NewSubscriber returns a new Subscriber
c15837
// Run manages the lifecycle of the subscriber process
c15838
// Snip removes an empty Pool from a node and trims empty leaf nodes from the Trie
c15839
// NewPanicCheck creates a handler responsible for checking for panics and setting the Healthcheck to fail.
c15840
// NewHTTPStartStop creates a new handler that handles emitting frontent // HTTP StartStop events
c15841
// ServeHTTP handles emitting a StartStop event after the request has been completed
c15842
// GetLocalIP queries the host interface to determine the local IP address of this // machine. If a local IP address cannot be found, then nil is returned. Local IPv6 // address takes presedence over a local IPv4 address. If the query to the underlying // OS fails, an error is returned.
c15843
// HealthyNodes will return a list of all nodes known at the time of the // request with a healthy status.
c15844
// RemoveNode can be used to explicitly remove a node from the list of known // live nodes. Updates the node timestamp but DOES NOT implicitly update the // node's status; you need to do this explicitly.
c15845
// GetListenIP returns the IP that this host will listen on.
c15846
// GetMulticastEnabled returns whether multicast announcements are enabled.
c15847
// Gets an environmental variable "key". If it does not exist, "defaultVal" is // returned; if it does, it attempts to convert to an integer, returning // "defaultVal" if it fails.
c15848
// Gets an environmental variable "key". If it does not exist, "defaultVal" is // returned; if it does, it attempts to convert to a string slice, returning // "defaultVal" if it fails.
c15849
// Gets an environmental variable "key". If it does not exist, "defaultVal" is // returned; if it does, it attempts to convert to a string, returning // "defaultVal" if it fails.
c15850
// Splits a string on a regular expression.
c15851
// getListenInterface gets the network interface for the listen IP
c15852
// multicastAnnounce is called when the server first starts to broadcast its // presence to all listening servers within the specified subnet and continues // to broadcast its presence every multicastAnnounceIntervalSeconds in case // this value is larger than zero.
c15853
// Log writes a log message of a certain level to the logger
c15854
// Logf writes a log message with a specific format to the logger
c15855
// Address rReturns the address for this node in string format, which is simply // the node's local IP and listen port. This is used as a unique identifier // throughout the code base.
c15856
// Convenience function. Creates a new message instance.
c15857
// If members exist on this message, and that message has the "forward to" // status, this function returns it; otherwise it returns nil.
c15858
// Returns the mean modified by the requested number of sigmas
c15859
// Returns both mean and standard deviation
c15860
// Returns a pointer to the requested Node
c15861
// Bytes returns a copy of this broadcast's bytes. Manipulating the contents // of this slice will not be reflected in the contents of the broadcast.
c15862
// BroadcastBytes allows a user to emit a short broadcast in the form of a byte // slice, which will be transmitted at most once to all other healthy current // members. Members that join after the broadcast has already propagated // through the cluster will not receive the message. The maximum broadcast // length is 2...
c15863
// receiveBroadcast is called by receiveMessageUDP when a broadcast payload // is found in a message.
c15864
// checkBroadcastOrigin checks wether the origin is set correctly
c15865
// SetConfiguration sets a global YARA configuration option.
c15866
// GetConfiguration gets a global YARA configuration option.
c15867
// destroy frees stored C pointers
c15868
// RuleMatching implements the ScanCallbackMatch interface for // MatchRules.
c15869
// writeFull does its best to write all of buf to w. See io.ReadFull.
c15870
// NewCompiler creates a YARA compiler.
c15871
// Destroy destroys the YARA data structure representing a compiler. // Since a Finalizer for the underlying YR_COMPILER structure is // automatically set up on creation, it should not be necessary to // explicitly call this method.
c15872
// AddString compiles rules from a string. Rules are added to the // specified namespace. // // If this function returns an error, the Compiler object will become // unusable.
c15873
// GetRules returns the compiled ruleset.
c15874
// MustCompile is like Compile but panics if the rules and optional // variables can't be compiled. Like regexp.MustCompile, it allows for // simple, safe initialization of global or test data.
c15875
// DisableIncludes disables all include statements in the compiler. // See yr_compiler_set_include_callbacks.
c15876
// ScanMem scans an in-memory buffer using the ruleset, returning // matches via a list of MatchRule objects.
c15877
// ScanMemWithCallback scans an in-memory buffer using the ruleset. // For every event emitted by libyara, the appropriate method on the // ScanCallback object is called.
c15878
// ScanFile scans a file using the ruleset, returning matches via a // list of MatchRule objects.
c15879
// ScanFileWithCallback scans a file using the ruleset. For every // event emitted by libyara, the appropriate method on the // ScanCallback object is called.
c15880
// ScanProc scans a live process using the ruleset, returning matches // via a list of MatchRule objects.
c15881
// ScanProcWithCallback scans a live process using the ruleset. For // every event emitted by libyara, the appropriate method on the // ScanCallback object is called.
c15882
// Save writes a compiled ruleset to filename.
c15883
// LoadRules retrieves a compiled ruleset from filename.
c15884
// Destroy destroys the YARA data structure representing a ruleset. // Since a Finalizer for the underlying YR_RULES structure is // automatically set up on creation, it should not be necessary to // explicitly call this method.
c15885
// GetRules returns a slice of rule objects that are part of the // ruleset
c15886
// AddFile compiles rules from a file. Rules are added to the // specified namespace. // // If this function returns an error, the Compiler object will become // unusable.
c15887
// MakePool creates a Pool that can hold n elements.
c15888
// Put adds an element to the cbPool, returning a stable pointer // suitable for passing through CGO. It panics if the pool is full.
c15889
// Put accesses an element stored in the cbPool, using a pointer // previously returned by Put. It panics if the pointer is invalid or // if it references an empty slot.
c15890
// Delete removes an element from the cbPool, using a pointer previously // returned by Put. It panics if the pointer is invalid or if it // references an empty slot.
c15891
// ScanFileDescriptor scans a file using the ruleset, returning // matches via a list of MatchRule objects.
c15892
// ScanFileDescriptorWithCallback scans a file using the ruleset. For every event // emitted by libyara, the appropriate method on the ScanCallback // object is called.
c15893
// Write writes a compiled ruleset to an io.Writer.
c15894
// ReadRules retrieves a compiled ruleset from an io.Reader
c15895
// Identifier returns the rule's name.
c15896
// Namespace returns the rule's namespace.
c15897
// Tags returns the rule's tags.
c15898
// Metas returns a map containing the rule's meta variables. Values // can be of type string, int, bool, or nil. // // If a rule contains multiple meta variables with the same name, only // the last meta variable is returned as part of the map.
c15899
// Strings returns the rule's strings