docker run -it --rm -p 5551:5432 --name=db1 --hostname=db1 ubuntu:20.04 bash
docker run -it --rm -p 5552:5432 --name=db2 --hostname=db2 ubuntu:20.04 bash
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| httpClient = { | |
| get: function( url, data, callback ) { | |
| var xhr = new XMLHttpRequest(); | |
| xhr.onreadystatechange = function () { | |
| var readyState = xhr.readyState; | |
| if (readyState == 4) { | |
| callback(xhr); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # this tool will automate firmware extraction and unpacking using FT232R-type adaptors (like BusPirate) and a SOIC clip placed on a chip to dump | |
| # install the necessary software: | |
| #$ sudo apt install flashrom binwalk || echo 'git clone?' | |
| # pump up binwalk with additional packages and libraries | |
| #$ bash <(curl -s https://raw.githubusercontent.com/devttys0/binwalk/master/deps.sh) | |
| # place the clip on the chip, connect it to the adaptor, which sould be connected to your PC (with drivers installed) and launch the script: | |
| # chip => clip => adaptor => PC => script |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * To change this template, choose Tools | Templates | |
| * and open the template in the editor. | |
| */ | |
| package com.example.http.authenticate; | |
| import java.io.*; | |
| import java.text.SimpleDateFormat; | |
| import java.util.Date; | |
| import java.util.HashMap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| if (!('performance' in window)) { | |
| window.performance = { | |
| now: function() { | |
| return +new Date(); | |
| } | |
| }; | |
| } | |
| function trace(text) { | |
| console.log((window.performance.now() / 1000).toFixed(3) + ": " + text); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* garp.c - Send IPv4 Gratuitous ARP Packet | |
| Usage Example: sudo ./garp eth0 | |
| Copyright (C) 2011-2013 P.D. Buchan (pdbuchan@yahoo.com) | |
| Copyright (C) 2013 Seungwon Jeong (seungwon0@gmail.com) | |
| This program is free software: you can redistribute it and/or modify | |
| it under the terms of the GNU General Public License as published by | |
| the Free Software Foundation, either version 3 of the License, or |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #pragma once | |
| #include "Audio.h" | |
| Audio::Audio(std::string str) { | |
| if (str.substr(str.size() - 4) != ".wav") | |
| throw std::invalid_argument("Can only read WAV files!"); | |
| load_wav(str); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #! jruby | |
| require 'java' | |
| java_import 'java.net.InetSocketAddress' | |
| java_import 'java.net.InetAddress' | |
| java_import 'java.net.DatagramSocket' | |
| java_import 'java.net.DatagramPacket' | |
| java_import 'java.net.SocketTimeoutException' | |
| java_import 'java.util.concurrent.SynchronousQueue' |
