SecurityRonin/timeglyph

GitHub: SecurityRonin/timeglyph

一款取证时间戳解读工具,针对未知的时间戳数值给出带有评分和引证的多种可能解释,而非单一结论。

Stars: 0 | Forks: 0

# timeglyph [![Crates.io](https://img.shields.io/crates/v/timeglyph.svg)](https://crates.io/crates/timeglyph) [![Docs.rs](https://img.shields.io/docsrs/timeglyph)](https://docs.rs/timeglyph) [![License: Apache-2.0](https://img.shields.io/badge/License-Apache_2.0-blue.svg)](LICENSE) [![CI](https://static.pigsec.cn/wp-content/uploads/repos/cas/ad/ad5834178f7599af9fdda11629d49cae07f2997beec49821b2920eff5bfd50e7.svg)](https://github.com/SecurityRonin/timeglyph/actions/workflows/ci.yml) [![Release](https://static.pigsec.cn/wp-content/uploads/repos/cas/42/42ba98a60a0bb3b0ad908f024db145f9c5b831eb7df822f56ac578ee7d7215b3.svg)](https://github.com/SecurityRonin/timeglyph/releases) [![Sponsor](https://img.shields.io/badge/sponsor-h4x0r-ea4aaa?logo=github-sponsors)](https://github.com/sponsors/h4x0r) **取证时间戳解密** — 解码、编码并*识别*系统记录时间的多种方式, 提供带有评分、引证、歧义优先解释的功能。 时间戳是记录为符号的时间 —— 即系统写入的用于表示某一时刻的原始整数或字节。`timeglyph` 用于解密这些记录。给定一个*未知*值,它会报告**每一种合理的解释,并附带排名、评分及其假设** —— 绝不会给出单一的“检测到的”答案,因为原始值通常是模糊的。 ``` $ timeglyph 1577836800 # 与 1577836800 一致的 readings(已排序;raw value 通常是不确定的 —— 并非单一 verdict): [1.00] unix 2020-01-01T00:00:00Z (Unix time (seconds)) [0.94] postgres 2000-01-01T00:26:17.8368Z (PostgreSQL timestamp (µs since 2000)) [0.67] cocoa 2051-01-01T00:00:00Z (Cocoa / CFAbsoluteTime (s since 2001)) [0.67] hfsplus 1953-12-31T00:00:00Z (Apple HFS+ (s since 1904)) ... $ timeglyph identify --json 1577836800 # machine-readable ranked candidates $ timeglyph decode filetime 132223104000000000 $ timeglyph encode unix 2020-01-01T00:00:00Z $ timeglyph hex 0060947C58B2D501 # raw bytes (LE/BE + packed on-disk) $ timeglyph string 20200101000000Z # ISO / RFC / ASN.1 string forms $ timeglyph csv events.csv # enrich a CSV: human-readable timestamp columns $ timeglyph list # the format registry, with spec citations ``` 退出代码是 pipeline 安全的:`0` 表示明确的最佳解读,`2` 表示存在歧义或为哨兵值(需要人工复核),`1` 表示错误。 ## 状态 引擎运行正常。`PosixNs(i128)` 核心、解码/编码/自动检测/字节解码、基于组件的合理性评分,以及认识论框架(一致性 + 闰秒平滑)均已实现,并针对主要规范锚点进行了测试。注册表涵盖 Unix s/ms/µs/ns、FILETIME、WebKit/Chrome、Cocoa(整数和有符号双精度)、HFS+、.NET ticks、OLE、PostgreSQL、SQLite Julian day、Snowflake IDs(Twitter/X、Discord)以及 FAT/DOS 打包的本地时间。支持闰秒的 GPS/TAI64/NTP 系列已在 `leap` 特性(`decode gps|tai64|ntp`,通过 `hifitime` 进行闰秒修正 UTC)下实现。剩余的构建工作(更多打包/字符串形式,发行版) —— 请参阅 **[HANDOFF.md](HANDOFF.md)** 了解设计记录和计划。 ## 为什么还要另一个转换器? 老实说:已经有很好的工具了([`time_decode`](https://github.com/digitalsleuth/time_decode), MIT;DCode,专有)。`timeglyph` 并不是“第一个” —— 它是一个 Rust 单一静态二进制文件,也是一个**严谨的、有引证的模型**,在这里解读是一种*证据*,而不是定论:一个 POSIX 正确的内部核心(绝不会被误标为 UTC),闰秒系列被单独分开,并且**将歧义作为一等公民的评分输出**。日历/时区计算复用了(`jiff`),从不重新发明;支持闰秒的系列将委托给 `hifitime`。 [隐私政策](https://securityronin.github.io/timeglyph/privacy/) · [服务条款](https://securityronin.github.io/timeglyph/terms/) · © 2026 Security Ronin Ltd
标签:Rust, 可视化界面, 数字取证, 数据解码, 时间戳, 网络流量审计, 自动化脚本, 通知系统