Outils pour utilisateurs

Outils du site


blog

Terminal shell script faille de sécurité XSS injection code malveillant cat

Voir aussi :

Source https://makandracards.com/makandra/35943-terminal-escape-sequences-the-new-xss-for-linux-sysadmins

$ printf '#!/bin/bash\necho doing something evil!\nexit\n\033[2Aecho doing something very nice!\n' > backdoor.sh

$ chmod +x backdoor.sh

$ cat backdoor.sh
#!/bin/bash
echo doing something very nice!

$ ./backdoor.sh
doing something evil!
2025/03/24 15:06

Sécu - Scan de vulnérabilités

Voir :

  • suricata
  • openvas
  • nmap
  • Qualys
2025/03/24 15:06

Téléphone portable Android connexion PC sous GNU/Linux

Notes adb

Voir :

Préreq :

  1. le mode debug USB doit être activé
  2. le debug doit être autorisé. Si pas le cas passez en “Photo transfer (PTP) mode”

Install

apt-get install android-tools-adb

Autre outils ?

apt-cache search android-tools
android-tools-adb - Android Debug Bridge CLI tool
android-tools-fsutils - Android ext4 utilities with sparse support
android-tools-fastboot - outil en ligne de commande pour le protocole Fastboot d'Android
Connexion
adb start-server
adb devices
lsusb
Bus 002 Device 005: ID 0e8d:201d MediaTek Inc

~/.android/adb_usb.ini

# 0xidVendorHere
0x0e8d

ou

export ADB_VENDOR_KEYS=0x0e8d

Redémarrage d'adb pour le prise en compte de la modif

adb start-server
adb kill-server

Copie

adb push plop.txt /sdcard/
App
Dépôts alternatifs

Voir aussi :

Install de F-Droid un dépôt de Logiciel Libre

wget https://f-droid.org/FDroid.apk
adb install FDroid.apk

Mise à jour

adb install -r cartes-gps-navigation-osmand.apk

Liste des applis installées

adb shell 'pm list packages -f'

Exemple sauvegarde

#adb backup -apk -shared -all -f backup.ab
adb backup '-apk -shared -all -f backup.ab'

Tar du fichier de sauvegarde

tail -n +5 backup.ab |pigz -d -z  > backup.tar
dd if=backup.ab bs=24 skip=1 |pigz -d -z  > backup.tar

Notes fastboot

Voir :

Prerequisites:

  • unlocked bootloader
  • adb and fastboot installed on your computer
adb reboot bootloader
#fastboot flash recovery twrp-2.8.x.x-xxx.img
fastboot flash system <ROM file here>
fastboot reboot

Source : https://www.thecustomdroid.com/how-to-unlock-bootloader-on-huawei-devices/

adb reboot bootloader
fastboot devices
fastboot oem unlock 2155388422526005
fastboot getvar unlocked
fastboot reboot

Source : https://www.kingoapp.com/root-tutorials/how-to-unlock-bootloader-android-device.htm

apt-get install android-tools-fastboot
 
fastboot devices
fastboot oem unlock
 
# Après confirmation sur le téléphone : 
fastboot reboot

Recovery Fastboot https://www.androidpit.com/forum/731450/wiko-sunny-how-to-get-twrp-recovery-installed

fastboot devices
fastboot oem unlock
 
fastboot flash recovery recovery.img
 
fastbook
fastboot oem unlock
< waiting for device >

Partage de fichier - montage lecteur

Partage MTP (Transfère de fichiers)
apt-get install mtp-tools jmtpfs mtpfs

avec interface graphique

apt-get install gmtp
mkdir ~/mnt/mtp/
jmtpfs ~/mnt/mtp/
rsync -ax /media/cdrom/ mnt/mtp/Carte\ SD/plop/
fusermount ~/mnt/mtp/
Partage PTP (Transfère de photos)

Pb

$ adb install cartes-gps-navigation-osmand.apk 
4529 KB/s (18980364 bytes in 4.092s)
        pkg: /data/local/tmp/cartes-gps-navigation-osmand.apk
Failure [INSTALL_FAILED_ALREADY_EXISTS]

$ adb install -r cartes-gps-navigation-osmand.apk 
4861 KB/s (18980364 bytes in 3.812s)
        pkg: /data/local/tmp/cartes-gps-navigation-osmand.apk
 Success

Autres

Logs

adb logcat | grep $(adb shell ps | grep org.smssecure.smssecure | cut -c10-15)
logcat -C -b crash,system,main 'bash:S logcat:S mali_winsys:S *:I'

Droits appli

adb shell pm grant uk.co.richyhbm.monochromatic android.permission.WRITE_SECURE_SETTINGS

root access
https://f-droid.org/wiki/page/Should_I_root_my_device%3F

debian
https://www.debian-fr.org/t/debian-kit-debian-en-parallele-dandroid-sans-chroot/59967

Sécurité Sources inconnues Autoriser l'installation d'application issue de sources inconnues

wget http://download.clockworkmod.com/superuser/superuser.zip
 
mkdir plop
cd plop
unzip ../superuser.zip
 
adb kill-server
$ adb root
adbd cannot run as root in production builds
Note root wiko

SuperSU TWRP ( Team Win Recovery Project)

wipe dalvik/cache

Changer son IMEI ? https://play.google.com/store/apps/details?id=com.cryptotel.chamelephon

adb shell getprop ro.build.version.release
adb shell getprop |grep ro.build.version.release

Autres

Désinstaller une application système

adb shell pm uninstall -k --user 0 foundation.e.mail
2025/03/24 15:06

Téléchargement

Source : https://www.debian.org/CD/http-ftp/#stable

Veuillez utiliser à la place un outil qui permet la reprise des téléchargements interrompus.

  • Sous UNIX et GNU/Linux, vous pouvez utiliser aria2, wget ou curl ou HTTPie
wget -c URL

ou

curl -C - -L -O URL

Remplacer URL par l'adresse HTTP ou HTTPS

Vous pouvez aussi consulter une comparaison de gestionnaires de téléchargement pour vous aider à choisir un programme qui vous convient.

2025/03/24 15:06

Tcp cluster nonlocal bind

/etc/sysctl.conf

net.ipv4.ip_nonlocal_bind = 1
2025/03/24 15:06
blog.txt · Dernière modification : de 127.0.0.1

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki