Skip to content

Instantly share code, notes, and snippets.

View NitriKx's full-sized avatar

Benoît Sauvère NitriKx

View GitHub Profile
var ids=[203742316,
292566812,
301889439,
554951139,
433199066,
598142724,
452958246,
880599639,
2021663434,
@NitriKx
NitriKx / SimpleHTTPServerWithUpload.py
Last active July 28, 2017 10:44 — forked from UniIsland/SimpleHTTPServerWithUpload.py
Simple Python Http Server with Upload (support directories creation + only 127.0.0.1 + return 500 if error + CORS + Preflight requests + JSON/Gzip encoding support + DELETE)
#!/usr/bin/env python
"""Simple HTTP Server With Upload.
This module builds on BaseHTTPServer by implementing the standard GET
and HEAD requests in a fairly straightforward manner.
"""
__version__ = "0.1"
__all__ = ["SimpleHTTPRequestHandler"]
@NitriKx
NitriKx / GoogleAppEngineOkHTTP3RetrofitCallFactory.java
Created August 31, 2017 15:17
OkHttp3 Call Factory for Google AppEngine (useful for using swagger with Retrofit2 template)
package com.teevity.api.lowlevel.impl.googleappengine;
import java.io.IOException;
import java.io.InputStream;
import java.net.HttpURLConnection;
import java.net.URL;
import com.google.common.base.Strings;
import com.teevity.api.lowlevel.impl.ApiException;
@NitriKx
NitriKx / Coinhive-Dockerfile
Created October 9, 2017 15:47
Usage : docker --rm coinhive xxxxxxxxxx --username xxxxxx
FROM debian:jessie
RUN apt-get update && apt-get install -y curl libgtk-3-0 libgconf-2-4 libpangocairo-1.0-0 chromium
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash
RUN apt-get install -y nodejs && apt-get -y clean
RUN mkdir -p /opt/coin-hive && cd /opt/coin-hive && npm install coin-hive
---
AWSTemplateFormatVersion: '2010-09-09'
Description: 'Croit training VM'
Parameters:
EnvironmentName:
Description: A name that will be used in the resource creation
Type: String
AllowedPattern: "[a-zA-Z0-9]+"
InstanceType:
Description: EC2 instance type
@NitriKx
NitriKx / delete-wiz-k8s-connector-in-error.py
Last active July 18, 2023 13:31
Delete all the Wiz Kubernetes connector in Error
import logging
import requests
from builtins import print, str, len, int, range, enumerate
from python_graphql_client import GraphqlClient
from requests import HTTPError
from typing import List, Optional, Dict
logging.basicConfig(level=logging.INFO)
logger = logging.getLogger("wiz-client")
@NitriKx
NitriKx / google-ca-cert.pem
Created January 26, 2024 14:27
Google Root CA
GTS Root R1
===========
-----BEGIN CERTIFICATE-----
MIIFVzCCAz+gAwIBAgINAgPlk28xsBNJiGuiFzANBgkqhkiG9w0BAQwFADBHMQswCQYDVQQGEwJV
UzEiMCAGA1UEChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3Qg
UjEwHhcNMTYwNjIyMDAwMDAwWhcNMzYwNjIyMDAwMDAwWjBHMQswCQYDVQQGEwJVUzEiMCAGA1UE
ChMZR29vZ2xlIFRydXN0IFNlcnZpY2VzIExMQzEUMBIGA1UEAxMLR1RTIFJvb3QgUjEwggIiMA0G
CSqGSIb3DQEBAQUAA4ICDwAwggIKAoICAQC2EQKLHuOhd5s73L+UPreVp0A8of2C+X0yBoJx9vaM
f/vo27xqLpeXo4xL+Sv2sfnOhB2x+cWX3u+58qPpvBKJXqeqUqv4IyfLpLGcY9vXmX7wCl7raKb0
xlpHDU0QM+NOsROjyBhsS+z8CZDfnWQpJSMHobTSPS5g4M/SCYe7zUjwTcLCeoiKu7rPWRnWr4+w
@NitriKx
NitriKx / vault-audit-logs-bigquery-schema.json
Created November 7, 2024 13:41
BigQuery schema for the Vault JSON audit logs
[
{
"name": "auth",
"type": "RECORD",
"mode": "NULLABLE",
"fields": [
{
"name": "accessor",
"type": "STRING",
"mode": "NULLABLE"