I would like to analyze the default Chrome data location with Hindsight for every user on the system (Windows). The string concatenation for default_directory works. But my two variables (default_directory and user) in the loop are not working. I'm writing a script for using the Carbon Black API.
for user in users_list:
try:
default_directory = os.path.normpath('C:\\Users\\' + user + '\\AppData\\Local\\Google\\Chrome\\User Data\\Default') # String concatenation
session.create_process(r'C:\\Windows\\cbapi\\hindsight.exe -i "{default_directory}" -o "hindsight_{user}"', wait_timeout=600)
except Exception: pass
Thank you in advance for your assistance!