- Ubuntu 12.04
- OpenStack havana release
- python-swiftclient Swifit CLI
- cURL
- Swift tools such as Swift-Recon, Swift-Informant, and Swift-Dispersion
- A StatsD server. https://github.com/etsy/statsd
This file contains hidden or 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 <algorithm> | |
| #include <iostream> | |
| #include <map> | |
| using namespace std; | |
| /** | |
| * @brief repeat helper. | |
| */ | |
| template <typename F> |
This file contains hidden or 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
| string colors("BGR"), comb(4, '.'), l(comb), guess; | |
| typedef map<int,int> M; | |
| struct Color { | |
| Color( M& cm, M& gm, int& color ) | |
| : cm_(cm), gm_(gm), color_(color=0) { } | |
| void operator()( char c ) | |
| { color_ += min( cm_[c], gm_[c] ); } | |
| M &cm_, &gm_; |
This file contains hidden or 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
| from smartcard.System import readers | |
| from smartcard.CardType import AnyCardType | |
| from smartcard.CardRequest import CardRequest | |
| from smartcard.CardConnection import CardConnection | |
| from smartcard.util import toHexString, toBytes | |
| from smartcard.CardMonitoring import CardMonitor, CardObserver | |
| from smartcard.util import * | |
| from time import sleep | |
| def check_reader(): |
This file contains hidden or 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
| // ==UserScript== | |
| // @name ganster | |
| // @namespace [email protected] | |
| // @include http://www.sexgangsters.com/* | |
| // @version 1 | |
| // @grant none | |
| // ==/UserScript== | |
| var api_call = function(api_method, api_args, api_callback) { | |
| return function() { |
This file contains hidden or 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
| import os, sys | |
| import hashlib | |
| def file_digest(f): | |
| m = hashlib.md5() | |
| m.update(file(f).read()) | |
| return m.hexdigest() | |
| def remove_duplicates(dir): | |
| # size, list of files. |
This file contains hidden or 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/python3 | |
| import sys | |
| def MyCount(string): | |
| tmpStr = "" | |
| for c in string: | |
| if ord(c)>=255 and (c not in ",。!¥()《》【】『』、?~·:“”‘’;"): tmpStr += c | |
| return len(tmpStr) | |
| if __name__=="__main__": |
This file contains hidden or 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
| # This script is used to export changes between two commits | |
| # into two folders for people don't have hg to review code. | |
| # | |
| # Usage: | |
| # python hgfolderdiff.py rev1 rev2 diffs.zip | |
| # | |
| # export change files in two revisions into two directories, | |
| # and then archive to zip file. | |
| # | |
| import os, subprocess, sys |
This file contains hidden or 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/python | |
| # powerpc-gekko-objdump -d example.elf | python cg.py | dot -Tpng > cg.png && eog cg.png | |
| import re, sys | |
| f_re = re.compile('^[0-9a-f]* <([a-zA-Z0-9_]*)>:$') | |
| c_re = re.compile('\tbl *[0-9a-f]* <([a-zA-Z0-9_]*)>') | |
| _blacklist = set(['sys_init', 'SYS_ResetSystem', 'puts', 'getButtons', |
This file contains hidden or 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
| # Simple python script to check each steps of RSA calculation. | |
| # Keys. | |
| n = 0xAA9DE43925350CD9C0F1F98017FFD882BCFE524122212E764C6D529989B4192169B30559BDFA0F6F3037C3FDF54E18D2A36028E1940BEF14A472D50814A1089861B541491E2CA61652012FBC9E381CD744860F22EB4DD4274AF5C87EF5D05BD5040D8BA550A0FA59C1AFF7B354DF565B531B4ECF4DE731F5998F651BE25146E7 | |
| ns = 'AA9DE43925350CD9C0F1F98017FFD882BCFE524122212E764C6D529989B4192169B30559BDFA0F6F3037C3FDF54E18D2A36028E1940BEF14A472D50814A1089861B541491E2CA61652012FBC9E381CD744860F22EB4DD4274AF5C87EF5D05BD5040D8BA550A0FA59C1AFF7B354DF565B531B4ECF4DE731F5998F651BE25146E7' | |
| e = 0xEDBE77C1 | |
| p = 0xE091BB42189DEA18CF8EE01A2407A6F0DF154C026948CBBE2857584885D60C08E1CD91FB47C35D07E337FF162201BEF10E6D9CBAE975AA086A0E6C6ABD85DE65 | |
| q = 0xC27F0DB3D6B798AD36340B56A402467476433A9034953DE611062ECEE87E2A2A46EEFA4900DE013B13191CD0FC84ABFB4CAE01AD22E6F19D4C97AB76CA02455B |