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
From c7c0b49be9e272aa6421ed26f7b03d3c465d2313 Mon Sep 17 00:00:00 2001 | |
From: Rasmus Andersson <[email protected]> | |
Date: Tue, 2 Mar 2010 03:13:41 +0100 | |
Subject: [PATCH] Added fs.mkdirs and fs.mkdirsSync for recursively creating directories as needed | |
--- | |
doc/api.txt | 10 +++++ | |
lib/fs.js | 82 +++++++++++++++++++++++++++++++++++++++++ | |
test/simple/test-fs-mkdirs.js | 47 +++++++++++++++++++++++ | |
3 files changed, 139 insertions(+), 0 deletions(-) |
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
/*! | |
* Dynamically changing favicons with JavaScript | |
* Works in all A-grade browsers except Safari and Internet Explorer | |
* Demo: http://mathiasbynens.be/demo/dynamic-favicons | |
*/ | |
// HTML5™, baby! http://mathiasbynens.be/notes/document-head | |
document.head || (document.head = document.getElementsByTagName('head')[0]); | |
function changeFavicon(src) { |
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
diff --git a/src/share/classes/sun/security/ec/NamedCurve.java b/src/share/classes/sun/security/ec/NamedCurve.java | |
--- a/src/share/classes/sun/security/ec/NamedCurve.java | |
+++ b/src/share/classes/sun/security/ec/NamedCurve.java | |
@@ -658,6 +658,133 @@ | |
0xFF70); | |
*/ | |
+ /* Brainpool curves (RFC 5639) */ | |
+ add("brainpoolP160r1", "1.3.36.3.3.2.8.1.1.1", P, | |
+ "E95E4A5F737059DC60DFC7AD95B3D8139515620F", |
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
$ ssh-keygen -l -f id_rsa.pub | |
2048 aa:bb:cc:dd:ee:ff:00:11:22:33:44:55:66:77:88:99 id_rsa.pub (RSA) |
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 java.lang.reflect.Type; | |
import android.util.Base64; | |
import com.google.gson.Gson; | |
import com.google.gson.GsonBuilder; | |
import com.google.gson.JsonDeserializationContext; | |
import com.google.gson.JsonDeserializer; | |
import com.google.gson.JsonElement; | |
import com.google.gson.JsonParseException; |
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
# to generate your dhparam.pem file, run in the terminal | |
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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 javax.crypto.Cipher; | |
class Test { | |
public static void main(String[] args) { | |
try { | |
System.out.println("Hello World!"); | |
int maxKeyLen = Cipher.getMaxAllowedKeyLength("AES"); | |
System.out.println(maxKeyLen); | |
} catch (Exception e){ | |
System.out.println("Sad world :("); |
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 java.util.Iterator; | |
import java.util.Map; | |
import java.util.TreeMap; | |
import javax.net.ssl.SSLServerSocketFactory; | |
/* | |
* Source from Christopher Schultz | |
* @see http://markmail.org/message/zn4namfhypyxum23 | |
*/ | |
public class SSLInfo |
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 java.io.RandomAccessFile; | |
import java.lang.reflect.Field; | |
import java.lang.reflect.Method; | |
import java.nio.channels.FileChannel; | |
import sun.nio.ch.FileChannelImpl; | |
import sun.misc.Unsafe; | |
@SuppressWarnings("restriction") | |
public class MMapper { |
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
// I'm forever forgetting to adjust the time zone on my camera when taking pictures on vacation | |
// this uses the linux exiftool to adjust the timezone -8 hours for all images in a directory | |
exiftool "-DateTimeOriginal-=0:0:0 8:0:0" * |
OlderNewer