一些函数库罢了。
- RSA_Utils(停工)
(TODO)(停工)
引入:source 【脚本路径】
注意:返回值均使用变量:RETURN_VAR
- Profile.sh——Bash脚本头【所有脚本的基础依赖】
- System——系统组件相关【依赖Profile.sh】
prompt——终端打印彩色文字comfirmy——默认选择Y的询问函数comfirmn——默认选择N的询问函数
使用:prompt [参数] "文字"
红色:警告、重点
黄色:警告、一般打印
绿色:执行日志
蓝色、白色:常规信息
例:
#!/bin/bash
source Profile.sh
testPrintln(){
prompt -s "成功信息(绿色)"
prompt -x "执行日志(绿色)"
prompt -e "错误信息(红色)"
prompt -w "警告信息(黄色)"
prompt -i "普通信息(蓝色)"
prompt -m "普通消息(蓝色)"
prompt -k "一个参数(蓝色)" "两个参数(黄色)"
}
testPrintlncheckRootPasswd——检查root密码是否正确checkRootPasswd $1doAsRoot——以root用户身份运行,需要提供root密码doAsRoot -p root密码 -c 命令checkForRoot——检查是否有root权限backupFile——备份文件的方法,要求sudo没有密码才能备份系统文件addFolder——新建文件夹 $1 注意权限!系统文件需要sudo无密码debianBullseyeDetect——显示是否是Debian11,无返回值!isMacOS——检测是否为苹果系统isGNOME——是否是GNOME桌面
系统组件相关操作
引入:import 【包名】
- AES_Utils——AES加密
- AES_CBC——CBC模式
- AES_CFB——CFB模式
- AES_Tools——AES组件共用的函数(十六进制字符串转Byte数组、Byte数组转十六进制字符串)
- Code_Utils——编码
- Base64Bytes——Base64和Bytes
- BytesHexString——十六进制字符串和Bytes
- Datetime_Utils——时间组件
- IO_Utils——输入输出,文件读写
- IO_Utils——文件读写
- RSA_Utils——RSA组件
- com.github.xiangyuecn.rsajava——PKCS1的依赖
- RSA_PKCS1_Utils——处理PKCS1的RSA组件
- RSA_PKCS8_Utils——处理PKCS8的RSA组件
- RSA_Tools——RSA公用函数
- System_Utils——系统组件
- Tools_Utils——工具模块里面的每个包都是独立的,不允许依赖其他包(相互独立)
- IpAddress——IP
- RandomNumber——随机数
- ScheduleTask——定时任务(可以用于代替
while(xx==true){Thread.sleep(1000)}检测变量)
AES模块,CBC模式和CFB模式
注意:byte[] 数据
Python3: 0~256
java: -127~128
- AES CBC
- AES CFB
- AES Tool
public static byte[] hex2bytes(String inputHexString)——十六进制字符串转Byte数组public static String bytes2hex(byte[] b)——Byte数组转十六进制字符串public static byte[] padding(String key, int length)——把所给的String密钥转为一定长度 的 Byte数组并填充
例:
package AES_Utils;
public class test {
public static void main(String[] args) {
String todo = "妳好Hello@";
String hex;
/**
* CFB模式 密码123456 填充;符号
*/
System.out.printf("CFB加密前:%s\n", todo);
AES_Utils.AES_CFB cfb = new AES_Utils.AES_CFB("123456", ";");
hex = cfb.encrypt(todo);
System.out.printf("CFB加密:%s\n", hex);
System.out.printf("CFB解密:%s\n", cfb.decrypt(hex));
/**
* 临时更换密码
*/
hex = cfb.encrypt("12345", todo);
System.out.printf("CFB临时加密(PWD: 12345):%s\n", hex);
System.out.printf("CFB临时解密(PWD: 12345):%s\n", cfb.decrypt("12345", hex));
System.out.println();
/**
* CBC模式 密码123456 偏移量:4321 位数 16:128/32:256
*/
AES_Utils.AES_CBC cbc = new AES_Utils.AES_CBC("123456", "4321", 32);
System.out.printf("CBC加密前:%s\n", todo);
hex = cbc.encrypt(todo);
System.out.printf("CBC加密:%s\n", hex);
System.out.printf("CBC解密:%s\n", cbc.decrypt(hex));
/**
* 临时更换密码
*/
hex = cbc.encrypt("12345", "54321", todo);
System.out.printf("CBC临时加密(PWD: 12345, IV: 54321):%s\n", hex);
System.out.printf("CBC临时解密(PWD: 12345, IV: 54321):%s\n", cbc.decrypt("12345", "54321", hex));
}
}类型转换类
- Base64Bytes——Base64和Bytes
public static String bytes2base64(byte[] data)——传入byte数组执行base64加密public static byte[] base642bytes(String data)——传入String执行base64解密
- BytesHexString——十六进制字符串和Bytes
public static byte[] hex2bytes(String inputHexString)——十六进制字符串转Byte数组public static String bytes2hex(byte[] b)——Byte数组转十六进制字符串
package Code_Utils;
import java.io.UnsupportedEncodingException;
public class test {
public static void main(String[] args) throws UnsupportedEncodingException {
String test = "字符串";
String str = "";
System.out.printf("原始的字符串: %s\n", test);
str = Base64Bytes.bytes2base64(test.getBytes("UTF-8"));
System.out.printf("Base64-E: %s\n", str);
System.out.printf("Base64-D: %s\n", new String(Base64Bytes.base642bytes(str), "UTF-8"));
str = BytesHexString.bytes2hex(test.getBytes("UTF-8"));
System.out.printf("HexString-E: %s\n", str);
System.out.printf("HexString-D: %s\n", new String(BytesHexString.hex2bytes(str), "UTF-8"));
}
}- Datetime_Utils
public static long getTimeStampNow(boolean isMillis)——获取当前时间毫秒时间戳 ,此方法不受时区影响,1675374966417public static LocalTime getTimeNow(Clock zoneClock)——返回当前时间,仅时间,04:42:06.249760public static LocalDate getDateNow(Clock zoneClock)——返回今天日期(无时间),2023-02-17public static LinkedList<Object> periodLocalDate(LocalDate d1, LocalDate d2)——返回d1, d2时间差数据,列表:1.int数组年月日 2.字符串时间差public static LinkedList<LocalDate> getFirstAndLastDayofMonth(LocalDate localDate)——获取某个月的第一天和最后一天public static LinkedList<LocalDate> getFirstInAndLastInMonth(LocalDate localDate, int dayofWeek)——获取某个月的第一个周几和最后一个周几public static LocalDateTime getDateTimeNow(Clock zoneClock)——返回当前日期时间,2023-02-17T05:36:53.899425public static LinkedList<LocalDateTime> getDayMaxAndMin(LocalDate localDate)——获取某天的零点和最大时刻public static LinkedList<Object> durationLocalDateTime(LocalDateTime d1, LocalDateTime d2)——返回d1, d2时间差数据,列表:1.long数组 天、时、分、秒、毫秒、微秒 2.字符串时间差public static ZonedDateTime getZoneDateTimeNow(String szoneId)——获取时区时间 ZoneDateTime 2023-03-13T04:23:39.688183+08:00[Asia/Shanghai]public static ZonedDateTime zonedDateTimeConversion(ZonedDateTime zonedDateTime, String szoneId)——不同时区的时间转换,WARN:注意这两次转换后的纽约时间有1小时的夏令时时差。涉及到时区时,千万不要自己计算时差,否则难以正确处理夏令时。public static DateTimeFormatter getFormatter(String format)——获取格式public static LocalDateTime localDate2LocalDateTime(LocalDate localDate)——localDate转localDateTimepublic static ZonedDateTime LocalDateTime2zonedDateTime(LocalDateTime localDateTime, String szoneId)——localDateTime转为ZonedDateTimepublic static LocalDateTime instant2ShanghaiLocalDateTime(Instant instant)——瞬时时间Instant转为上海LocalDateTimepublic static LocalDateTime timestamp2LocalDateTime(long timestamp, String szoneId, boolean isEpochMilli)——时间戳转为LocalDateTimepublic static long localDateTime2Timestamp(LocalDateTime localDateTime, ZoneOffset zoneOffset, boolean isEpochMilli)——localDateTime转时间戳public static Instant localDateTime2Instant(LocalDateTime localDateTime, ZoneOffset zoneOffset)——LocalDateTime转Instantpublic static Clock getZoneClock(String timezone)——返回某时区的时钟,如:巴黎时区:"Europe/Paris"public static ZoneId getSystemTimezone()——获取系统默认时区
注意:byte[] 数据
Python3: 0~256
java: -127~128
- IO_Utils
public static LinkedList<String> readUsingBufferedReader(File f)——读取文件,以行位单位返回列表,仅适用于单行少的,返回每一行的列表。public static File writeUsingBufferedWriter(File f, LinkedList<String> lines, boolean appendMode)——给定行的列表写入文件public static LinkedList<String> readUsingScanner(File f)——使用Scanner读取较大的文件,但是花时也长public static LinkedList<String> readUsingFileFileChannel(File f)——读取大文本文件public static LinkedList<String> readUsingFiles(File f)——读取小的文本文件,本质上使用BufferedReaderpublic static byte[] readBytesUsingBufferedInputStream(File f)——读取二进制文件public static void writeBytesUsingBufferedOutputStream(File f, byte[] data, boolean appendMode)——写入二进制文件public static byte[] readBytesUsingFileInputStream(File f)——读取小的二进制文件
依赖com.github.xiangyuecn.rsajava
com.github.xiangyuecn.rsajava- 处理PKCS1的依赖,感谢RSA-java项目
- RSA_PKCS1_Utils
public static PrivateKey loadPKCS1_PRK(File f)——加载PKCS1私钥public static PublicKey loadPKCS1_PUK(File f)——加载PKCS1公钥public static void savePKCS1_RSA_Key(RSA_PEM pem, File save_path, boolean isPRK)——保存PKCS1 RSA密钥public static String pem2String(RSA_PEM pem, boolean isPRK, boolean pkcs1)——返回密钥文本public static RSA_PEM generatePKCS1_RSAKey(int key_size)——初始化PKCS1密钥
- RSA_PKCS8_Utils
public static String sign(byte[] data, PrivateKey privateKey, boolean HexString_or_Base64)——用私钥对信息生成数字签名public static boolean verify(byte[] data, PublicKey publicKey, String sign, boolean HexString_or_Base64)——校验数字签名public static byte[] decryptByPrivateKey(byte[] data, PrivateKey privateKey)——用私钥解密public static byte[] decryptByPublicKey(byte[] data, PublicKey publicKey)——用公钥解密public static byte[] encryptByPublicKey(byte[] data, PublicKey publicKey)——用公钥加密public static byte[] encryptByPrivateKey(byte[] data, PrivateKey privateKey)——用私钥加密public static String getBase64PrivateKey(Map<String, Object> keyMap)——取得Base64后的私钥public static String getBase64PublicKey(Map<String, Object> keyMap)——取得Base64后的公钥public static PrivateKey getPrivateKey(Map<String, Object> keyMap)——取得私钥public static PublicKey getPublicKey(Map<String, Object> keyMap)——取得公钥public static PrivateKey loadPKCS8_PRK(File f)——加载PKCS8私钥public static PublicKey loadPKCS8_PUK(File f)——加载PKCS8公钥public static void savePKCS8_RSA_Key(String Base64_RSA_Key, File save_path, boolean isPRK)——保存PKCS8 RSA密钥public static Map<String, Object> generatePKCS8_RSAKey(int key_size)——初始化PKCS8密钥public static KeyPair generatePKCS8_RSAKeyPair(int key_size, String alg)——生成PKCS8 RSA密钥对 (直接保存Encoder密钥Python不兼容)public static Map<String, Object> loadPKCS1_RSA_Key_as_PKCS8(File prk, File puk)——直接读取PKCS1密钥并转为PKCS8密钥使用
- RSA_Tools
public static byte[] readBytesUsingBufferedInputStream(File f)——读取二进制文件public static void writeBytesUsingBufferedOutputStream(File f, byte[] data)——写入二进制文件public static String bytes2base64(byte[] data)——base64加密public static byte[] base642bytes(String data)——base64解密public static byte[] hex2bytes(String inputHexString)——十六进制字符串转Byte数组public static String bytes2hex(byte[] b)——Byte数组转十六进制字符串public static Map<String, Object> PKCS1_2_PKCS8(RSA_PEM pem)——PKCS1转PKCS8public static RSA_PEM PKCS8_2_PKCS1(PrivateKey prk, PublicKey puk)——PKCS8 转 PKCS1
依赖:Datetime_Utils、IO_Utils、System_Utils
- System_Utils
checkSystemType()——判断系统是Windows(0)、Linux(1)或者MacOS(2)或者其他(-1)public static boolean isWindows()——是否是Windows系统public static boolean isRunAsAdministrator()——是否以管理员运行public static LinkedList<LinkedList<String>> execCommandByRuntime(String cmd,LinkedList<File> logfile,boolean optionIfWindowsSetCharsetToGBK,boolean optionIfLinuxSetGnomeTerminalVisible,int optionTimestampMode,boolean verbose,long timeout,TimeUnit timeUnit)——使用Runtime运行命令。cmd 字符串命令、logfile 日志文件,如果不生成,请填写null。仅提供长度一位:标准、错误全部在一个文件。提供两位:标准和错误分开输出、optionIfWindowsSetCharsetToGBK 如果是Windows系统,启用GBK编码、optionIfLinuxSetGnomeTerminalVisible 如果是Linux系统,使用GNOME Terminal运行、optionTimestampMode 文件输出带时间戳的模式(其他: 不带时间,1:LocalDateTime 2023-03-20T21:57:15.676611,2:ZonedDateTime 2023-03-20T21:57:15.677782+08:00[Asia/Shanghai],3:时间-中文-毫秒 2023年03月20日22时02分40.602148秒,4:毫秒时间戳) 1679320718584)、verbose 是否直接输出到命令行、timeout 超时 小于等于0忽略、timeUnit 时间单位,如果timeout小于等于0,这个参数无效、@return LinkedList<LinkedList> 列表1(0):标准输出 列表2(1):标准错误 列表3(2):退出码public static LinkedList<LinkedList<String>> execCommandByRuntime(String cmd)——仅运行命令public static String execCommandByProcessBuilder(String cmd)——仅运行命令(不能带空格)public static String execCommandByProcessBuilder(String[] cmd)——仅运行命令(允许空格)public static LinkedList<LinkedList<String>> execCommandByProcessBuilder(String cmd,File[] logfile,boolean redirectErrorStream,long timeout,TimeUnit timeUnit)——使用ProcessBuilder运行命令。cmd 命令(不允许空格)、logfile null为无日志文件。每次运行日志都会被覆盖!如果重定向错误日志,请提供一个日志文件。如果没有重定向,请提供两个、redirectErrorStream 是否重定向错误(一般为是)、timeout 超时 小于等于0时无效、timeUnit 单位、 @return 标准输出 标准错误 退出码public static LinkedList<LinkedList<String>> execCommandByProcessBuilder(String[] cmd,File[] logfile,boolean redirectErrorStream,long timeout,TimeUnit timeUnit)——使用ProcessBuilder运行命令 命令(允许空格)public static Path mkdir(Path path, boolean isMkdirs)——创建文件夹public static Path mkdirs(Path path)——mkdir -ppublic static Path mkdir(Path path)——mkdir 存在会报错public static Path touch(Path path, boolean overwrite)——创建文件public static Path touch(Path path)——touch 直接覆盖public static LinkedList<Path> copy(Path src, Path dst)——复制文件或文件夹(覆盖)public static LinkedList<Path> copyFollowLinks(Path src, Path dst)——复制文件或文件夹(覆盖)public static LinkedList<Path> copyExcludeDotfiles(Path src, Path dst)——复制当前目录中除了点文件以外的文件(仅允许目录),且不跟随符号链接public static LinkedList<Path> move(Path src, Path dst)——移动文件或文件夹(覆盖)public static LinkedList<Path> moveFollowLinks(Path src, Path dst)——移动文件或文件夹(覆盖)public static LinkedList<Path> moveExcludeDotfiles(Path src, Path dst)——移动当前目录中除了点文件以外的文件(仅允许目录),且不跟随符号链接public static LinkedList<Path> rm(Path path)——rm 删除文件(不能删除文件夹和隐藏文件),如果是目录,仅会删除目录中的文件(没有递归)public static LinkedList<Path> rmAll(Path path, boolean action)——删除文件、文件夹public static LinkedList<Path> rmAll(Path path)——rm -r递归删除删除文件(包括隐藏文件)、文件夹public static LinkedList<Path> rmExcludeDotfiles(Path path)——删除当前目录中除了点文件以外的文件(仅允许目录)public static LinkedList<Path> tree(Path path, int level, boolean includeHidden, boolean followLinks)——tree列出所有文件public static LinkedList<Path> tree(Path path)——tree 列出所有(不跟随Link)public static LinkedList<Path> la(Path path)——ls -a 列出包括隐藏文件在内的文件public static LinkedList<Path> ls(Path path)——ls列出文件(隐藏文件除外)public static boolean isDotfiles(Path path)——是否是点开头文件(隐藏文件)public static boolean isInDotDirectory(Path path)——是否在点目录中(隐藏目录),是的话返回true,注意:并不会因为是隐藏文件而true,只专注目录public static Object[] mergeArrays(Object[] a, Object[] b)——合并两个数组public static LinkedList arrayList2LinkedList(List e)——List转LinkedListprivate static HashMap<Integer, Integer> getPythonJavaByteMap(boolean pythonBytesKey)——私有方法,返回Python Bytes对应的JavaBytes 字典public static byte pythonbyte2javabyte(int pybyte)——Python byte转 Java bytepublic static int javabyte2pythonbyte(int jbyte)——Java byte转 Python bytepublic static byte[] pythonbytes2javabytes(byte[] pybytes)——Pythonbyte数组转Javabyte数组public static int[] javabytes2pythonbytes(byte[] jbytes)——Javabyte数组转Pythonbyte数组
- AdministratorChecker——辅助类
Tools项目中的工具包不准依赖其他项目,只能自己成一个文件,单文件, 可以是依赖,也可以是模板参考
-
IpAddress——IP识别
-
IpAddressFilter.java——IP识别public static boolean isValidIPv4(String ipv4Address) {——是否是ipv4public static boolean isValidIPv6(String ipv6Address) {——是否是ipv6public static boolean isValidIPv4AddressWithPort(String ipWithPort) {——是否是ipv4+portpublic static boolean isValidIPv6AddressWithPort(String ipWithPort) {——是否是ipv6+portpublic static int getIpType(String ip) {——检测ip是哪一类(注意:ipv6需要中括号!):"IPv4":1/"IPv6":2/"IPv4 with Port":3/"IPv6 with Port":4/"Invalid IP":5public static Pair<String, String> splitIpAndPort(String ipAddressWithPort) {——返回ip和端口
-
Pair——模拟Kotlin pair
-
-
RandomNumber
- RandomNumber——随机数
public static int randomInt(int min, int max) {public static int secureRandomInt(int min, int max) {public static int mathRandomInt(int min, int max) {
- RandomNumber——随机数
-
ScheduleTask——用来代替While true检查元素变化的周期任务
public class ScheduleTask {public void setExecAsScheduleAtFixedRate(boolean execAsScheduleAtFixedRate) {——设置模式是 scheduleAtFixedRate scheduleWithFixedDelaypublic ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, AtomicBoolean control) {——条件超时public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, AtomicBoolean control, TimeUnit timeUnit) {——条件超时public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, AtomicBoolean control, long checkIinitialDelayMicroSecond, long checkPeriodMicroSecond, TimeUnit timeUnit) {——条件超时构造方法public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond) {——会一直运行此任务,除非外部调用cancle方法public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, TimeUnit timeUnit) {——会一直运行此任务,除非外部调用cancle方法public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, long taskTimeout) {——运行超时public ScheduleTask(Runnable task, long initialDelaySecond, long periodSecond, long taskTimeout, TimeUnit timeUnit) {——超时后会自动退出public void startTask() {——开始任务private void startWithControl(AtomicBoolean control) {——检测控制元素来决定是否停止private void startWithoutControl() {——超时控制public void cancelTask() {——取消任务
引入:复制文件夹到项目中,npm i
// 按需引入
import { prompts as green } from './msystem/msystem.mjs'
green("终端绿色字体");
// 整体引入
import * as msystem from './msystem/msystem.mjs';
msystem.prompte("终端红色字体");
- maes——AES加密模块
- mHashcode——对象数字Hashcode生成(不是Hex!)
- mqrcode——二维码生成与扫描
- msystem——系统相关操作
AES加密模块
- aes_tools.mjs——工具模块
export const bytes2hex=(bytes)=>{——bytes[]=>hexexport const hex2bytes=(hex)=>{——hex=>bytes[]export const keyPadding = (stringKey, length) => {——密钥长度补全export const bytesToString = (arr) => {——读取UTF8编码的字节,并专为Unicode的字符串export const stringToBytes = (str, isGetBytes = true) => {——将字符串格式化为UTF8编码的字节export const bytesToString1 = (arr) => {——Byte数组 (UTF-8) 转字符串export const stringToBytes1 = (str) => {——字符串转Byte数组 (UTF-8)CHARACTER——"UTF-8"
- aes_cfb.mjs——CFB模块
export const cfbCipher = (SecuritykeyStr, initVectorStr, pwdLength = 32) => {——返回加密器export const cfbDecipher = (SecuritykeyStr, initVectorStr, pwdLength = 32) => {——返回解密器export const encrypt = (cipher, message) => {——加密信息export const decrypt = (decipher, hexmessage) => {——解密的方法export const tEncrypt = (message, key, iv, length = 32) => {——临时加密的方法export const tDecrypt = (hexmessage, key, iv, length = 32) => {——临时解密的方法
- aes_cbc.mjs——CBC模块
export const cbcCipher = (SecuritykeyStr, initVectorStr, pwdLength = 16) => {——返回加密器export const cbcDecipher = (SecuritykeyStr, initVectorStr, pwdLength = 16) => {——返回解密器export const encrypt = (cipher, message) => {——加密信息export const decrypt = (decipher, hexmessage) => {—— 解密的方法export const tEncrypt = (message, key, iv, length = 16) => {——临时加密的方法export const tDecrypt = (hexmessage, key, iv, length = 16) => {——临时解密的方法
- maes.mjs——用于引用导出的模块
export class cfbCipher {——可以反复使用的CFB类export class cbcCipher {——可以反复使用的CBC类export const createCFB = (key, iv, length = 32) => {——返回一对CFB加密器,解密器export const createCBC = (key, iv, length = 16) => {——返回一堆CBC加密器、解密器export const encryptCBC = (cipherPair = undefined, msg = "", key = undefined, iv = undefined, length = undefined) => {——CBC加密 如果cipherPair是undefined,则认为是临时加密,需要提供密钥向量等export const decryptCBC = (cipherPair = undefined, msg = "", key = undefined, iv = undefined, length = undefined) => {——CBC解密 如果cipherPair是undefined,则认为是临时加密,需要提供密钥向量等export const encryptCFB = (cipherPair = undefined, msg = "", key = undefined, iv = undefined, length = undefined) => {——CFB加密export const decryptCFB = (cipherPair = undefined, msg = "", key = undefined, iv = undefined, length = undefined) => {——CFB解密function test() {——测试的方法(和Python、Jave匹配)
类似Java的Hashcode() 但是不是很可靠,可能会重复
https://github.com/m3talstorm/hashcode/tree/master
https://stackoverflow.com/questions/194846/is-there-hash-code-function-accepting-any-object-type
const hashCodeObject = (value) => {——Hashcode对象(可能重复!不像Java那样可靠)const hashCodeString = (string) => {——返回字符串的Hashcode数字
二维码模块
const asyncGenerateQR = async (text, width, type) => {——内部函数,生成二维码 With async/awaitexport const createQRSync = (text, savepath, width = "500", type = "svg")——生成二维码图像并保存export const generateQRBase64Promises = (text, width = 500, type = "image/png") => {——With promises 返回Base64图片export const generateQRBase64Async = async (text, width = 500, type = "image/png") => {—— With async/await 返回Base64图片export const decodejpg2Uint8Array = (jpgFile) => {——读取jpg图片转为Uint8Arrayexport const decodepng2Uint8Array = (pngFile) => {——读取png图片转为Uint8Arrayexport const readQRCodeFromFileSync = async (filepath, width = undefined, height = undefined) => {——读取二维码 目前仅支持JPG和PNG
export const getExecFunction = () => {——获取当前运行的函数名称const defaultCallback = (err, data, funcname) => {——默认回调函数 (弃用)const onSuccess = (fn) => {——默认的用于Promise的函数 (弃用)const onFailed = (fn) => {——默认的用于Promise的函数(弃用)export const print = (str, fg = 31, bg = 0, display = 1) => {——简单的终端颜色export const prompt = (str, mode = 4) => {——常用显示export const prompts = (str) => {export const prompte = (str) => {export const prompti = (str) => {export const promptw = (str) => {export const promptm = (str) => {
export const getFileSeparator = () => {——获取文件分隔符export const isWindows = () => {——是否是Windows系统export const setClipboard = (content, sync = true) => {——clipboardy设置粘贴板export const getClipboard = (sync = true) => {——clipboardy获取系统粘贴板信息export const prlst = (list, promptMode = 0) => {——打印列表export const getPathSeparator = () => {——返回环境变量分隔符export const getPath = () => {——获取环境变量export const arrayRemoveDuplicates = (arr) => {——去除重复数组元素export const fileType = (filepath, sync = true) => {——判断文件类型 文件:1 文件夹:2 链接文件:3export const ls = (filepath, sync = true, showHidden = false, followLinks = true, absolutePath = true) => {——lsexport const la = (filepath, sync = true, followLinks = false, absolutePath = true) => {—— 模拟laexport const lsFileExtfilter = (filepath, ext) => {——返回给定扩展名的文件export const fileLinkedto = (filepath) => {——返回链接文件指向 [链接地址, 链接好坏]export const tree = (filepath, showHidden = false, followLinks = false) => {——tree 返回目录下所有文件,包括空文件夹(包含当前文件夹) 仅有同步方法export const treeSync = (filepath, showHidden = false, followLinks = false) => {——目前同上export const mkdir = (dir, sync = true, overwrite = false, recursive = false, mode = "0700") => {——新建文件夹 注意Overwrite!会覆盖的!export const mkdirs = (path, sync = true, overwrite = false, mode = "0700") => {——mkdir -p 注意Overwrite!会覆盖的!export const rm = async (filepath, sync = true, recursive = false) => {——删除文件export const rmClearDirectory = async (dir, sync = true) => {——清空目录export const rmFD = async (filepath, sync = true) => {——删除文件或者文件夹export const cp = (src, dst, sync = true, recursive = false, overwrite = true, errorOnExist = false, dereference = false, eserveTimestamps = false, filter = (src, dest) => { return true; })——复制文件 如果recursive是false,除了src dst,其他Option选项无效export const cpFD = (src, dst, sync = true, overwrite = true, errorOnExist = false, dereference = false, preserveTimestamps = false, filter = (s, d) => { return true; })——复制文件、文件夹export const mv = (src, dst, sync = true) => {——移动文件(重命名)export const mvCPRM = (src, dst, overwrite = true, errorOnExist = false, dereference = false, preserveTimestamps = false, filter = (s, d) => { return true; })——先复制再删除export const readFileContent = (filepath, readFile = false, sync = true, fsopenflag = 'r', encoding = 'utf-8', callback = undefined, fsopenmode = 0o666, fsreadoffset = 0, fsreadbufflength = 0, fsreadlength = undefined, fsreadposition = null)——读取文件export const readFileNReadlines = (filepath, splitor = undefined, code_comment = undefined, sync = true, encoding = "utf-8", ignoreNull = true) => {——逐行读取文件export const readConfFileSync = (filepath, splitor = "=", code_comment = "#") => {——默认配置文件设置export const writeFileContent = (filepath, towrite, sync = true, encoding = "utf-8", flag = "w", overwrite = true, mode = 0o666) => {——写入文件export const writeFileInAppendMode = (filepath, towrite, sync = true, encoding = "utf-8", overwrite = true, mode = 0o666) => {——追加写入export const writeByLinesAsync = (filepath, linesToWrite, flags = "w", encoding = "utf-8", EOL = "\r\n", overwrite = true) => {——逐行写入(仅异步)export const sleep = async (msecond) => {——设置延时,使用:await sleep(xxxx);export const getIpAddr = (type=0) => {——返回本机IP地址const randomNum = (minNum, maxNum) => {——生成从minNum到maxNum的随机数
引入:import 【脚本名称】
- m_AES——AES模块
- m_ColorStdout——终端彩色字体输出(Windows(受限) & Linux)
- m_ConfigFiles——配置文件相关操作
- m_Datetime——时间模块
- m_ExcelOpenpyxl——Excel相关处理(Openpyxl)(读写)
- m_ExcelXlsxWriter——Excel相关处理(XlsxWriter)(只写)
- m_Image——图像处理相关
- m_PDF——PDF文件处理
- m_ProgressBar.py——终端进度条(Linux Only)
- m_QR——二维码生成、识别
- m_RSA——RSA模块
- m_System——系统信息相关
- m_VCF3——通讯录VCF3.0文件读取
- m_Web——网络相关
- m_Winreg——Windows注册表相关
与Java无缝衔接,支持CFB(默认32-256位)、CBC模式(默认长度16-128位)
注意:byte[] 数据
Python3: 0~256
java: -127~128
class AES_CFBdef padding(self, pwd, leng)——填充到指定位数def encrypt(self, content)——加密def decrypt(self, content)——解密def ex_encrypt(self, content, ex_passwd, ex_iv="")——临时加密def ex_decrypt(self, content, ex_passwd, ex_iv="")——临时解密
class AES_CBCdef padding(self, pwd, leng)——填充到指定位数def encrypt(self, content)——加密def decrypt(self, content)——解密def ex_encrypt(self, content, ex_passwd, ex_iv="")——临时加密def ex_decrypt(self, content, ex_passwd, ex_iv="")——临时解密
例:
if __name__ == '__main__':
s = "妳好Hello@"
cipher = AES_CFB("123456", ";")
es = cipher.encrypt(s)
print("KEY:123456 IV:; KEY_SIZE: 32 加密:" + es)
print("KEY:123456 IV:; KEY_SIZE: 32 解密:" + cipher.decrypt(es))
es = cipher.ex_encrypt(s, "12345", "54321")
print("KEY:12345 IV:54321 KEY_SIZE: 32 加密:" + es)
print("KEY:12345 IV:54321 KEY_SIZE: 32 解密:" + cipher.ex_decrypt(es, "12345", "54321"))
print("CBC Test: ")
cipher = AES_CBC("123456", "4321", 32)
es = cipher.encrypt(s)
print("KEY:123456 IV:4321 KEY_SIZE: 32 加密:" + es)
print("KEY:123456 IV:4321 KEY_SIZE: 32 解密:" + cipher.decrypt(es))
es = cipher.ex_encrypt(s, "12345", "54321")
print("KEY:12345 IV:54321 KEY_SIZE: 32 加密:" + es)
print("KEY:12345 IV:54321 KEY_SIZE: 32 解密:" + cipher.ex_decrypt(es, "12345", "54321"))列表、字典等的处理
averageSplitList(list2split:list, n:int)——自动平均分配列表splitListInto(list2split:list, n:int)——将列表强制分为n个permutation(lst, len)——对给定的列表进行排列组合sortListBy(list, byIndex = 0, reverse = False)——列表排序def sortByNatsorted(list):——自然排序功能sortDictByValue(dict, reverse = False)——按值排序字典sortDictByKey(dict, reverse = False)——按key排序字典def hasDuplicates(lst):——判断给定列表中是否有重复元素def find_duplicate_indexes(lst, verbose=False):——返回重复元素+索引def modify_string_if_duplicate(string, lst):——检查是否在给定列表中,并返回字符串,python判断给定新字符串是否包含在原列表中,如果有就加上后缀(1),比如给定x,原来列表中有x,就返回x(1),如果原列表中有x(1),就返回x(2)def remove_duplicates(input_list, preserve_order=True):——去除重复元素
wprint(content, color=4)——Windows端打印彩色文字(颜色可选受限,可自行修改源码)lprint(content, fg=32, bg=40, display=1)——Linux端打印彩色文字(颜色可选多)cprint(content, mode=4——跨平台常用颜色打印(颜色不多)
终端彩色字体输出,支持Windows Powershell、GNOME Terminal
Windows端颜色受限(可以自己修改源代码补充)
例:
#!/usr/bin/python3
"""
Mode预置:
0:暗色蓝
1:暗色绿
2:暗色红
3:亮色蓝
4:亮色绿
5:亮色红
6:蓝底红字
"""
if __name__ == '__main__':
# 打印Windows端可选颜色
for text, color in zip(texts, colors):
if IS_WINDOWS:
wprint(text, color)
for i in range(0, 7):
cprint("cprint-测试字体", i)write_JSON(json_save_path, json_body)——保存JSON到文本文档load_JSON(json_path——从文本文档加载JSON
加载JSON配置文件和保存JSON对象到文本
getFirstAndLastDay(year, month)——获取某月的第一天和最后一天getFirstDayofLastMonth(year, month)——获取上个月第一天的日期,然后加21天就是22号的日期getFirstDayofNextMonth(year, month)——获取下个月的第一天getDateToday()——获取今天日期 2023-01-17getNow(utc=False, timestamp=False)——返回当前时间 2023-01-18 05:08:11.937176getStrTimeNow()——仅仅返回字符串时间 05:14:17daysDalta(dateTime, Days)——计算日期,加减天数datetime2Timestamp(args)——将datetime日期格式,先timetuple()转化为struct_time格式,然后time.mktime转化为时间戳timestamp2Datetime(ts)——时间戳转日期时间,仅能精确到秒str2Datetime(strinput, format=0, datesplit="-", timesplit=":", datetimesplit=" ")——字符串转日期时间getDate(dateTime)——返回日期getTime(dateTime)——返回时间formatOutput(dateTime, format=None ,datesplit="-", timesplit=":", datetimesplit=" ")——格式化输出delayMsecond(t)——精确到1ms的延迟ms定时器 1s = 1000毫秒
def log(data, debugMode=True, note="", abfilepath=False)——记录日志
依赖m_System和m_Arrays
def createNewWorkbook(firstSheetName=None):——新建workbook但不是新建一个实际的文件def createSheet(wb, sheetName, position=None):——新增表格def getSheetNames(wb):——返回Sheets名字def getSheetByIndex(wb, index):——返回Sheetdef copyWorksheet(wb, ws):——复制工作表def readRows(ws, min_row, max_row, min_col, max_col, valueOnly=True):——读行def readColumns(ws, min_col, max_col, min_row, max_row, valueOnly=True):——读列def getCellRange(ws, cell1, cell2):—— 返回一个范围内的单元格def getRowOrColumns(ws, name):——返回行或者列def isnumeric(value):—— 检查给定参数类型def justReadOneRow(ws, row, deep=60, valueOnly=True):——读1行,50列def excel_column_to_number(column_name):——列名转换为对应的列索引def justReadOneColumn(ws, col, deep=50, valueOnly=True):——读列def loadExcel(filename):——加载现有的Excel表格def replaceOneCellValue(wb, ws, cell, checkValue, replacement, whenEqual=True):——替换单元格值def merge_xlsx_files(src_folder, output_file):——简单的创建一个新的工作簿作为合并后的文件(仅合并到一张worksheet!)def delete_worksheets_except_index(input_file, index_to_keep, saveAs=None):——删除除了指定索引的worksheet以外的其他表格def appendData(ws, list):——添加一行数据def worksheetSplitInto(inputFile, outputDir=None, prefix=None):——将一个Excel中的多个worksheet拆成单个文件def cellBold(ws, cellID):——字体加粗def barChart(title="标题", x="X轴", y="Y轴", type="col"):——返回柱状图(空的)def reference(worksheet=None, range_string=None, min_col=None,min_row=None,max_col=None,max_row=None):——返回引用区间def barChartAppendData(chart, data, categories):——为柱状统计图添加数据def deleteWorksheet(wb, worksheetNameOrIndex):——删除指定的worksheetdef is_openpyxl_workbook(obj):——判断是不是workbook对象def copyWorksheetIntoBase(wbSrcf, wsSrc, wbDstf, savePath="", copyTitle=None):——复制某Excel建议用另一个def copyWorksheetInto(wbSrcf, wsSrc, wbDstf, savePath="", copyTitle=None):——复制某Excel到另一个Excel,如果savePath是None,返回wbdef copy_cell_format(source_cell, target_cell):—— 复制源单元格的格式到目标单元格def merge_excel_with_format_and_merged_cells(src_folder, output_file, sheet_name, cell_range):——合并指定文件夹中的Excel文件的某个工作表中的某个范围的数据和格式(包括合并单元格)。def insert_header_from_excel(target_file_or_wb, header_file, header_range, target_sheets=None, savePath=None):——从header_file中读取指定区域的表头,并插入到目标Excel文件的所有工作表或指定工作表的顶部。表头内容和格式会被保留,并在目标文件原有内容之前插入。def remove_blank_rows_or_columns(wb, sheet_name, mode='row'):——从指定的工作表中移除空白行或空白列。def remove_blank_cells(wb, sheet_name, cell_range, mode='row'):——移除指定单元格范围内的空白单元格,按行或列模式处理。
def permutation(lst, len)——对给定的列表进行排列组合def excelIndex2cell(row, col)——将索引转化为字符串定位,如(0,0)==> ‘A1’def colname2num(colname)——Excel 表格单元格转换坐标(A -> 0、AA -> 26)def lines_writer(worksheet_ob, content_in_lines:list, start_row)——添加一行或者多行数据
依赖m_System
def draw_English_text(image, x, y, string, font_size=20, color=(0, 0, 0), word_css="en.ttf", direction=None)——添加英文文字(字体限制英文, 可自行修改中文字体)def draw_text(image, x, y, string, font_size=20, color=(0, 0, 0), word_css="zh.ttf", direction=None):——添加文字,座标负数则从反方向开始计算
依赖m_System、m_Arrays
def add_content(pdf_in_name:str,pdf_out_name:str,content_dict:dict)——添加PDF注释(目录)def mergePdfs(directory, output_pdf_file)——合并PDF(提供目录)def image2pdf(directory, output_pdf_name, content:bool=True):——将所给文件夹的jpg图片转为PDF文档(提供目录)def pdf2images(pdfFile, dpi=200, format='png', toDir="2images"):——拆分PDF到图片def jpg_to_individual_pdf(directory):——将指定文件夹中的每张 JPG 图片转换为单独的 PDF 文件def split_pdf(input_pdf_path, output_dir, export_menu=False):——将PDF拆分成单页的PDF文件def get_bookmarks(pdf_path, outlines=None, parent_name=""):——获取PDF书签def export_bookmarks(input_pdf_path, output_txt_path, delimiter="\t", ignoreTheSame=False):——导出PDF目录与页码的关系def rotate_pdf_pages(directory, rotation_angle):——将指定文件夹中的所有PDF文件按照指定角度顺时针旋转def get_pdf_page_sizes(pdf_file):——获取 PDF 文件中每一页的大小(宽度和高度)。def extract_pages_to_pdf(input_pdf_path, output_pdf_path, page_numbers_str):——从PDF文件中提取指定页码并保存为新的PDF文件def extract_pages_to_jpg(input_pdf_path, output_dir, page_numbers_str, dpi=300):——从PDF文件中提取指定页码并保存为JPG图片
def readQR(qr_path)——识别二维码def generateQR(data, save_file="qr.png", view_only=False)——生成二维码
参考: 来源:https://blog.csdn.net/Lingdongtianxia/article/details/76359555
(Linux Only)
timeBar(float_sec, curr, total, color=32)——返回时间进度条(静态)rateBar(curr, total, color=32, shows=None)——显示进度条百分比(静态)timeWaitfor(sec)——等待时间的进度条(百分之一为间隔,动态)
[███████████████████████████████████████████████████████████████] - 还有0.00秒。
[███████████ ] - 还有30.00秒。
[██████████ ] 10.0 %
[██████████████████████████████████ ] - 5号进程
例:
import m_ProgressBar
if __name__ == '__main__':
# 显示一条时长3秒的进度条
m_ProgressBar.timeWaitfor(3)
# 显示一条红色的时间进度条 时间剩余30秒、进度11% 总量100%、红色
m_ProgressBar.timeBar(30, 11, 100, color=31)
print()
# 显示一条百分比进度条 进度10% 总量100%、绿色
m_ProgressBar.rateBar(10, 100)
print()
# 显示一条白色的百分比进度条 进度34% 总量100%、白色 后缀“5号进程”
m_ProgressBar.rateBar(34, 100, 38, " - 5号进程")依赖m_System
def loadPRK(rsa_private_key_path)——加载RSA私钥def loadPUK(rsa_public_key_path)——加载RSA公钥def sign_msg(prk, msg)——私钥签名 用私钥签名msg信息def verify_msg(puk, sig_msg, msg)——公钥验证签名, 返回是否验证def encrypt_msg(puk, msg)——加密信息, 使用公钥def decrypt_msg(prk, crypto_msg)——解密信息,使用私钥def generateRSA(key_name, key_path, key_length=2048)——用于生成RSA密钥
例:
if __name__ == '__main__':
RSA_NAME = "test"
# 生成RSA密钥
generateRSA(RSA_NAME, key_length=512)
prk = loadPRK(RSA_NAME+".pem")
puk = loadPUK(RSA_NAME+".pub")
print(prk)
print(puk)
# TEST
sign = sign_msg(prk, "妳好")
print("私钥签名信息:{}".format(sign.hex().upper()))
print("公钥验证信息:{}".format(verify_msg(puk, sign, "妳好")))
hex = encrypt_msg(puk, "妳好").hex().upper()
print("公钥加密信息:{}".format(hex))
print("私钥解密信息:{}".format(decrypt_msg(prk, bytes.fromhex(hex))))
# 删除RSA密钥
os.remove(RSA_NAME+".pem")
os.remove(RSA_NAME+".pub")execCommand(cmd, debug=False)——执行命令checkAdministrator()——检查是否有管理员权限cpu_count()——返回CPU核心数isBomExist(text_file_path)——检查文件(UTF-8文本文档)头部是否包含有UTF-BOMremoveBom(filepath)——移除UTF-8文件的BOM字节fdExisted(file_or_dir, expect=0)——判断文件、目录是否以期待的方式存在(0:不做约束 1:文件 2:文件夹)fileOrDirectory(file_or_dir)——判断文件还是目录(-1:other (可能不存在) 1:file 2:dir)rmFD(file_or_dir, expect=0)——删除文件copyFD(src, dst)——复制文件或者文件夹moveFD(src, dst)——移动文件或者文件夹def getSuffixFile(suffix, directory=".", case_sensitive=True):——返回文件夹下的带后缀的文件displaySystemInfo()——打印系统信息,仅Windows和Linuxjavabyte2pythonbyte(javabyte)——Python byte转Java bytejavabytes2pythonbytes(javabytes)——Java byte数组转PythonByte数组pythonbytes2javabytes(pythonbytes)——Python byte数组转Java byte数组pythonbyte2javabyte(pythonbyte)——Python byte转Java byteinputTimeout(str_msg, int_timeout_second)——输入超时模块def remove_newlines(text):——去换行def trim_spaces(string):——使用 strip() 方法去除字符串前后的空格def splitFilePath(file_path):——给定路径分离出文件夹、文件名、扩展名;如果是文件夹,返回上级文件夹的绝对路径、上级文件夹名称和当前文件夹名称def splitFileNameAndExt(file_path):——给定路径分离出文件夹、文件名、扩展名,如果是文件夹返回Nonedef renameFile(src, dst, copyFile=False, prefix=None, suffix=None, ext=None):——重命名文件(可复制)def editFilename(src, dst, prefix=None, suffix=None, ext=None):——编辑文件名def splitFileNameAndExt(file_path):——给定路径分离出文件夹、文件名、扩展名,如果是文件夹返回Nonedef getFileNameOrDirectoryName(abPath):——获取文件名或者文件夹名称def splitFilePath(file_path, fileOrDirectory=0):——给定路径分离出文件夹、文件名、扩展名(带.)。注意:必须是存在的文件夹。如果是文件夹,返回上级文件夹的绝对路径、上级文件夹名称和当前文件夹名称def check_prefix_suffix(string, prefix=None, suffix=None):——检查字符串是否以特定前缀或后缀开头或结尾。def readFileAsList(filepath, separator="\t", comment="#", ignoreNone=True, encoding="UTF-8"):——读取文件到列表def get_relative_path(path1, path2="."):——给定两个路径,返回前者相对于后者的相对路径def sortByNatsorted(list2sort):——返回自然排序的列表def ls(path='.', show_hidden=False):——List directory contents.def tree(directory='.', show_hidden=False):——Recursively get a directory tree with absolute paths.def getTreeAbPath(treeResult):——返回tree的文件路径def filter_file_items(items, exclusion, mode=0, item_type=0, relp=".", withFileExt=False, verbose=False):——从列表中剔除指定的项目def filter_filename_and_directoryname(file_list, exclude, ext=True):——过滤文件名、文件夹列表,精确到扩展名def filter_filename_and_directoryname_contains_string(file_list, exclude_string):——按字符过滤文件名、文件夹列表def isInExcludeList(fp, excludeList, mode=0):——返回是否在排除列表(文件名)def split_path_into_parts(path):——将路径拆分为其组成部分。def mkdir(path, ignoreExisted=True, replace=False):——新建文件夹
例:
if __name__ == '__main__':
print("是否是管理员:{}".format(checkAdministrator()))
execCommand("ls", True)
print("CPU核心数: {}".format(cpu_count()))
print("gitignore文件是否有UTF-8 BOM: {}".format(isBomExist("gitignore")))
# 列出py文件
for f in getSuffixFile("py"):
print(f)def getFieldnames(vcards):——获取字段名称def getFieldnamesAndParams(vcards):——获取字段名+属性名称def readVCF(vcf_file, validate=False, ignoreUnreadable=False, verbose=False):——读取 VCF 文件并收集所有唯一的字段名def process_address(adr):——内部函数def process_name(n):——内部函数def process_list(lst):——内部函数def process_bytes(data):——内部函数def vcards_to_csv(vcards, csv_file):——将 VCF 转换为 CSV 文件def csv_to_vcards(csv_file, delimiter=','):——从 CSV 文件读取数据并转换为 vCard 对象列表。def vcards_to_vcf(vcards, vcf_file, Escaping=False):——将 vCard 对象列表导出为 VCF 文件。def quoted_printable_to_utf8(quoted_printable_string):——将 QUOTED-PRINTABLE 编码的字符串转换为 UTF-8 编码的字符串def decode_vcard_lines(vcard_lines):——将 vCard 文件中的 QUOTED-PRINTABLE 编码的行转换为 UTF-8
def getWebservertime(host)——返回网络日期、时间['2022-06-23', '03:53:01']
此模块Windows Only
createValue(key, subname, type, value)——创建值deleteValue(key, value)——删除值deleteValueEx(fullpath, value)——删除值splitRootPath(fullpath)——分解全路径为root和子路径getKeyInfo(reg, query)——查询Key信息getValue(reg, valuename)——返回值、类型getValueEx(fullpath, valuename)——返回值、类型createSubkey(reg, subname)——创建注册表子键createKey(fullpath)——创建注册表键existedSubkey(key, subname)——是否有注册表子键deleteSubkey(reg, subname)——删除注册表子键deleteKey(fullpath)——删除注册表键existedKey(fullpath)——全路径是否存在getKey(root, Path, permission=winreg.KEY_ALL_ACCESS)——打开注册表getKeyEx(fullpath, permission=winreg.KEY_ALL_ACCESS)——打开注册表getSubkey(key, mode=0)——给定注册表,返回子键名称列表hideSoftware(name, is64Bit=True, accurate=True, hide=True)—— 是否隐藏软件卸载入口 to hide a software from regedit, 添加Dword SystemComponent 1
-
2024.9.23——0.3.7
- Python Excel新增了一些功能
-
2024.7.16——0.3.6
- Python优化了PDF相关代码
-
2024.7.6——0.3.5
- Python优化了Image模块
-
2024.6.19——0.3.4
- Python PDF模块优化、新增功能、修复
-
2024.6.4——0.3.3
- Python新增VCF3.0通讯录读取模块
-
2024.4.17——0.3.2
- Python更新了Excel、System、Array模块
-
2024.4.13——0.3.1
- Python更新了
m_System
- Python更新了
-
2024.4.9——0.3.0
- Python更新了Excel表格拆分功能
-
2024.4.2——0.2.9
- Python更新了Excel读取
-
2024.4.1——0.2.8
- TODO:Python
m_ExcelXlsxWriter分离出,需要一个可以读取Excel的
- TODO:Python
-
2024.3.21——0.2.7
- Python PDF模块新增jpg转pdf
-
2024.1.28——0.2.6
- Java Tool_Utils新增IP相关
-
2023.9.21——0.2.5
- Python PDF模块新增转图像功能
-
2023.8.31——0.2.4
- Java新增Tools工具模块
-
2023.8.26——0.2.3
- Node新增mHashcode模块
-
2023.8.16——0.2.2
- 修复了Node AES模块加密功能无法复用的问题
-
2023.8.15——0.2.1
- Node新增AES加密模块,支持CBC、CFB
-
2023.7.30——0.2.0
- Node qrcode二维码模块基本完成
-
2023.7.23——0.1.9
- Node system模块新增读写功能
-
2023.7.22——0.1.8(Under Dev)
- Node模块写入文件
-
2023.7.6——0.1.7(Under Dev)
- 新增Node.js项目库
-
2023.5.19——0.1.6
- Python新增日志模块
m_Debug
- Python新增日志模块
-
2023.4.25——0.1.5
- Python新增
m_Array
- Python新增
-
2023.4.6——0.1.4
- Java AES模块由类调用改为示例调用
- Python AES模块由类调用改为示例调用
- 补充了Java项目依赖关系
-
2023.4.5——0.1.3
- Python System模块新增Java Python byte数组转换
- Java System模块新增Java Python byte数组转换
-
2023.03.27——0.1.2
- Java新增System_Utils模块
-
2023.03.16——0.1.1
- Java优化了IO模块,支持追加写入
-
2023.03.13——0.1.0
- Java新增Datetime_Utils时间模块
-
2023.02.01——0.0.9
- Python新增时间模块
-
2023.01.14——0.0.8
- Python更新了System模块
- Python正在新增Windows注册表模块
-
2023.01.03——0.0.7
- Python更新了System模块
-
2022.08.31——0.0.6
- 更新了Java的RSA模块,支持PKCS1(已集成第三方依赖到项目中)和PKCS8
-
2022.08.19——0.0.5
- Python添加了二维码模块、PDF模块、图像处理模块、Excel模块、网络相关模块
-
2022.08.18——0.0.4
- 新增RSA模块
- 对接了Python和Java的AES模块
- 优化了AES模块
-
2022.08.10——0.0.3
- 添加了Python终端彩色字体输出
- 添加了Python系统信息模块
-
2022.08.08——0.0.2
- 添加了Java AES
-
2022.08.07——0.0.1
- 初始化仓库