this script will generate routing files for ocserv and iproute2 based on MaxMind's GeoLite2
usage: generate.py [-h] [-i] [-g] [-cc]
optional arguments:
-h, --help show this help message and exit
-i CSV Dir
| class PipelineExecutor { | |
| private headOfExecutionChain: ExecutionUnit; | |
| constructor(units: ExecutionUnit[]) { | |
| const totalUnits = units.length; | |
| for (let i = 0; i <= totalUnits; i++) { | |
| if (i < totalUnits - 1) { | |
| units[i].setNext(units[i + 1]); | |
| } | |
| } |
| class CanPanic implements ExecutionUnit { | |
| next: ExecutionUnit | null; | |
| pipeline: IAPPipeline; | |
| constructor(pipeline: IAPPipeline) { | |
| this.next = null; | |
| this.pipeline = pipeline; | |
| } | |
| setNext(next: ExecutionUnit): void { | |
| this.next = next; |
| class CanFail implements ExecutionUnit { | |
| next: ExecutionUnit | null; | |
| pipeline: IAPPipeline; | |
| constructor(pipeline: IAPPipeline) { | |
| this.next = null; | |
| this.pipeline = pipeline; | |
| } | |
| setNext(next: ExecutionUnit): void { | |
| this.next = next; | |
| } |
| import requests | |
| from lxml import html | |
| USERNAME = "<username>" | |
| PASSWORD = "<password>" | |
| LOGIN_URL = "https://my.irancell.ir/api/verifyecarepass" | |
| CSRF_URL = "https://my.irancell.ir/" | |
| URL = "https://my.irancell.ir/api/myaccounts_test" |
| #!/bin/abs | |
| # requires https://www.abs-lang.org/ | |
| gateway = "http://192.168.8.1" | |
| token_uri = "/api/webserver/token" | |
| reboot_uri = "/api/device/control" | |
| f get(uri) { | |
| cmd = `curl -s -X GET ${gateway}${uri}` | |
| return cmd |
| ||yektanet.com^ | |
| ||popfa.ir^ | |
| ||mediaad.org^ | |
| ||tapsell.ir^ | |
| ||popupme.net^ | |
| ||kaprila.com^ | |
| ||popupplus.ir^ | |
| ||amarfa.ir^ | |
| ||adro.co^ | |
| ||adtube.ir^ |
| import os | |
| import ffmpy | |
| from flask import Flask, render_template, request, redirect, url_for, flash, send_from_directory, current_app | |
| from werkzeug.utils import secure_filename | |
| from flask_cors import CORS | |
| UPLOAD_FOLDER = './uploads' | |
| ALLOWED_EXTENSIONS = set(['ogg']) | |
| app = Flask(__name__) |
| @echo off | |
| set vlc="C:\Program Files (x86)\VideoLAN\VLC\vlc.exe" | |
| start "" %vlc% --qt-start-minimized dshow:// :dshow-vdev=none :dshow-adev="Stereo Mix (Realtek High Definition Audio)" :live-caching=10 :sout=#transcode{vcodec=none,acodec=vorb,ab=500,channels=2,samplerate=44100}:http{dst=:8080/audiostream.ogg} :sout-keep:dshow |
| #!/usr/bin/env bash | |
| # | |
| # react to cec keypresses in the jankiest way possible | |
| # | |
| # Author: Dave Eddy <[email protected]> | |
| # Date: 10/15/2013 | |
| # Licens: MIT | |
| # Tested on: Raspberry pi with libcec compiled from soure | |
| onright() { |