mirror of
https://github.com/volatilityfoundation/volatility3.git
synced 2026-09-12 12:47:39 +02:00
comply with xdg base directory spec by using XDG_CACHE_HOME if its set
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
Stores all the constant values that are generally fixed throughout
|
||||
volatility This includes default scanning block sizes, etc.
|
||||
"""
|
||||
|
||||
import enum
|
||||
import os.path
|
||||
import sys
|
||||
@@ -65,7 +66,10 @@ LOGLEVEL_VVV = 7
|
||||
LOGLEVEL_VVVV = 6
|
||||
"""Logging level for four levels of detail: -vvvvvv"""
|
||||
|
||||
CACHE_PATH = os.path.join(os.path.expanduser("~"), ".cache", "volatility3")
|
||||
|
||||
CACHE_PATH = os.path.join(
|
||||
os.environ.get("XDG_CACHE_HOME") or os.path.expanduser("~/.cache"), "volatility3"
|
||||
)
|
||||
"""Default path to store cached data"""
|
||||
|
||||
SQLITE_CACHE_PERIOD = "-3 days"
|
||||
|
||||
Reference in New Issue
Block a user