Skip to content

Instantly share code, notes, and snippets.

View ilyasKerbal's full-sized avatar

ILYAS KERBAL ilyasKerbal

View GitHub Profile
@varunon9
varunon9 / AlwaysRunningAndroidService.md
Last active July 17, 2025 00:10
How to create an always running service in Android

Full Source Code: https://github.com/varunon9/DynamicWallpaper/tree/always_running_service

Steps-

  1. Create a Foreground Service (MyService.java)
  2. Create a Manifest registered Broadcast Receiver (MyReceiver.java) which will start your Foreground Service
  3. In onDestroy lifecycle of MyService, send a broadcast intent to MyReceiver
  4. Launch the MyService on app start from MainActivity (see step 8)
  5. With above 4 steps, MyService will always get re-started when killed as long as onDestroy of Service gets called
  6. onDestroy method of Service is not always guaranteed to be called and hence it might not get started again
@rengler33
rengler33 / scrape_with_logs.py
Last active February 8, 2025 04:09
How to Capture Network Traffic When Scraping with Selenium & Python
# see rkengler.com for related blog post
# https://www.rkengler.com/how-to-capture-network-traffic-when-scraping-with-selenium-and-python/
import json
import pprint
from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities
capabilities = DesiredCapabilities.CHROME
@jacopo-j
jacopo-j / frida-spoof.js
Last active July 8, 2025 10:07
Frida script to spoof and hide several Android identifiers
/* Utilities */
var RANDOM = function() {};
function _randomInt(min, max) {
return Math.floor(Math.random() * (max - min + 1)) + min;
}
function _randomHex(len) {
var hex = '0123456789abcdef';
@RageshAntony
RageshAntony / App.def
Last active May 2, 2024 10:28
Kotlin/Native C Interop - Usage in Kotlin class
headers = nuklear.h App.h nuklear_glfw_gl2.h nk_defines.h /usr/include/GLFW/glfw3.h /usr/include/GLFW/glfw3native.h
compiler-options = -framework OpenGl
package = glfw
linkerOpts.osx = -L/opt/local/lib -L/usr/local/lib -lglfw
linkerOpts.linux = -L/usr/lib64 -L/usr/lib/x86_64-linux-gnu -lglfw -lGLU -lGL -lglut
linkerOpts.mingw = -lglfw
@c5inco
c5inco / SwipeableCards.kt
Last active December 12, 2024 02:35
Jetpack Compose implementation of inspiration: https://twitter.com/philipcdavis/status/1534192823792128000
package des.c5inco.cardswipecompose
import androidx.compose.animation.core.Animatable
import androidx.compose.animation.core.CubicBezierEasing
import androidx.compose.animation.core.LinearOutSlowInEasing
import androidx.compose.animation.core.animateDpAsState
import androidx.compose.animation.core.animateFloatAsState
import androidx.compose.animation.core.calculateTargetValue
import androidx.compose.animation.core.keyframes
import androidx.compose.animation.splineBasedDecay
@dlew
dlew / trombonechamp.kt
Created September 24, 2022 14:36
Trombone Champ hacky trombone code
import be.tarsos.dsp.AudioEvent
import be.tarsos.dsp.io.jvm.AudioDispatcherFactory
import be.tarsos.dsp.pitch.PitchDetectionHandler
import be.tarsos.dsp.pitch.PitchDetectionResult
import be.tarsos.dsp.pitch.PitchProcessor
import be.tarsos.dsp.pitch.PitchProcessor.PitchEstimationAlgorithm
import java.awt.Robot
import java.awt.event.InputEvent
import java.util.concurrent.Executors
import java.util.concurrent.TimeUnit
@DavideGalilei
DavideGalilei / sqlcipher_dump.js
Created December 8, 2022 11:12
Dump sqlcipher me.lam.calculatorvault sqlite database using Frida [ROOT]
// Thanks to https://ackcent.com/recovering-sqlcipher-encrypted-data-with-frida/
// frida -U -l sqlcipher_dump.js -f me.lam.calculatorvault
Java.perform(function() {
function dumpDb(File, db, path) {
var file = File.$new(path + ".plaintext");
file.delete();
db.rawExecSQL("ATTACH DATABASE '" + path + ".plaintext' AS plaintext KEY '';SELECT sqlcipher_export('plaintext');DETACH DATABASE plaintext;");
console.warn("\t[+] Dumped plaintext database at " + path + ".plaintext");
}
@KlassenKonstantin
KlassenKonstantin / RoundedCornerSurface.kt
Created August 9, 2023 15:21
Keep inner radii appealing
class MainActivity : ComponentActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContent {
InnerRadiusTheme {
// A surface container using the 'background' color from the theme
Surface(modifier = Modifier.fillMaxSize(), color = MaterialTheme.colorScheme.background) {
Column(
verticalArrangement = Arrangement.Center
) {