public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] implementing fchown & fchmod
@ 2003-12-04  9:14 Vincent Catros
  2003-12-04 11:31 ` Nick Garnett
  0 siblings, 1 reply; 2+ messages in thread
From: Vincent Catros @ 2003-12-04  9:14 UTC (permalink / raw)
  To: ecos-discuss

Hello,

In order to provide some file access control I would like to set and
retreave "uid", "gid" and "mode".

It seems that apropriate functions are :
- fchown & fchmod to set those parameters.
- fstat to reatreve those parameters.

Unfortunatly, fchown and fchmod are not implemented with eCos.

So, I plan to do it.

My question is :

How to change "uid", "gid" and "mode" at file system level?

AFAIK, I need setattr function to be exported by the file system (which
is not the case for the moment).
Is it true or is there an other way?

Regards.

Vincent


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [ECOS] implementing fchown & fchmod
  2003-12-04  9:14 [ECOS] implementing fchown & fchmod Vincent Catros
@ 2003-12-04 11:31 ` Nick Garnett
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Garnett @ 2003-12-04 11:31 UTC (permalink / raw)
  To: Vincent Catros; +Cc: ecos-discuss

"Vincent Catros" <Vincent.Catros@elios-informatique.fr> writes:

> Hello,
> 
> In order to provide some file access control I would like to set and
> retreave "uid", "gid" and "mode".
> 
> It seems that apropriate functions are :
> - fchown & fchmod to set those parameters.
> - fstat to reatreve those parameters.
> 
> Unfortunatly, fchown and fchmod are not implemented with eCos.

The first question is why do you want to do this? eCos does not have
any other forms of protection of security and any use of uid/gid etc
would be totally pointless. What exactly do you need this for? And
which filesystem are you using this on?

> 
> So, I plan to do it.
> 
> My question is :
> 
> How to change "uid", "gid" and "mode" at file system level?
> 
> AFAIK, I need setattr function to be exported by the file system (which
> is not the case for the moment).
> Is it true or is there an other way?

The getinfo() and setinfo() functions exist for adding these sorts of
operations. Just add the appropriate keys and data structures to
fileio.h and you're away.

-- 
Nick Garnett                    eCos Kernel Architect
http://www.ecoscentric.com      The eCos and RedBoot experts


-- 
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-12-04 11:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-04  9:14 [ECOS] implementing fchown & fchmod Vincent Catros
2003-12-04 11:31 ` Nick Garnett

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).