Bug 750880 - Why is deltacloud using /tmp? This is for user accounts, it should use /var/run/deltacloud-mock-nobody
Summary: Why is deltacloud using /tmp? This is for user accounts, it should use /var/...
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: deltacloud-core
Version: 19
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Michal Fojtik
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-11-02 16:30 UTC by Daniel Walsh
Modified: 2015-02-18 13:38 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-18 13:38:37 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Daniel Walsh 2011-11-02 16:30:47 UTC
Having privileged process using /tmp is dangerous

Unpriv users could get priv escalation.

Comment 1 Michal Fojtik 2011-11-03 08:24:44 UTC
Could you give me an example where Deltacloud is trying to store something in /tmp? AFAIK the only driver we have that actually 'store' something is Mock driver and it should use /var/tmp instead of /tmp. Also in /var/tmp the files created by the Mock driver should have user set to user who run Deltacloud.

Comment 2 Daniel Walsh 2011-11-03 15:02:33 UTC
I see files in /var/tmp and I don't beleive I ever ran any deltacloud apps as non root, I also see the ownership on these files as owned by nobody. UID=99?

Comment 3 Michal Fojtik 2011-11-04 15:32:38 UTC
Yes, that files was copied there by deltacloud-core RPM as the default 'mock' driver fixtures.
Since Deltacloud API should be run as user 'nobody' by default the files also need to be owned by user 'nobody' in order to work with them.

Comment 4 Steve Grubb 2011-11-04 16:10:23 UTC
The user account nobody is sort of a shared account. Meaning people used it for dropping privs rather than doing the right thing and asking for a real account. If this needs to be secure, I would ask for an assigned UID and not use nobody.

I don't know what it would be doing in any kind of temp dir. But they are normally required to be mounted noexec,nosuid,nodev for compliance reasons. If that is a problem, I'd get something under /var/run/ or another /var directory

Comment 5 Daniel Walsh 2011-11-04 18:03:08 UTC
The point being that deltacloud is not a user, it is a service.  services should use /var/run for temporary storage and /var/lib for permanant storage.

/tmp and /var/tmp is for real users.  The only time a system service should use these directories is if they have to interact with real users, otherwise you are just opening your system service to potential security risk, when there is no reason for it.

Comment 6 Michal Fojtik 2011-11-07 10:32:52 UTC
(In reply to comment #5)
> The point being that deltacloud is not a user, it is a service.  services
> should use /var/run for temporary storage and /var/lib for permanant storage.
> 
> /tmp and /var/tmp is for real users.  The only time a system service should use
> these directories is if they have to interact with real users, otherwise you
> are just opening your system service to potential security risk, when there is
> no reason for it.

Huh, thanks for this informations Daniel. I'll update deltacloud mock driver to use /var/lib instead of /var/tmp. This mock fixtures are kind of persistence layer for mock yaml files used in our 'fake' cloud provider.

Comment 7 Daniel Walsh 2011-11-07 17:04:17 UTC
Ok also make sure the /var/lib/DIRNAME is in the pay load.  And then we can setup proper labelling for this directory.

Comment 8 Fedora End Of Life 2013-04-03 19:33:08 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 19 development cycle.
Changing version to '19'.

(As we did not run this process for some time, it could affect also pre-Fedora 19 development
cycle bugs. We are very sorry. It will help us with cleanup during Fedora 19 End Of Life. Thank you.)

More information and reason for this action is here:
https://fedoraproject.org/wiki/BugZappers/HouseKeeping/Fedora19

Comment 9 Fedora End Of Life 2015-01-09 21:53:44 UTC
This message is a notice that Fedora 19 is now at end of life. Fedora 
has stopped maintaining and issuing updates for Fedora 19. It is 
Fedora's policy to close all bug reports from releases that are no 
longer maintained. Approximately 4 (four) weeks from now this bug will
be closed as EOL if it remains open with a Fedora 'version' of '19'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora 19 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 10 Fedora End Of Life 2015-02-18 13:38:37 UTC
Fedora 19 changed to end-of-life (EOL) status on 2015-01-06. Fedora 19 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.