Skip to content

Instantly share code, notes, and snippets.

View Jiab77's full-sized avatar
🤖
Search, Hack and Dev

Doctor Who Jiab77

🤖
Search, Hack and Dev
View GitHub Profile
@Jiab77
Jiab77 / control-your-medias-from-your-fitbit-smartwatch.md
Last active June 27, 2024 20:59
As the title says, and contrary to the myths, it is possible to control your medias from your Fitbit smartwatch and it's not complicated at all!

Control your medias from your Fitbit smartwatch

As the title says, and contrary to the myths, it is possible to control your medias from your Fitbit smartwatch and it's not complicated at all!

TL;DR

As long as the smartwatch firmware and the companion app on your mobile gives the possibility to send app notifications to the smartwatch, you can control your medias from it!

Myths and Reality

GitHub Search Syntax for Finding API Keys/Secrets/Tokens

As a security professional, it is important to conduct a thorough reconnaissance. With the increasing use of APIs nowadays, it has become paramount to keep access tokens and other API-related secrets secure in order to prevent leaks. However, despite technological advances, human error remains a factor, and many developers still unknowingly hardcode their API secrets into source code and commit them to public repositories. GitHub, being a widely popular platform for public code repositories, may inadvertently host such leaked secrets. To help identify these vulnerabilities, I have created a comprehensive search list using powerful search syntax that enables the search of thousands of leaked keys and secrets in a single search.

Search Syntax:

(path:*.{File_extension1} OR path:*.{File_extension-N}) AND ({Keyname1} OR {Keyname-N}) AND (({Signature/pattern1} OR {Signature/pattern-N}) AND ({PlatformTag1} OR {PlatformTag-N}))

Examples:

**1.

@Jiab77
Jiab77 / openpgp.md
Last active November 24, 2021 02:03
@Jiab77
Jiab77 / get-connected-friends-on-second-life-from-terminal.md
Last active June 27, 2024 20:59
If you are like me, lazy but able to get some crazy ideas sometime 😅 then you might have wondered how to get your connected friends on Second Life without being forced to connect on their website.

Get connected friends on Second Life from terminal

If you are like me, lazy but able to get some crazy ideas sometime 😅 then you might have wondered how to get your connected friends on Second Life without being forced to connect on their website.

I must admit that what I'm gonna explain is working only because Linden Labs have REALLY no clue about how security should be implemented correctly...

The above sentence is valid whatever you have enabled or not the MFA on your account.

For example, if a bad actor gets hands on your session cookie, nothing will avoid that bad actor to impersonate your account without any time limit!

@Jiab77
Jiab77 / setup-apcupsd-and-netdata-on-ubuntu.md
Last active September 3, 2024 12:35
In this document, I will explain how to setup apcupsd on Ubuntu 18.04 and 20.04.

Setup apcupsd and netdata on Ubuntu

In this document, I will explain how to setup apcupsd on Ubuntu 18.04 and 20.04.

I'll only document USB connected UPS and not the other supported connection modes.

Remove nut

If you have followed my previous gist related to nut, I'd serisouly recommend you to cleanup everything before continuing this gist.

@Jiab77
Jiab77 / setup-nut-and-netdata-on-ubuntu.md
Last active September 4, 2024 12:44
In this document, I will explain how to setup nut (Network UPS Tools) on Ubuntu 18.04 and 20.04.

Setup nut and netdata on Ubuntu

In this document, I will explain how to setup nut (Network UPS Tools) on Ubuntu 18.04 and 20.04.

It is basically the next chapter of my previous gist, Upgrade nut on Ubuntu 18.04.

I'll only document USB connected UPS and not the other supported connection modes.

Install required dependencies

@Jiab77
Jiab77 / upgrade-nut-on-ubuntu-18.04.md
Last active June 27, 2024 21:01
In this document, I will explain how to upgrade the default nut (Network UPS Tools) version from 2.7.4-5.1ubuntu2 to 2.7.4-11ubuntu4.

Upgrade nut on Ubuntu 18.04

In this document, I will explain how to upgrade the default nut (Network UPS Tools) version from 2.7.4-5.1ubuntu2 to 2.7.4-11ubuntu4.

It is basically the same process as the one used in my previous upgrade gist, Upgrade systemd on Ubuntu 18.04.

The main reason why you would follow this gist is because by default the UPS detection tool nut-scanner is not available by default on Ubuntu 18.04 and can't be compiled correctly from source due to non standard library linking used that does not find the shared library even if it is correctly installed / loaded on the system.

Maybe you have been more lucky than me on your side and then you can simply leave this gist 😅 but on my side every fix attempts resulted in:

@Jiab77
Jiab77 / simple-multi-threaded-php-web-server.md
Last active June 27, 2024 21:24
An easy way to start the embedded PHP web server with the multi-thread option enabled or simulated when necessary.
@Jiab77
Jiab77 / create-DNS-over-TLS-bridge-with-pi-hole-unbound-and-stubby-on-ubuntu-server.md
Last active September 7, 2024 10:40
Few months ago, I've made a similar work but I wanted something a little more easier to manage. Please have a look at here for my previous work.

Create DNS-over-TLS bridge with Pi-hole, unbound and stubby on Ubuntu Server

Few months ago, I've made a similar work but I wanted something a little more easier to manage. Please have a look at here for my previous work.

This time, I'm gonna do pretty much the same thing but using Pi-hole as base then modify it to include unbound and stubby.

This way, I can use the power of Pi-hole with some additional security layers:

  • Recursive DNS check (unbound)
  • DNS-over-TLS (stubby)
@Jiab77
Jiab77 / get_cuda_sm.sh
Created February 22, 2021 21:42 — forked from eyalroz/get_cuda_sm.sh
Shell script for determining the SM value for your (single) GPU
#!/bin/bash
#
# Prints the compute capability of the first CUDA device installed
# on the system, or alternatively the device whose index is the
# first command-line argument
device_index=${1:-0}
timestamp=$(date +%s.%N)
gcc_binary=${CMAKE_CXX_COMPILER:-$(which c++)}
cuda_root=${CUDA_DIR:-/usr/local/cuda}