Friday, July 13, 2007

Re: [BLUG] Unix conventions for controlling file access

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Brian Wheeler wrote:

>> Corrupted how?

I'm sure the sky is the limit. It's a file like any other that's had its
metadata removed from the directory no? Sounds like a bad idea in general.
To each their own obviously.

- -Dave

- --

| Dave Monnier - dmonnier@ren-isac.net |
|

http://nicholas.ren-isac.net/dmonnier/

|
| Principal Security Engineer, REN-ISAC http://www.ren-isac.net/ |
| 24x7 Watch Desk: +1(317)278-6630, ren-isac@ren-isac.net |

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGl6CkBIf6jlONJjIRAqZZAKDHnc72LZ3sj3QInYGm7X2vwsOH+wCfdGQ7
pZ/dOV/pk6mmuSRz10PaI80=
=rah5
-----END PGP SIGNATURE-----
_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Unix conventions for controlling file access

On Fri, 2007-07-13 at 11:29 -0400, Dave Monnier REN-ISAC wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Mark Krenz wrote:
> > I'm curious to get opinions on this. I'm working with some support
> > technicians for a software company that shall remain nameless for now.
> >
> > Anyways, a problem came up where temporary files are being written to
> > /tmp by a program and then showing up in the output of lsof as
> > (deleted). When talking with the support people about this, they said
> > that their method of controlling access to these files is to create
> > them, then unlink the file while the program is still running. This
> > makes the entry disappear from the directory listing. The program
> > should still be able to access the file when the filehandle is open, but
> > for the most part other programs cannot access it.
> >
> > What do you think about this?
> >
>
> Sounds like tomfoolery to me. I'd say this qualifies as another act of
> security theater. I wonder why they would go for this card trick over using
> actual access control methods.
>

Well, access controls aside, it is useful for temporary data that you
definitely want to go away after the process stops. And since multiple
processes can inherit file descriptors, children of the process that
opened it can all access it, but others cannot.

> This also sounds like a great way to have their file corrupted.
>

Corrupted how? Its a file like any other, except the inode has a
reference count of 0 (+ the open process(es) using it) so its not in any
danger of being overwritten by other filesystem activity.


Brian


> - -Dave
> - --
>
> | Dave Monnier - dmonnier@ren-isac.net |
> |

http://nicholas.ren-isac.net/dmonnier/

|
> | Principal Security Engineer, REN-ISAC http://www.ren-isac.net/ |
> | 24x7 Watch Desk: +1(317)278-6630, ren-isac@ren-isac.net |
>
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.6 (GNU/Linux)
>
> iD8DBQFGl5pMBIf6jlONJjIRAlwsAJ4zBR9PvUCt1plMLZ8Bsn/f2C+O6gCeLXIA
> U+0VBgeKa20Iyztn6i3E/hI=
> =UxI6
> -----END PGP SIGNATURE-----
> _______________________________________________
> BLUG mailing list
> BLUG@linuxfan.com
> http://mailman.cs.indiana.edu/mailman/listinfo/blug

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Unix conventions for controlling file access

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark Krenz wrote:
> I'm curious to get opinions on this. I'm working with some support
> technicians for a software company that shall remain nameless for now.
>
> Anyways, a problem came up where temporary files are being written to
> /tmp by a program and then showing up in the output of lsof as
> (deleted). When talking with the support people about this, they said
> that their method of controlling access to these files is to create
> them, then unlink the file while the program is still running. This
> makes the entry disappear from the directory listing. The program
> should still be able to access the file when the filehandle is open, but
> for the most part other programs cannot access it.
>
> What do you think about this?
>

Sounds like tomfoolery to me. I'd say this qualifies as another act of
security theater. I wonder why they would go for this card trick over using
actual access control methods.

This also sounds like a great way to have their file corrupted.

- -Dave
- --

| Dave Monnier - dmonnier@ren-isac.net |
|

http://nicholas.ren-isac.net/dmonnier/

|
| Principal Security Engineer, REN-ISAC http://www.ren-isac.net/ |
| 24x7 Watch Desk: +1(317)278-6630, ren-isac@ren-isac.net |

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFGl5pMBIf6jlONJjIRAlwsAJ4zBR9PvUCt1plMLZ8Bsn/f2C+O6gCeLXIA
U+0VBgeKa20Iyztn6i3E/hI=
=UxI6
-----END PGP SIGNATURE-----
_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Unix conventions for controlling file access

