This file contains 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
use std::{ | |
sync::Arc, | |
time::{Duration, Instant, SystemTime, UNIX_EPOCH}, | |
}; | |
use anyhow::{Context, Error}; | |
use async_trait::async_trait; | |
use ic_agent::{export::Principal, identity::AnonymousIdentity, Agent}; | |
use rand::{rngs::StdRng, SeedableRng}; | |
use rsa::{ |
This file contains 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
#!/usr/bin/python | |
from __future__ import absolute_import, division, print_function | |
import http.client | |
import socket | |
import ssl | |
import time | |
from ansible.module_utils.basic import AnsibleModule | |
__metaclass__ = type |
This file contains 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
[package] | |
name = "tmp" | |
version = "0.1.0" | |
edition = "2021" | |
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html | |
[dependencies] | |
anyhow = "1.0.86" | |
clap = { version = "4.5.4", features = ["derive"] } |
This file contains 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
FROM debian:trixie-20230904-slim | |
ENV DEBIAN_FRONTEND=noninteractive | |
# https://snapshot.debian.org/archive/debian/20240515T144351Z/ | |
ARG SNAPSHOT=20240515T144351Z | |
RUN \ | |
--mount=type=cache,target=/var/cache/apt,sharing=locked \ | |
--mount=type=cache,target=/var/lib/apt,sharing=locked \ |
This file contains 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
from dataclasses import dataclass, field, fields | |
from http.server import BaseHTTPRequestHandler as BaseHandler | |
from http.server import HTTPServer | |
from typing import IO | |
from uuid import uuid4 | |
import json | |
import os | |
import re | |
import socket |
This file contains 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
# run 'mcpan MaxMind::DB::Writer::Tree' beforehand | |
use MaxMind::DB::Writer::Tree; | |
use Net::Works::Network; | |
my %types = (); | |
my $tree = MaxMind::DB::Writer::Tree->new( | |
ip_version => 4, | |
record_size => 24, |
This file contains 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
"use strict"; | |
const isFirstRun = async () => { | |
const pluginStore = strapi.store({ | |
environment: "", | |
type: "type", | |
name: "setup", | |
}); | |
const initHasRun = await pluginStore.get({ key: "initHasRun" }); |
This file contains 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
import { createContext, useContext, useReducer } from "react"; | |
const initialState = { | |
isSigningIn: false, | |
isSignedIn: false, | |
}; | |
const AuthContext = createContext(initialState); | |
const reducer = (state, action) => { |
This file contains 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
variable "iso_url" { | |
type = string | |
default = "https://cdimage.debian.org/cdimage/release/10.8.0/amd64/iso-cd/debian-10.8.0-amd64-netinst.iso" | |
} | |
variable "iso_checksum" { | |
type = string | |
default = "file:https://cdimage.debian.org/cdimage/release/10.8.0/amd64/iso-cd/MD5SUMS" | |
} |
This file contains 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
package main | |
import ( | |
"bytes" | |
"crypto/aes" | |
"crypto/cipher" | |
"encoding/hex" | |
"encoding/json" | |
"flag" | |
"fmt" |
NewerOlder