All Projects → fuyufjh → splunk-hec-go

fuyufjh / splunk-hec-go

Licence: Apache-2.0 license
Splunk HTTP Event Collector (HEC) Golang library

Programming Languages

go
31211 projects - #10 most used programming language

Labels

Projects that are alternatives of or similar to splunk-hec-go

Kong-API-Manager
Kong API Manager with Prometheus And Graylog
Stars: ✭ 78 (+310.53%)
Mutual labels:  splunk
fanuc-driver
Configurable Fanuc Focas data collector and post processor.
Stars: ✭ 38 (+100%)
Mutual labels:  splunk
splunk modinput prometheus
A Splunk modular input for ingesting Prometheus metrics
Stars: ✭ 40 (+110.53%)
Mutual labels:  splunk
splunk-otel-js-web
Splunk distribution of Open Telemetry for browser environment.
Stars: ✭ 23 (+21.05%)
Mutual labels:  splunk
Sigma
Generic Signature Format for SIEM Systems
Stars: ✭ 4,418 (+23152.63%)
Mutual labels:  splunk
splunk-connect-for-syslog
Splunk Connect for Syslog
Stars: ✭ 111 (+484.21%)
Mutual labels:  splunk
config explorer
Config viewer and file editor for Splunk. Based on VSCode.
Stars: ✭ 20 (+5.26%)
Mutual labels:  splunk
semantic logger
Semantic Logger is a feature rich logging framework, and replacement for existing Ruby & Rails loggers.
Stars: ✭ 730 (+3742.11%)
Mutual labels:  splunk
TA-bigfix
Splunk technical add-on (TA) for ingesting BigFix client, relay, and server logs. Includes REST inputs for ingesting assets, relevant fixlets, action summaries, and analysis results.
Stars: ✭ 15 (-21.05%)
Mutual labels:  splunk
TA-dmarc
Add-on for ingesting DMARC aggregate reports into Splunk
Stars: ✭ 14 (-26.32%)
Mutual labels:  splunk
ansible-splunk-playbook
Install a full Splunk Enterprise Cluster or Universal forwarder using an ansible playbook
Stars: ✭ 34 (+78.95%)
Mutual labels:  splunk
splunk handler
Python logging handler for sending logs to Splunk Enterprise
Stars: ✭ 44 (+131.58%)
Mutual labels:  splunk
TA ETW
Splunk Technology Add-On (TA) for collecting ETW events from Windows systems
Stars: ✭ 17 (-10.53%)
Mutual labels:  splunk
vagrant-ids
An Ubuntu 16.04 build containing Suricata, PulledPork, Bro, and Splunk
Stars: ✭ 21 (+10.53%)
Mutual labels:  splunk
splunk-connect-for-ethereum
Splunk Connect for Ethereum
Stars: ✭ 50 (+163.16%)
Mutual labels:  splunk
kafka-connect-splunk
Kafka Connect connector for receiving data and writing data to Splunk.
Stars: ✭ 25 (+31.58%)
Mutual labels:  splunk
TA-Sysmon-deploy
Deploy and maintain Symon through the Splunk Deployment Sever
Stars: ✭ 31 (+63.16%)
Mutual labels:  splunk
vault-plugin-splunk
Vault plugin to securely manage Splunk admin accounts and password rotation
Stars: ✭ 23 (+21.05%)
Mutual labels:  splunk
SplunkScriplets
Various Splunk Scripts and applets, all in one place
Stars: ✭ 24 (+26.32%)
Mutual labels:  splunk
evtx2json
A tool to convert Windows evtx files (Windows Event Log Files) into JSON format and log to Splunk (optional) using HTTP Event Collector.
Stars: ✭ 38 (+100%)
Mutual labels:  splunk

Splunk HEC Golang Library

Build Status

Golang library for Splunk HTTP Event Collector (HEC).

Build

You need install glide before build.

Install all dependencies

glide install

Build the example

go build -o build/example ./example/main.go

Features

  • Support HEC JSON mode and Raw mode
  • Send batch of events
  • Customize retrying times
  • Cut big batch into chunk less than MaxContentLength
  • Indexer acknowledgement
  • Streaming data via HEC Raw

Example

client := hec.NewCluster(
	[]string{"https://127.0.0.1:8088", "https://localhost:8088"},
	"00000000-0000-0000-0000-000000000000",
)
client.SetHTTPClient(&http.Client{Transport: &http.Transport{
	TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
}})

event1 := hec.NewEvent("event one")
event1.SetTime(time.Now())
event2 := hec.NewEvent("event two")
event2.SetTime(time.Now().Add(-time.Minute))

err := client.WriteBatch([]*hec.Event{event1, event2})
if err != nil {
	log.Fatal(err)
}

See hec.go for more usages.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].