Skip to content

Instantly share code, notes, and snippets.

View Demon000's full-sized avatar
😴
nothin

Cosmin Tanislav Demon000

😴
nothin
  • Cluj-Napoca, România
View GitHub Profile
@Demon000
Demon000 / gist:a0e7d007363d1ec035b3ec24b61ead54
Created December 13, 2023 16:21
JavaScript KeyboardEvent to Android KEYCODE
private browserKeyToKeycode(
data: BrowserKeyboardEvent,
): KeyCode | undefined {
switch (data.code) {
case 'ShiftLeft':
return KeyCode.KEYCODE_SHIFT_LEFT;
case 'ShiftRight':
return KeyCode.KEYCODE_SHIFT_RIGHT;
case 'MetaLeft':
@Demon000
Demon000 / log.txt
Last active September 21, 2023 17:13
tls
0 read chunk <Buffer 16 03 01 00 e1 01 00 00 dd 03 03 61 37 fb 11 ba 72 be 4e ac 79 4d d4 0b d4 a8 9a c4 3d b7 aa 9e ca 53 94 5a 1d 77 54 ee b7 79 5f 20 e8 b5 bf f8 93 8f ... 180 more bytes>
0 read immediately DataBuffer {
appendOffset: 230,
readOffset: 0,
data: <Buffer 16 03 01 00 e1 01 00 00 dd 03 03 61 37 fb 11 ba 72 be 4e ac 79 4d d4 0b d4 a8 9a c4 3d b7 aa 9e ca 53 94 5a 1d 77 54 ee b7 79 5f 20 e8 b5 bf f8 93 8f ... 180 more bytes>
}
0 read encrypted DataBuffer {
appendOffset: 230,
readOffset: 0,
data: <Buffer 16 03 01 00 e1 01 00 00 dd 03 03 61 37 fb 11 ba 72 be 4e ac 79 4d d4 0b d4 a8 9a c4 3d b7 aa 9e ca 53 94 5a 1d 77 54 ee b7 79 5f 20 e8 b5 bf f8 93 8f ... 180 more bytes>
@Demon000
Demon000 / NodeCryptor.ts
Last active September 21, 2023 17:11
tls
import { Cryptor, DataBuffer } from '@web-auto/android-auto';
import DuplexPair from 'native-duplexpair';
import { Duplex, Readable, Writable } from 'node:stream';
import { TLSSocket, connect } from 'node:tls';
export class NodeCryptor extends Cryptor {
private connected = false;
private securePair: {
cleartext: TLSSocket;
encrypted: Duplex;
01-17 12:15:48.636 1970 2055 E imsd : rcsMain.cpp | 76 | | 2055 |########### RCS SERVICE START ##################
01-17 12:15:48.636 1970 2055 E imsd : DaemonBaseImpl.cpp | 89 | | 2055 |addFdToListen[9a8063a8]: adding fd[24] status[0]
01-17 12:15:48.636 1970 2055 E imsd : handshakeHandler.cpp | 34 | | 2055 |handshakeHandler ctor
01-17 12:15:48.636 1970 2055 E imsd : ImsTimer.cpp | 19 | | 2055 |ImsTimer: ctor
01-17 12:15:48.636 1970 2055 E imsd : ImsTimer.cpp | 41 | | 2055 |ImsTimer: initialize
01-17 12:15:48.636 1970 2055 E imsd : ImsTimer.cpp | 49 | | 2055 |ImsTimer: initialize function returns true
01-17 12:15:48.636 1970 2055 E imsd : ImsTimer.cpp | 19 | | 2055 |ImsTimer: ctor
01-17 12:15:48.636 1970 2055 E imsd : ImsTimer.cpp | 19 | | 2055 |ImsTimer: ctor
01-17 12:15:48.636 1970 2055 E imsd : RcsProxy.cpp | 35 | | 2055 |RcsProxy::RcsProxy()
01-17 12:15:48.636 1970 2041 E imsd : RcsIpcReqHandler.cpp | 238 | | 2041 |MainThreadEvtHandler:: activatelinklocalRe
/mnt/nvmestorage/lineage-20.0/kernel/motorola/sm8475/drivers/gpu/msm/kgsl.c:4808:24: warning: shift count >= width of type [-Wshift-count-overflow]
static u64 dma_mask = DMA_BIT_MASK(64);
^~~~~~~~~~~~~~~~
/mnt/nvmestorage/lineage-20.0/kernel/motorola/sm8475/include/linux/dma-mapping.h:94:54: note: expanded from macro 'DMA_BIT_MASK'
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
^ ~~~
/mnt/nvmestorage/lineage-20.0/kernel/motorola/sm8475/drivers/gpu/msm/kgsl.c:4848:36: warning: implicit conversion from 'unsigned long long' to 'unsigned int' changes value from 18446744073709551615 to 4294967295 [-Wconstant-conversion]
dma_set_max_seg_size(device->dev, DMA_BIT_MASK(32));
~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~
/mnt/nvmestorage/lineage-20.0/kernel/motorola/sm8475/include/linux/dma-mapping.h:94:40: note: expanded from macro 'DMA_BIT_MASK'
/dts-v1/;
// version: 17
// last_comp_version: 16
// boot_cpuid_phys: 0x0
/ {
channel-id-map = "acg", "amxbr", "amxpr", "amxmx", "amxcl", "amxar", "amxla", "amxpe", "amxco", "tefbr", "tefmx", "tefar", "tefcl", "tefpe", "tefco", "perar", "entcl", "iusmx", "niibr", "niicl", "niimx", "niipe", "oibr", "timbr", "tigco", "retbr", "retar", "retla", "retcl", "tefla", "retla1st", "tefunl", "tigca", "tigca1st", "retmx", "attmx", "womcl", "avaco", "retpe", "openla", "opencl", "openmx", "altmx", "openpe", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "undefined", "reteu", "retgb", "retfr", "retes", "retie", "retde", "vfgb", "vfde", "vffr", "o2gb", "o2de", "orafr", "bouyfr", "eegb", "tescogb", "yoigo", "oraes", "retapac", "retmea", "vfit", "vfes", "vfeu", "3gb", "tescoie", "altfr", "3ie", "altpt", "timit", "retma", "win
&i2c1 {
gmsl0: gmsl-deserializer@48 {
compatible = "maxim,max9286";
reg = <0x48>;
maxim,gpio-poc = <0 GPIO_ACTIVE_LOW>;
enable-gpios = <&io_expander0 0 GPIO_ACTIVE_HIGH>;
ports {
#address-cells = <1>;
&i2c1 {
gmsl0: gmsl-deserializer@48 {
compatible = "maxim,max9286";
reg = <0x48>;
maxim,gpio-poc = <0 GPIO_ACTIVE_LOW>;
enable-gpios = <&io_expander0 0 GPIO_ACTIVE_HIGH>;
ports {
#address-cells = <1>;
build/make/core/Makefile:72: warning: overriding commands for target `out/target/product/eqs/vendor/bin/cplay'
out/soong/installs-lineage_eqs.mk:88926: warning: ignoring old commands for target `out/target/product/eqs/vendor/bin/cplay'
build/make/core/Makefile:72: warning: overriding commands for target `out/target/product/eqs/vendor/lib/hw/audio.primary.taro.so'
build/make/core/base_rules.mk:533: warning: ignoring old commands for target `out/target/product/eqs/vendor/lib/hw/audio.primary.taro.so'
build/make/core/Makefile:72: warning: overriding commands for target `out/target/product/eqs/vendor/lib/hw/sound_trigger.primary.taro.so'
build/make/core/base_rules.mk:533: warning: ignoring old commands for target `out/target/product/eqs/vendor/lib/hw/sound_trigger.primary.taro.so'
build/make/core/Makefile:72: warning: overriding commands for target `out/target/product/eqs/vendor/lib/libagmclient.so'
build/make/core/base_rules.mk:533: warning: ignoring old commands for target `out/target/product/eqs/vendor/lib/lib
/* 5.10 compatibility */
#include <linux/regulator/driver.h>
#include "../../../drivers/regulator/internal.h"
struct regulator_bulk_devres {
struct regulator_bulk_data *consumers;
int num_consumers;
};