Skip to content

Instantly share code, notes, and snippets.

View dougg0k's full-sized avatar

Douglas Galdino dougg0k

  • Brazil
  • 05:31 (UTC -03:00)
View GitHub Profile
@dougg0k
dougg0k / REACT_NATIVE_SECURITY.md
Last active February 12, 2026 21:31
React Native Security - this compilation were initially built upon a help request about security for a banking app.

Obfuscate code helps.

@dougg0k
dougg0k / code-flags.conf
Last active February 17, 2026 20:50
VSCode flags - ~/.config/code-flags.conf
# Never use more than one --enable-features and --disable-features as it can overwrite the previous.
# This was built using Arch Linux (Wayland) if some flags / features are not compatible with other OS, up to whoever uses, to remove them.
# There are two threads that if ever get implemented into vscode, could bring improvements to the usage experience.
# https://github.com/microsoft/vscode/issues/27378
# https://github.com/microsoft/vscode/issues/221145
# CPU
--enable-features=RawDraw,HighEfficiencyModeAvailable,WebRTCPipeWireCapturer,FractionalScaleV1,WaylandPerSurfaceScale,NetworkServiceSandbox,FontAccess
--disable-features=CalculateNativeWinOcclusion,BackForwardCache,NetworkServiceInProcess,VizDisplayCompositor,UseSkiaRenderer
@dougg0k
dougg0k / edgerouter_doh.md
Last active January 16, 2026 04:00
Edgerouter / EdgeOS / DoH / Security Settings / NextDNS / Cloudflare

Edgerouter / EdgeOS / DoH / Security Settings

Notes

  • It seems that every firmware update, whatever was done to get nextdns into the router, will be gone, so you will have to redo the steps or at least some, if you confirm that it has happened.
  • Make sure to have NTP enabled and configured. To avoid bugs.
  • You can do through the UI CLI or using SSH, if you have enabled it and set a port.
  • You can delete any configuration done, by using delete, e.g., delete firewall all-ping.
  • These steps were confirmed to be working after a complete hardware reset.

In the screen with the Install button, do not press it.

  • Press Shift+F10 to open cmd
  • Type the following commands
REG ADD "HKLM\SYSTEM\Setup\LabConfig" /v BypassTPMCheck /t REG_DWORD /d 1 /f
REG ADD "HKLM\SYSTEM\Setup\LabConfig" /v BypassSecureBootCheck /t REG_DWORD /d 1 /f
REG ADD "HKLM\SYSTEM\Setup\LabConfig" /v BypassRAMCheck /t REG_DWORD /d 1 /f
REG ADD "HKLM\SYSTEM\Setup\LabConfig" /v BypassStorageCheck /t REG_DWORD /d 1 /f
REG ADD "HKLM\SYSTEM\Setup\LabConfig" /v BypassCPUCheck /t REG_DWORD /d 1 /f
import { GraphQLClient, RequestDocument, Variables } from "graphql-request";
export function delay(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
export async function gqlRequest({
url,
document,
variables,
CREATE MATERIALIZED VIEW IF NOT EXISTS latest_prices
AS
SELECT DISTINCT ON (summary_tokens_sold) summary_tokens_sold, price
FROM sgd6.open_sea_sale t1
WHERE block_timestamp = (
SELECT MAX(block_timestamp)
FROM sgd6.open_sea_sale
WHERE summary_tokens_sold = t1.summary_tokens_sold
AND price > 0
)
@dougg0k
dougg0k / index.js
Created September 24, 2021 16:27
Get data from Cloudflare WAF protected url. In this case, was for GraphQL.
const puppeteer = require("puppeteer");
const Xvfb = require("xvfb");
async function getDataFromProtectedUrl({ url, operationName, query, variables }) {
const xvfb = new Xvfb({
silent: true,
xvfb_args: ["-screen", "0", "1280x720x24", "-ac"],
});
xvfb.start((err) => {
if (err) console.error(err);
const puppeteer = require("puppeteer");
const Xvfb = require("xvfb");
async function getOpenseaData({ operationName, query, variables }) {
const xvfb = new Xvfb({
silent: true,
xvfb_args: ["-screen", "0", "1280x720x24", "-ac"],
});
xvfb.start((err) => {
if (err) {
@dougg0k
dougg0k / http_request_proxy_list.ts
Last active August 21, 2021 23:56
Bypass Rate Limiter by IP by making requests through a proxy list.
import got from "got";
import tunnel from "tunnel";
const PROXY_LIST = [
{ ip: "", port: 80 },
{ ip: "", port: 80 },
{ ip: "", port: 80 },
{ ip: "", port: 80 },
];
const getCountryFlagEmoji = countryCode => String.fromCodePoint(...[...countryCode.toUpperCase()].map(x => 0x1f1a5+x.charCodeAt(0)))
getFlagEmoji('GB') // 🇬🇧
getFlagEmoji('JP') // 🇯🇵
getFlagEmoji('ZA') // 🇿🇦