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
function dump(o) { | |
var r = "["; | |
for (var p in o) { | |
r += p + " = " + o[p] + ", "; | |
} | |
r += "]"; | |
alert(r); | |
} |
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
/** | |
* | |
* Why we shouldn't try to use just assymetric algorithm http://stackoverflow.com/questions/118463/what-is-the-performance-difference-of-pki-to-symmetric-encryption | |
* | |
* | |
* Bouncy Castle TlsProtocolHandler doesn't support session reuse. Check with: | |
* | |
* http://royontechnology.blogspot.com/2008/01/how-to-find-out-if-server-supports-ssl.html | |
* | |
**/ |
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
P=`sudo lsof | grep '(deleted)' | awk '{ print $2 }'` | |
for x in $P; do | |
cat /proc/$x/cmdline; | |
echo ""; | |
done; | |
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
import static org.junit.Assert.assertFalse; | |
import java.io.ByteArrayOutputStream; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileOutputStream; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.OutputStream; | |
import java.net.ServerSocket; |
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
#!/bin/bash | |
# something in PATH env to lookup name in | |
LINK_PATH=/usr/bin | |
# where jdk is install to? | |
JDK_INSTALL_PATH=/opt/jdk1.7.0_21/bin | |
# alternative prefix | |
ALTER_PREFIX=oracle |
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
# -*- coding: utf-8 -*- | |
from xml.etree import ElementTree as ET | |
import itertools | |
import StringIO | |
import traceback | |
XML=r"""<?xml version='1.0' encoding='%s'?><response><msg>АБВГДЕЖЗСКЛМНОПРСТУФХЦЧШЩЫЪЭЬЮЯ</msg></response>""" | |
# XXX: for some unknown reason Ё isn't supported | |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.