Bug #15430

live-additional-software.conf is given wrong permissions when it's updated by tails-additional-software

Added by bertagaz 2018-03-20 23:44:39 . Updated 2018-04-05 17:55:02 .

Status:
Resolved
Priority:
Normal
Assignee:
alant
Category:
Target version:
Start date:
2018-03-20
Due date:
% Done:

100%

Feature Branch:
Type of work:
Code
Blueprint:

Starter:
Affected tool:
Additional Software Packages
Deliverable for:
299

Description

With an ISO build with commit:8dd945efef3e4f47f11742862cf34b098ae42cc2

  • Boot from USB with network and admin password with no configured persistent storage
  • Install a package with APT
  • Confirm you want to create the persistent storage
  • Enter passphrases and confirm
  • Wait for t-p-s to finish and close it

/media/tails-persistence-setup/TailsData/live-additional-software.conf is 0600

live-persist rightfully detects it’s not 0644 on next boot and disable ASP.


Subtasks


History

#1 Updated by bertagaz 2018-03-20 23:46:04

#2 Updated by intrigeri 2018-03-21 10:22:15

> /media/tails-persistence-setup/TailsData/live-additional-software.conf is 0600

Strange, config/chroot_local-patches/tps-14594-asp-gui.diff has code to make it 0644. I’ll take a look today or tomorrow!

#3 Updated by bertagaz 2018-03-21 10:45:36

intrigeri wrote:
> > /media/tails-persistence-setup/TailsData/live-additional-software.conf is 0600
>
> Strange, config/chroot_local-patches/tps-14594-asp-gui.diff has code to make it 0644. I’ll take a look today or tomorrow!

Yesh, that’s why I’ve set this ticket as new. I’m not quite sure of what’s is happening, and I’m surprised given what I vaguely understand from the t-p-s patch, so I wonder if I’m messing up. But I have this failure with the automated test and I can reproduce it by hand.

#4 Updated by intrigeri 2018-03-21 15:44:16

  • Subject changed from T-p-s does not create live-additional-software.conf with the right permissions to live-additional-software.conf is given wrong permissions when it's updated by tails-additional-software
  • Status changed from New to Confirmed
  • Assignee changed from intrigeri to alant

I’ve reproduced this but I believe that t-p-s is not at fault: if I create a persistent storage with t-p-s, the file has correct permissions (0644). So I’m inclined to blame additionalsoftware/config.py’s _write_config in our Python library. Feel free to reassign to me if you see that the permissions are wrong after t-p-s exits but before your code touches the file.

#5 Updated by intrigeri 2018-03-22 09:50:48

#6 Updated by alant 2018-03-25 20:58:03

intrigeri wrote:
> So I’m inclined to blame additionalsoftware/config.py’s _write_config in our Python library.

You’re right. This should be fixed by commit 6b8f5d6.

#7 Updated by alant 2018-03-25 22:11:54

  • Status changed from Confirmed to In Progress
  • % Done changed from 0 to 50
  • QA Check set to Ready for QA

#8 Updated by bertagaz 2018-04-03 13:03:15

According to the test suite, this is fixed. I was able to remove the workaround there was about this bug and have the test suite still passing.

#9 Updated by alant 2018-04-05 17:55:02

  • Status changed from In Progress to Resolved
  • % Done changed from 50 to 100
  • QA Check changed from Ready for QA to Pass