Skip to content

Instantly share code, notes, and snippets.

View hellok's full-sized avatar

Chen Qin hellok

View GitHub Profile
@hellok
hellok / Linux ASLR comparison.md
Created June 1, 2017 03:39 — forked from thestinger/Linux ASLR comparison.md
Comparing ASLR between mainline Linux, grsecurity and linux-hardened

These results are with glibc malloc on x86_64. The last public PaX and grsecurity patches don't support arm64 which is one of the two architectures (x86_64 kernels including x32/x86_32 and arm64 kernels including armv7 userspace) focused on by linux-hardened. There isn't anything other than x86_64 to compare across all 3 kernels although linux-hardened has the same end result for both x86_64 and arm64 (with slightly different starting points) and there are few mainline differences. The linux-hardened implementation of ASLR is a very minimal modification of the mainline implementation to fix the weaknesses compared to grsecurity. The intention is to upstream all of these changes, although care needs to be taken to properly justify them to avoid getting anything rejected unnecessarily.

Explanation of differences between kernels:

  • Mainline and linux-hardened base randomization entropy for the mmap base and executable to the vm.mmap_rnd_bits sysctl for 64-bit and
--- a/drivers/video/logo/logo_linux_clut224.ppm 2014-06-09 02:19:54.000000000 +0800
+++ b/drivers/video/logo/logo_linux_clut224.ppm 2014-08-21 20:07:31.729230596 +0800
@@ -1,5 +1,5 @@
P3
-# Standard 224-color Linux logo
+# 224-color Minami Kotori bootup logo for Linux
80 80
255
0 0 0 0 0 0 0 0 0 0 0 0
@@ -11,8 +11,6 @@
@hellok
hellok / endian.h
Created April 21, 2014 17:46 — forked from yinyin/endian.h
#ifndef __FINK_ENDIANDEV_PKG_ENDIAN_H__
#define __FINK_ENDIANDEV_PKG_ENDIAN_H__ 1
/** compatibility header for endian.h
* This is a simple compatibility shim to convert
* BSD/Linux endian macros to the Mac OS X equivalents.
* It is public domain.
* */
#ifndef __APPLE__
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",
# configuration for osx clipboard support
set-option -g default-command "reattach-to-user-namespace -l sh"

Gitlab 5.4 - Gmail configuration

In order to send messages through a Gmail account (also applicable to Google Apps accounts) add the following parts to your config files:

Files:

  • config/environments/production.rb
  • config/gitlab.yml
public class Cipher {
public static void main(String[] args) throws Throwable
{
BASE64Decoder decoder = new BASE64Decoder();
BASE64Encoder encoder = new BASE64Encoder();
String message = "s_hostname:jonasnuts.blogs.sapo.pt OR s_hostname:jonasnuts.com;1350305502";
// data