Skip to content

Instantly share code, notes, and snippets.

This file has been truncated, but you can view the full file.
1 46.139.54.184 [Tue Feb 22 23:25:11 UTC 2017] GET /_js/master.js HTTP/1.1 200 6943 http://www.google.com/url?sa=t&rct=j&q=log%20management&source=web&cd=4 Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/28.0.1467.0 Safari/537.36
2 221.125.19.252 [Tue Feb 22 16:54:49 UTC 2017] GET /_downloads/Datasheet.pdf HTTP/1.1 200 6979 http://www.google.com/url?sa=t&rct=j&q=log%20management&source=web&cd=4 Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.1.0.346 Mobile Safari/534.11+
3 19.174.45.8 [Tue Feb 22 19:22:46 UTC 2017] GET /_media/bio_nir.jpg HTTP/1.1 404 6901 http://www.linkedin.com SAMSUNG-C5212/C5212XDIK1 NetFront/3.4 Profile/MIDP-2.0 Configuration/CLDC-1.1
4 65.98.119.36 [Tue Feb 22 18:46:20 UTC 2017] GET /_media/play_button_gray.png HTTP/1.1 200 7004 http://www.accel.com Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.1.0.346 Mobile Safari/534.11+
5 78.235.33.64 [Tue Feb 22 20:04:0
@joschi
joschi / graylog_token.txt
Last active September 28, 2023 04:27
Graylog access token login
# Create an access token for user "admin" with name "test-1234"
# POST /users/{username}/tokens/{name}
$ curl -i -u admin:admin -H 'Accept: application/json' -X POST 'http://127.0.0.1:12900/users/admin/tokens/test-1234?pretty=true'
HTTP/1.1 200 OK
X-Graylog-Node-ID: cd03ee44-b2a7-4824-be16-bb7456149dbd
Content-Type: application/json
Date: Mon, 08 Aug 2016 12:12:09 GMT
Content-Length: 139
{
@joschi
joschi / log4j2.xml
Last active June 29, 2016 15:10
Graylog REST API Access Logs
<?xml version="1.0" encoding="UTF-8"?>
<Configuration packages="org.graylog2.log4j" shutdownHook="disable">
<Appenders>
<RollingFile name="AccessLogs" fileName="/tmp/logs/access.log"
filePattern="/tmp/logs/access-%d{yyyy-MM-dd}.log.gz">
<PatternLayout>
<Pattern>%d %-5p: %c - %m%n</Pattern>
</PatternLayout>
<Policies>
<TimeBasedTriggeringPolicy modulate="true"/>
@joschi
joschi / graylog_session.txt
Last active April 25, 2016 09:11
Graylog session login
# HTTP POST to /system/sessions with username and password to acquire a valid session ID
$ curl -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' 'http://127.0.0.1:12900/system/sessions' -d '{"username":"USER", "password":"SECRET", "host":""}'
X-Graylog-Node-ID: cd03ee44-b2a7-4824-be16-bb7456149dbd
Content-Type: application/json
Date: Tue, 23 Feb 2016 10:27:09 GMT
Content-Length: 98
{"valid_until":"2016-02-23T18:27:09.726+0000","session_id":"fdf31c3c-037b-4ff3-ba32-893e06e17c4a"}
# Use the acquired session in a Graylog REST API request (Basic Auth credentials: username==$SESSION_ID, password=="session")
@joschi
joschi / Issue832.java
Created January 17, 2015 14:58
Dropwizard #832
package io.dropwizard.client;
import io.dropwizard.Application;
import io.dropwizard.Configuration;
import io.dropwizard.setup.Environment;
import io.dropwizard.testing.junit.DropwizardAppRule;
import org.junit.Rule;
import org.junit.Test;
import javax.ws.rs.client.Client;
@joschi
joschi / dw-addons.md
Last active August 29, 2015 14:03
Dropwizard 3rd Party Addons

Please refer to the official Dropwizard Module Directory for an up-to-date list.

Dropwizard 0.7.x

Name Description License Maven Central
dropwizard-guice Support for Google Guice Apache 2.0 http://mvnrepository.com/artifact/com.hubspot.dropwizard/dropwizard-guice
dropwizard-spring Spring integration for Dropwizard Apache 2.0 http://mvnrepository.com/artifact/com.hmsonline/dropwizard-spring
dropwizard-redirect-bundle A simple bundle for Dropwizard that allows for HTTP redirects http://mvnrepository.com/artifact/com.bazaarvoice.dropwizard/dropwizard-redirect-bundle
@joschi
joschi / keybase.md
Last active June 14, 2016 11:39
keybase.md

Keybase proof

I hereby claim:

  • I am joschi on github.
  • I am joschi (https://keybase.io/joschi) on keybase.
  • I have a public key ASDmakZsOA6w7oJbbL7nkTQ3rPBpWtG89l-IDCfdjkKI4wo

To claim this, I am signing this object:

@joschi
joschi / onejar-0.97-to-0.97.1.diff
Created February 20, 2013 10:22
Source diff between OneJAR 0.97 and 0.97.1.
diff -ru 0.97/src/com/simontuffs/onejar/Boot.java 0.97.1/src/com/simontuffs/onejar/Boot.java
--- 0.97/src/com/simontuffs/onejar/Boot.java 2011-05-04 12:57:38.000000000 +0200
+++ 0.97.1/src/com/simontuffs/onejar/Boot.java 2012-08-14 21:46:30.000000000 +0200
@@ -12,6 +12,7 @@
import java.io.BufferedReader;
import java.io.File;
import java.io.FileInputStream;
+import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
@joschi
joschi / PKGBUILD
Created November 29, 2012 18:37
ruby-multi_json 1.3.7-1
# Maintainer: Alexsandr Pavlov <kidoz at mail dot ru>
pkgname=ruby-multi_json
_gemname=${pkgname#ruby-}
pkgver=1.3.7
pkgrel=1
pkgdesc="A generic swappable back-end for JSON handling."
arch=('any')
url="http://github.com/intridea/multi_json"
license=('MIT')
depends=('ruby' 'rubygems')