Keybase proof
I hereby claim:
- I am lkraider on github.
- I am lkraider (https://keybase.io/lkraider) on keybase.
- I have a public key ASCtuhrH3CmFPAr8qYr8m8Q0gFEV8h9kXkKNBplfdp_LrAo
To claim this, I am signing this object:
# parsed report from: https://gist.github.com/lkraider/729223f16025c1ff6223536896465e36 | |
# using online tool: http://eleccelerator.com/usbdescreqparser/ | |
0x05, 0x86, // Usage Page (Power Pages) | |
0x09, 0x04, // Usage (0x04) | |
0xA1, 0x01, // Collection (Application) | |
0x05, 0x84, // Usage Page (Power Pages) | |
0x09, 0x1E, // Usage (0x1E) | |
0xA1, 0x00, // Collection (Physical) | |
0x85, 0x01, // Report ID (1) | |
0x09, 0x1F, // Usage (0x1F) |
def decode(msg): | |
text = [] | |
for i in range(0, len(msg), 2): | |
text.append(unrot(msg[i: i + 2])) | |
return str.join('', text) | |
def unrot(pair, key=ord('x')): | |
offset = 0 | |
for c in 'cdefgh': |
~# /lib/nut/nutdrv_qx -a nsys1 -DDDDD -x vendorid=0001 | |
Network UPS Tools - Generic Q* USB/Serial driver 0.28 (2.7.4) | |
USB communication driver 0.33 | |
0.000000 send_to_all: SETINFO driver.parameter.vendorid "0001" | |
0.000033 debug level is '5' | |
0.000975 upsdrv_initups... | |
0.014797 Checking device (1D6B/0003) (002/001) | |
0.030369 - VendorID: 1d6b | |
0.030398 - ProductID: 0003 | |
0.030408 - Manufacturer: unknown |
~# /lib/nut/blazer_usb -a nsys1 -DDDDD -x vendorid=0001 | |
Network UPS Tools - Megatec/Q1 protocol USB driver 0.12 (2.7.4) | |
0.000000 send_to_all: SETINFO driver.parameter.vendorid "0001" | |
0.000038 debug level is '5' | |
0.021080 Checking device (1D6B/0003) (002/001) | |
0.036745 - VendorID: 1d6b | |
0.036778 - ProductID: 0003 | |
0.036819 - Manufacturer: unknown | |
0.036842 - Product: unknown | |
0.036856 - Serial Number: unknown |
~# /lib/nut/usbhid-ups -a nsys1 -DDDDD -x vendorid=0001 -x explore | |
Network UPS Tools - Generic HID driver 0.41 (2.7.4) | |
USB communication driver 0.33 | |
0.000000 send_to_all: SETINFO driver.parameter.vendorid "0001" | |
0.000042 send_to_all: SETINFO driver.flag.explore "enabled" | |
0.000061 debug level is '5' | |
0.001022 upsdrv_initups... | |
0.017350 Checking device (1D6B/0003) (002/001) | |
0.037392 - VendorID: 1d6b | |
0.037425 - ProductID: 0003 |
I hereby claim:
To claim this, I am signing this object:
from PIL import Image | |
from io import BytesIO | |
import itertools | |
def as_pbm(w, h, data): # -> bytes | |
ret = bytes() | |
ret += b'P4\n' | |
ret += (str(w) + ' ' + str(h) + '\n').encode('ascii') |
{
"shell_cmd": "/usr/bin/env python3 -u \"${file}\" 2> >(tr '\\n' '|')",
"selector": "source.python",
"file_regex": "[ ]*File \"(...*?)\", line ([0-9]*)(...*?)\\|...*?\\|(.*)\\|",
"working_dir": "${file_path}"
}
#!/usr/bin/env python2 | |
# -*- coding: utf-8 -*- | |
# https://www.urionlinejudge.com.br/judge/pt/problems/view/1478 | |
from sys import stdout | |
w = stdout.write | |
m = ''.join('%03s ' % l for l in range(100, 0, -1) + range(2, 101)) | |
n = input('') | |
while n > 0: | |
nn = n * 4 | |
for ss in xrange(396, 396 - nn, -4): |
resource "aws_iam_policy" "terraform_create_policy" { | |
name = "terraform_create_policy" | |
path = "/" | |
policy = "${data.aws_iam_policy_document.terraform_create_policy.json}" | |
} | |
data "aws_iam_policy_document" "terraform_create_policy" { | |
statement { | |
sid = "1" | |
actions = [ |