Open nathang21 opened 5 months ago
sorry it took me a while to get back. You're right, this is a a relatively arbitrary limitation in the script, mostly just because of how its written. The easiest way to work around this would be to edit the archive manually:
I'll see about adding a commandline arg to limit it to interacting with a subset of the archives inside it.
Just trying to restore a backup with a password made by HA 2024.1 Is this tool still working ?
It looks like they changed the backup format a little bit, and I'm having trouble getting HA to import encrypted backups that even it makes. I'll fix this when I'm able to dedicate some time to sort out whats goign wrong here.
Having the same problem as mentioned here. Just for information. :) no pressure.
When I rearrange the tar file structure, I can use decrypt-ha-backup without any issue...
Ah sorry, i wanted to post in #1 , I'm getting the same problem with "invalid header". i think the problem there could be the used password with special characters. backups without password war just fine.
When I rearrange the tar file structure, I can use decrypt-ha-backup without any issue...
I'm running in the same issue, but I don't understand what you were rearranging to get things to work. Could you elaborate?
ah, now I get it, it's the leading ./
that's the problem.
diff --git a/decrypt-ha-backup/__main__.py b/decrypt-ha-backup/__main__.py
index 7ed4110..c24f16a 100644
--- a/decrypt-ha-backup/__main__.py
+++ b/decrypt-ha-backup/__main__.py
@@ -128,7 +128,7 @@ class BackupItem:
@property
def fileName(self):
ext = ".tar.gz" if self._backup.compressed else ".tar"
- return f"./{self._slug.replace('/', '_')}{ext}"
+ return f"{self._slug.replace('/', '_')}{ext}"
@property
def slug(self):
is the code change that gets things to work for me without futzing with my archive.
I'm getting this error when trying to extract/decrypt, however I confirmed that the
cebe7a76_hassio_google_drive_backup.tar.gz
file is present in the.tar
archive, as well as in thebackup.json
(see attached). backup.jsonI only want to recover part of the files from this backup, but I haven't found a workaround.
I looked at #1 and confirmed I am able to open the root .tar file without issue, and can see all the
.tar.gz
files, but can not decrypt any of them. Is it possible to decrypt only one of these subfolders/archives? The utility as designed currently only appears to work on the root archive.