Skip to main content

sniff

Function sniff 

Source
pub fn sniff(path: &str) -> Result<&'static str>
Expand description

语义(继承 KB 现网经验):

  • OOXML 若文件头是 OLE 容器 → 加密件,归 encrypted;
  • legacy(doc/ppt/xls)期望 OLE,不是 OLE → unsupported(伪装);
  • 其余按头/magic 兜底。