Linux Shell 程式設計與管理實務讀者釋疑
三 11 九月 2024 by ols3Linux Shell 程式設計與管理實務 p159 範例6-5-1:
# 範例6-5-1
#
# 用途: 找出 /etc 目錄中最新的檔案,符號連結檔不計入。
#
#
#! /bin/bash
unset -v newfile
for f in /etc/*; do
[ -f $f -a ! -L $f ] && # [ ] 代表條件判斷,
# -f $f : 若 $f 檔案存在,
# -a : 且
# ! -L $f : 該檔案不是符號連結檔
[[ $f -nt $newfile ]] && # 比較檔案時間
newfile=$f # 只記錄較新的檔案
done
echo "最新的檔案是: $newfile"
執行結果: 最新的檔案是: /etc/mailcap
ls -la /etc/mailcap
-rw-r--r-- 1 root root 106597 9月 11 07:29 /etc/mailcap (2024/09/11 AM 07:29)
OpenSSH 可移植版-遠端代碼競行漏洞
sshd(8) in Portable OpenSSH versions 8.5p1 to 9.7p1 (inclusive). Race condition resulting in potential remote code execution. A race condition in sshd(8) could allow remote code execution as root on non-OpenBSD systems. This attack could be prevented by disabling the login grace timeout (LoginGraceTime …
read morexz-utils 植入後門 (CVE-2024-3094)
xz-utils: backdoor in upstream xz/liblzma leading to ssh server compromise
Malicious code was discovered in the upstream tarballs of xz, starting with version 5.6.0. Through a series of complex obfuscations, the liblzma build process extracts a prebuilt object file from a disguised test file existing …
read more白宮敦促開發人員放棄 C 和 C++
純文字簡報工具 sent
OpenSSH 9.6 (2023/12/18)
OpenSSH 9.6 釋出,修正 SSH 傳輸協定的缺陷,避免 Terrapin 攻擊(MITM 中間人水龜攻擊):
當客戶端和伺服器都支援時,OpenSSH 9.6 新的「嚴格 KEX」協定 …
read moreQuod Libet
Quod Libet 是一個用 Python 編寫的基於GTK+的音訊播放器,使用Mutagen標記庫。它的設計理念是使用者更了解如何組織音樂。它可以讓您根據正規 …
read more物盡其用,Intel G3420 邁入第十個年頭
Geany IDE 獨立免安裝 AppImage
Geany 2.0.0 AppImage 釋出 ...
Geany 是一款功能強大、穩定且輕量級的程式設計編輯器,我把它包成一個獨立可執行的 AppImage,完全免安裝。
- 支援 …
uemacs 的加密功能
uemacs 的加密功能:
/* CRYPT.C
*
* Encryption routines
*
* written by Dana Hoggatt and Daniel Lawrence
*/
#include <stdio.h>
#include "estruct.h"
#include "edef.h"
#include "efunc.h"
#if CRYPT
static int mod95(int);
/*
* reset encryption key of current buffer
*
* int f; default flag
* int n; numeric argument
*/
int …
uemacs 中文可用版 4.0.15.1 tw
我是重度的 Emacs 編輯器的使用者, 過去出版的書籍全都是在 Emacs 中完成的; 但 Emacs 太厚重, 在遠端跨主機工作不方便, 輕便的 uemacs 便 …
read moreAES 加解密器
- v1.0.4.1 : 加解密速度快 4 倍、強化記憶體配置。
- v1.0.4.0 : 新增 Salt '鹽巴調味' 功能,讓暴力破解、字典攻擊、彩虹表攻擊更困難。
- 主 …
X3BL 簡易 HTTPS Server v1.0.1
X3BL 簡易 HTTPS Server v1.0.1:
- 高擴展性:可以輕鬆處理數萬個連接
- 支援 Let's Encrypt TLS 憑證
壓力測試: (由慢速的學術網路連入)
Running …
適用於 Windows 的 GCC/MinGW-w64 獨立編譯器
WinLibs : 適用於 Microsoft Windows 的免費 C 和 C++ 編譯器。
GCC(GNU 編譯器集合)是一個免費的開源編譯器,適用於 C 和 C++(以及 Objective-C、Fortran、D 等其他語言)。 MinGW-w64是一個免費開源 …
read more