Properly remove bad profile dir #435

Merged
dan merged 2 commits from import_export into master 2022-03-09 23:58:37 +00:00
Owner
No description provided.
sarah added 1 commit 2022-03-09 22:33:14 +00:00
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/pr Build is passing Details
bf4cca631c
Properly remove bad profile dir
Member
Drone Build Status: failure https://build.openprivacy.ca/cwtch.im/cwtch/735
Member
Drone Build Status: success https://build.openprivacy.ca/cwtch.im/cwtch/736
dan reviewed 2022-03-09 23:47:57 +00:00
@ -193,2 +193,3 @@
// Otherwise purge
os.RemoveAll(filepath.Join(profilesDir, profileDir))
log.Errorf("error importing profile: %v. removing %s", err, profileDir)
os.RemoveAll(profileDir)
Owner

is it possible a malicious profile tarball could be constructed with a "id" / directory named '..' or something that on import and failure it trigers a deletion of the profiles directory or worse?

is it possible a malicious profile tarball could be constructed with a "id" / directory named '..' or something that on import and failure it trigers a deletion of the profiles directory or worse?
dan marked this conversation as resolved
sarah added 1 commit 2022-03-09 23:52:36 +00:00
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/pr Build is passing Details
ff91300c39
Adding extra checks to import tarball profile name
dan merged commit 9e506e5190 into master 2022-03-09 23:58:37 +00:00
Member
Drone Build Status: success https://build.openprivacy.ca/cwtch.im/cwtch/738
Sign in to join this conversation.
No description provided.