On Fri, 2007-07-13 at 15:13 +0000, Mark Krenz wrote:
> I'm curious to get opinions on this. I'm working with some support
> technicians for a software company that shall remain nameless for now.
>
> Anyways, a problem came up where temporary files are being written to
> /tmp by a program and then showing up in the output of lsof as
> (deleted). When talking with the support people about this, they said
> that their method of controlling access to these files is to create
> them, then unlink the file while the program is still running. This
> makes the entry disappear from the directory listing. The program
> should still be able to access the file when the filehandle is open, but
> for the most part other programs cannot access it.
>
> What do you think about this?
>

Its not unheard of, though it is a bit annoying if you're trying to
figure out who is sucking up all the disk. The advantage to do it this
way is there is no other way to easily open the file (There's an ioctl()
call using I_OPEN which might do it) and it is automatically dallocated
when the application shuts down (regardless if its a nice shutdown or
not).

Brian

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

[BLUG] Unix conventions for controlling file access

I'm curious to get opinions on this. I'm working with some support
technicians for a software company that shall remain nameless for now.

Anyways, a problem came up where temporary files are being written to
/tmp by a program and then showing up in the output of lsof as
(deleted). When talking with the support people about this, they said
that their method of controlling access to these files is to create
them, then unlink the file while the program is still running. This
makes the entry disappear from the directory listing. The program
should still be able to access the file when the filehandle is open, but
for the most part other programs cannot access it.

What do you think about this?

--
Mark Krenz
Bloomington Linux Users Group
http://www.bloomingtonlinux.org/
_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Tuesday, July 10, 2007

[BLUG] Meeting tonight

Look forward to the meeting tonight, see you all there. -Chris Walker
_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug

Re: [BLUG] Meeting tonight?

Work calls so I will not be able to make it tonite...and I could use some
ideas for dressing up the new laptop.

Let me know how it goes.

Thank you,
Scott Blaydes

On Tue, 10 Jul 2007 15:07:53 -0400, Steven Black wrote
> Ana:
>
> The presentation will go ahead regardless of whether there is a projector.
>
> Without a projector, people just get to hear me lecture. Don't bother
> taking notes, just sit back and know that all the good stuff will be
> available online. (*)
>
> Cheers,
> Steven Black
>
> (*) People should still try to make it to the meeting, if possible.
>
> On Tue, Jul 10, 2007 at 01:29:19PM -0400, Pawsitive Results wrote:
> > Is the projector situation under control? I'm not sure I'll make it
> > tonight (although I plan to try!)
> >
> > Ana
> >
> > On 7/10/07, Steven Black < [1]blacks@indiana.edu> wrote:
> >
> > Mark: We hope you can make it to the meeting.
> >
> > The meeting is at 7pm at the Monroe County Library in room 1B.
> >
> > I will be giving a presentation on "Easy and Effective Theming".
> > Specifically covering theming from startup on.
> >
> > Included will be:
> > * GRUB background images
> > * Usplash themes (*)
> > * GDM themes
> > * Screen savers
> > * System icons
> >
> > With the broad topic, I'll be covering a lot of ground. There will be a
> > link
> > on the website < [2]http://www.bloomingtonlinux.org/> for this meeting
> > <[3]http://www.bloomingtonlinux.org/wiki/32nd_meeting > which will
> > include a
> > link to a 5.3 page paper (plus references/links).
> >
> > (*) Usplash was created for Ubuntu. I know it is a little distribution
> > specific, but it is a popular distribution (and I use it). Included in
> > the paper are comments about the differences of Usplash to alternatives
> > like Bootsplash and Gensplash, as well as links to information to
> > create themes for those.
> >
> > Cheers,
> > Steven Black
> >
> > _______________________________________________
> > BLUG mailing list
> > [4]BLUG@linuxfan.com
> > [5]http://mailman.cs.indiana.edu/mailman/listinfo/blug
> >
> > References
> >
> > Visible links
> > 1. mailto:blacks@indiana.edu
> > 2. http://www.bloomingtonlinux.org/
> > 3. http://www.bloomingtonlinux.org/wiki/32nd_meeting
> > 4. mailto:BLUG@linuxfan.com
> > 5. http://mailman.cs.indiana.edu/mailman/listinfo/blug
> _______________________________________________
> BLUG mailing list
> BLUG@linuxfan.com
> http://mailman.cs.indiana.edu/mailman/listinfo/blug


--
Scott Blaydes
pgp/gpg key avaliable upon request.

_______________________________________________
BLUG mailing list
BLUG@linuxfan.com
http://mailman.cs.indiana.edu/mailman/listinfo/blug