Skip to content

Instantly share code, notes, and snippets.

View nanangarsyad's full-sized avatar

Nanang arsyad alfatich nanangarsyad

View GitHub Profile
@nanangarsyad
nanangarsyad / myweechat.md
Created January 18, 2021 13:46 — forked from pascalpoitras/1.md
My always up-to-date WeeChat configuration (weechat-dev)

WeeChat Screenshot

You need at least WeeChat 3.1-dev

Enable mouse

/mouse enable

@nanangarsyad
nanangarsyad / build.gradle
Created January 17, 2021 05:20 — forked from melastmohican/build.gradle
Gradle: build binary patch jar with selected classes only
apply plugin: 'java'
sourceCompatibility = 1.7
targetCompatibility = 1.7
repositories {
jcenter()
mavenCentral()
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
}
|=-----------------------------------------------------------------------=|
|=-------------=[ 3 Years of Attacking JavaScript Engines ]=-------------=|
|=-----------------------------------------------------------------------=|
|=------------------------------=[ saelo ]=------------------------------=|
|=-----------------------------------------------------------------------=|
The following are some brief notes about the changes that have taken place
since the release of the "Attacking JavaScript Engines" paper [1]. In
general, no big conceptional changes have happened since. Mitigations have
been added to break some of the presented techniques and, as expected, a
@nanangarsyad
nanangarsyad / commands.sh
Created July 20, 2018 03:18 — forked from williballenthin/commands.sh
Install IDA Pro under Wine in Docker
# build wine Docker image
pushd wine; docker build -t wine .; popd
# build x11 Docker image for IDA
pushd ida; docker build -t wine/ida .; popd
# demonstrate x11 forwarding works
docker run -ti --rm -e DISPLAY=$DISPLAY -v /tmp/.X11-unix:/tmp/.X11-unix wine/ida xclock
# interactive shell in container
@nanangarsyad
nanangarsyad / showForegroundNotification.java
Created July 6, 2018 19:32 — forked from kristopherjohnson/showForegroundNotification.java
Shows a foreground notification for an Android service. Tapping the notification will display the app as if it was tapped in application launcher
private static final int NOTIFICATION_ID = 1;
private void showForegroundNotification(String contentText) {
// Create intent that will bring our app to the front, as if it was tapped in the app
// launcher
Intent showTaskIntent = new Intent(getApplicationContext(), MyMainActivity.class);
showTaskIntent.setAction(Intent.ACTION_MAIN);
showTaskIntent.addCategory(Intent.CATEGORY_LAUNCHER);
showTaskIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
@nanangarsyad
nanangarsyad / OkHttp3Stack.java
Created June 5, 2018 08:51 — forked from alashow/OkHttp3Stack.java
An OkHttp backed HttpStack for Volley (okhttp3 version)
/**
* The MIT License (MIT)
*
* Copyright (c) 2015 Circle Internet Financial
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@nanangarsyad
nanangarsyad / VolleyOkHttp3StackInterceptors.java
Created June 5, 2018 08:51 — forked from LOG-TAG/VolleyOkHttp3StackInterceptors.java
CREDITS: <1>https://gist.github.com/alashow/c96c09320899e4caa06b <2>https://gist.github.com/intari/e57a945eed9c2ee0f9eb9082469698f3 <3>https://gist.github.com/alirezaafkar/a62d6a9a7e582322ca1a764bad116a70 Reason: for making the Volley use latest okhttpstack work for latest version Volley 1.1.0 by removing all deprecated org.apache dependencies!
/**
* Created by @subrahmanya on 2/3/18.
* CREDITS:
*<1>https://gist.github.com/alashow/c96c09320899e4caa06b
*<2>https://gist.github.com/intari/e57a945eed9c2ee0f9eb9082469698f3
*<3>https://gist.github.com/alirezaafkar/a62d6a9a7e582322ca1a764bad116a70
*
*
* Reason: for making the Volley use latest okhttpstack work for latest version Volley 1.1.0 by removing all deprecated org.apache dependencies!
*/
@nanangarsyad
nanangarsyad / helloworld.dex.md
Created May 23, 2018 02:58 — forked from lifuzu/helloworld.dex.md
execute the dex file in android with command
public class HelloWorld {
    public static void main(String[] args) {
         System.out.println("Hello World!");
    }
}

To run it on an android device:

javac HelloWorld.java
@nanangarsyad
nanangarsyad / configure_schroot.sh
Created May 23, 2018 01:34 — forked from joekickass/configure_schroot.sh
Schroot for Android development
[ubuntu-lucid]
description=Ubuntu
type=directory
directory=/var/chroot/ubuntu
users=myusername
root-users=myusername
aliases=lucid,default
@nanangarsyad
nanangarsyad / PhpFireBaseNotificationSample.php
Created May 6, 2018 01:17 — forked from MohammadaliMirhamed/PhpFireBaseNotificationSample.php
Simple PHP FireBase (FCM) script showing how to send an Android push notification. Be sure to replace the SERVER_API_ACCESS_KEY with a proper one from the Google API's Console page. To use the script, just call http://sample.com/PhpFireBaseNotificationSample.php?id=THE_DEVICE_REGISTRATION_ID The main Code For GCM is https://gist.github.com/prime…
<?php
#API access key from Google API's Console
define( 'API_ACCESS_KEY', 'YOUR-SERVER-API-ACCESS-KEY-GOES-HERE' );
$registrationIds = $_GET['id'];
#prep the bundle
$msg = array
(
'body' => 'Body Of Notification',