Skip to content

Instantly share code, notes, and snippets.

View fellypsantos's full-sized avatar
🎯
Focusing

Fellyp Santos fellypsantos

🎯
Focusing
  • Brazil
View GitHub Profile
@fellypsantos
fellypsantos / setup-react-native-env.ps1
Created September 28, 2024 00:42
Script to setup environment variables to make react-native build work.
# Function to set an environment variable if it doesn't exist
function Set-EnvironmentVariableIfNotExists {
param (
[string]$name,
[string]$value,
[string]$target = "User" # By default, set for current user
)
# Check if the environment variable exists
$currentValue = [System.Environment]::GetEnvironmentVariable($name, $target)
@fellypsantos
fellypsantos / tplink-unauth-exploit.py
Created April 27, 2024 15:46 — forked from eacmen/tplink-unauth-exploit.py
TP-LINK WL-WA850RE POC Unauthenticated Exploit
@fellypsantos
fellypsantos / adb-screenshot.bat
Created September 29, 2022 12:45
Take a screenshot from phone connected over adb, and save it to desktop.
@echo off
REM Screenshots will be saved to save directory
REM where your script is running.
REM Generate filename as timestamp
set FILENAME=%DATE:/=-%@%TIME::=-%
set FILENAME=%FILENAME: =%
set FILENAME=%FILENAME:,=.%.png
@fellypsantos
fellypsantos / Tampermonkey-XHR-Intercept.js
Created March 21, 2022 18:18
Script to intercept XMLHttpRequest calls made by some page.
/* Intercept XMLHttpRequests */
(function(open) {
XMLHttpRequest.prototype.open = function() {
this.addEventListener("readystatechange", function() {
console.log("readyState: "+this.readyState);
}, false);
open.apply(this, arguments);
};
})(XMLHttpRequest.prototype.open);
@fellypsantos
fellypsantos / CadSUSWebNoExpire.user.js
Last active February 18, 2022 17:59
Script para desabilitar expiração de sessão do CadSUSWeb, assim o operador fica sempre logado aumentando a produtividade pois não terá de fazer logins demorados consantemente.
// ==UserScript==
// @name CADSUS Web - Sessão Ilimitada
// @namespace cadsusweb#[email protected]
// @version 1.0
// @description Mantém sessão cadsusweb ativada até que o navegador seja fechado.
// @author [email protected]
// @match https://cadastro.saude.gov.br/novocartao/restrito/usuarioConsulta.jsp*
// @match https://cadastro.saude.gov.br/novocartao/restrito/usuarioCadastro.jsp*
// @downloadURL https://gist.github.com/fellypsantos/c10515c430a8e1ac6ad7c19c17ed93e4/raw/68ad0c130b195aeedddfa674f8252214e67997aa/CadSUSWebNoExpire.user.js
// @updateURL https://gist.github.com/fellypsantos/c10515c430a8e1ac6ad7c19c17ed93e4/raw/68ad0c130b195aeedddfa674f8252214e67997aa/CadSUSWebNoExpire.user.js
@fellypsantos
fellypsantos / validar_cpf.php
Created October 21, 2021 14:59 — forked from rafael-neri/validar_cpf.php
Validar CPF em PHP (Completo)
<?php
function validaCPF($cpf) {
// Extrai somente os números
$cpf = preg_replace( '/[^0-9]/is', '', $cpf );
// Verifica se foi informado todos os digitos corretamente
if (strlen($cpf) != 11) {
return false;
@echo off
setlocal enabledelayedexpansion
set folder[0]=C:\Program Files\Corel\CorelDRAW Graphics Suite 2019\Setup\MSIs\VSTA
set folder[1]=C:\Program Files\Corel\PASMUtility\v1
set folder[2]=C:\Program Files\Corel\CorelDRAW Graphics Suite 2019\Setup
set folder[3]=C:\Program Files\Corel\CorelDRAW Graphics Suite 2019\Programs64
set folder[4]=C:\Program Files\Corel\CorelDRAW Graphics Suite 2019\Filters64
set folder[5]=C:\Program Files\Corel\CorelDRAW Graphics Suite 2019\Connect64
@fellypsantos
fellypsantos / MacroConvertCodeToAddress.cs
Last active October 28, 2021 04:45
MacroRecorder c# to convert a street code to full address, number and neighborhood.
/**
Author: [email protected]
Description: C# script to run as a macro inside Macro Recorder program.
It receives a code like "FL" and converts to full address
like "Francisco Lima" house number as default and neighborhood.
*/
using System.Runtime.InteropServices;
using System.Threading;
using System.Windows.Forms;
@fellypsantos
fellypsantos / AndroidManifest.xml
Created June 5, 2020 03:15 — forked from erkattak/AndroidManifest.xml
Android Application Setup for use with Charles Proxy
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
android:networkSecurityConfig="@xml/network_security_config">
@fellypsantos
fellypsantos / open-cmder-here.md
Created May 6, 2020 04:27 — forked from hamzahamidi/open-cmder-here.md
"Open Cmder Here" in context menu

"Open Cmder Here" in context menu

To add an entry in the Windows Explorer context menu to open Cmder in a specific directory, paste this into a OpenCmderHere.reg file and double-click to install it.

    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT\Directory\Background\shell\Cmder]
    @="Open Cmder Here"
 "Icon"="\"%CMDER_ROOT%\\icons\\cmder.ico\",0"