This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<style> | |
body { | |
} | |
#canvas { | |
width: 100%; | |
height: 100%; | |
margin: 0px; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%module EnumClassGenerationIssue | |
%include <std_vector.i> | |
%inline { | |
enum class TestEnum {}; | |
} | |
%template(TestEnumVector) std::vector<TestEnum>; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 2.8) | |
project(sdnotify) | |
add_executable(sdnotify sdnotify.cpp) | |
target_link_libraries(sdnotify PUBLIC systemd) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
rows and column numbers start at the bottom left | |
P0.2: USB pin D+ | |
P0.3: USB pin D- | |
P0.4: USB pin D+ pulldown (used during reset) | |
P2.0: USB pin D- pullup (used during reset) | |
P0.5: switch row 6 drive | |
P0.6: switch row 5 drive | |
P0.7: switch row 4 drive |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
extern char *fw_data; | |
extern int fw_len; | |
// used to hold the RunOnlyOneUpdateTools mutex | |
extern HANDLE dword_458908; | |
// used to hold the first byte pair after the firmware header | |
extern int dword_45868c; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from hashlib import sha1 | |
from getpass import getpass | |
from requests import get | |
def is_pwd_pwned(pwd): | |
""" Returns tuple of (pwned:boolean, occurances) for given password""" | |
h = sha1(pwd.encode('utf-8')).hexdigest().upper().encode('ascii') | |
prefix_h = h[:5] | |
suffix_h = h[5:] |
OlderNewer