Yes, as stated in the emergency recovery these are the files containing the backups. backup-headers contains some metadata like compression algorithm used, this is not normal it’s not there.
Ideally, treat your backup as compromised when recovering them.
If neither backup-header nor backup-header.hmac exist it’s going to be tricky to recover the backed up data even manually, because those files contain the backup-id which is part of the low-level scrypt passphrase (not the same as the high-level backup passphrase).
The backup-id seems brute forceable though, as it consists of a second-resolution timestamp (should be in the 20 or so seconds leading up to the mtime of qubes.xml.000.enc) and a PID. One scrypt attempt takes around 3 seconds on my system, so… a few days/weeks/months maybe? Mostly depending on the PID range. I just tried a backup after two weeks of uptime, and the PID was near 100,000.
I don’t need to know which vm corresponds to which name. I just need to unlock all vms and take out the key data. Then not knowing the backup-header will not affect it.
Doing that requires a piece of information (the backup-id) that is inside backup-header or backup-header.hmac. You cannot decrypt the VM storage data without getting this backup-id somehow.
OMG, it seems that I need to traverse. It seems that backup-id is composed of a date and a string of numbers. Do I need to select a minimum vm data file to traverse?
I performed a test and generated a backup-id = 20250117T214120-2878, where 202501172141 seems to be the time when the backup file was generated. I have this exact date, but I don’t have 20-2878. If this - is fixed in this position, I only need to use the script to automatically try the remaining six digits to unlock the backup?
The part after the dash (the process ID) isn’t necessarily 4 digits long. It’s a number between 2 and /proc/sys/kernel/pid_max (4194304, although more likely something in the 3 to 6 digit range)
The part before the dash is an ISO 8601 timestamp. Take the modification time (the stat command will print it with second resolution) of the extracted qubes.xml.000.enc as the maximum value, and maybe 20 seconds less then that as the minimum value. You might want to do a couple backups first (on the same hardware as the damaged backup) and e.g. if you see that there’s usually a delay of 7 - 15 seconds, prioritize that timestamp range in your brute force script.
Thank you for your reply, you helped me narrow down the scope. It’s strange that there is no backup-header in the backup file generated by qubes os 4.23. Fortunately, I didn’t suffer any property loss, but many of my PGP private keys suffered catastrophic losses (including another account of one of my qubes community). I hope everyone can make backups in time and prevent the backups from being damaged (this way I can reduce the time I spend online and protect my eyes)
It’s definitely very weird if backup-header and backup-header.hmac are both missing. I’ve never heard of that. Does tar print any errors on extracting the backup file?