Skip to content

Instantly share code, notes, and snippets.

View zjm168love's full-sized avatar

zjm168love

  • Accenture
  • SH
View GitHub Profile
@ninehills
ninehills / chatpdf-zh.ipynb
Last active April 9, 2024 06:40
ChatPDF-zh.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@k8scat
k8scat / check_ssl.py
Created April 30, 2021 03:30
Check ssl expire time
# Maintainer: k8scat@gmail.com
import sys
import time
from datetime import datetime
import ssl
import socket
def get_ssl_info(domain, port=443):
@yihong0618
yihong0618 / shanbay_remember.js
Last active December 1, 2022 04:40
扇贝加密破解自动发送今日新词到 telegram
const https = require("https");
const token = ""; // change this to you telegram bot token!
const chatId = ""; // change this to your telegram chat id!
const cookie = ""; // change this to your shanbay cookie!
const PATH_API = (page) =>
`/wordsapp/user_material_books/blozps/learning/words/today_learning_items?ipp=10&page=${page}&type_of=NEW`;
const options = {
@twirrim
twirrim / sslcheck.py
Created August 29, 2018 22:10
ssl check
import socket
import ssl
import datetime
from multiprocessing.dummy import Pool as ThreadPool
# Tuples containing host and port
CERTS_TO_CHECK = [("host_one", 443),
("host_two", 25)]
@gdamjan
gdamjan / ssl-check.py
Last active April 14, 2024 07:16
Python script to check on SSL certificates
# -*- encoding: utf-8 -*-
# requires a recent enough python with idna support in socket
# pyopenssl, cryptography and idna
from OpenSSL import SSL
from cryptography import x509
from cryptography.x509.oid import NameOID
import idna
from socket import socket
@StevenACoffman
StevenACoffman / Eureka vs Consul.md
Last active March 9, 2024 08:11
Eureka vs Consul

Comparison of Spring Cloud with Eureka

I feel Consul.io does better in the following area:

  • The focus on scriptable configuration allows for better container management.
    Eureka requires either external Configuration Server or multiple configuration files.

  • The options for securing communications is more advanced.
    Eureka requires creating application with security settings desired. Default will allow HTTP only. Registration of end points assumes http but can be forced to https with code.

@pathcl
pathcl / check ssl certificate
Created September 16, 2015 19:17
check_ssl_certificate.py
#!/usr/bin/python
"""
Usage: check_ssl_certificate -H <host> -p <port> [-m <method>]
[-c <days>] [-w <days>]
-h show the help
-H <HOST> host/ip to check
-p <port> port number
-m <method> (SSLv2|SSLv3|SSLv23|TLSv1) defaults to SSLv23
-c <days> day threshold for critical
@mscharhag
mscharhag / Java8DateTimeExamples.java
Created February 24, 2014 19:53
Examples for using the Java 8 Date and Time API (JSR 310)
import java.time.*;
import java.time.format.DateTimeFormatter;
import java.time.format.FormatStyle;
import java.time.temporal.ChronoUnit;
import java.time.temporal.TemporalAdjusters;
import java.util.*;
import static java.time.temporal.TemporalAdjusters.*;
public class Java8DateTimeExamples {