Linux-Development-Sys Digest #339, Volume #6 Thu, 28 Jan 99 02:13:57 EST
Contents:
Re: sendmail-8.9.2 claims that "seteuid" is broken - True? (Waldek Hebisch)
LINKER PROBLEM (INTERACTIVE - SCO - LINUX) ("Robert")
Re: - deprecated - why? (Matthew Hannigan)
Re: Why I'm dumping Linux, going back to Windblows (Leslie Mikesell)
How do you dynamically pass port addresses to a device driver? (Ken Sills)
Re: Modest next goal for Linux (David T. Blake)
Shared memory weirdness (Matthew D Allen)
ipchains and syslog (Johan Kullstam)
Re: sendmail-8.9.2 claims that "seteuid" is broken - True? (Olav Woelfelschneider)
Re: How do you dynamically pass port addresses to a device driver? (Olav
Woelfelschneider)
Re: Root RAID different from Boot RAID? and other RAID issues (Bennett Todd)
Re: Parallel C for Linux (Loren Osborn)
Re: How can I build a Linux system from scratch - NO distribution? (Richard Jones)
Re: getting notified on file change? (Richard Jones)
Forcing FAT-like behaviour on the ext2fs ([EMAIL PROTECTED])
----------------------------------------------------------------------------
From: [EMAIL PROTECTED] (Waldek Hebisch)
Subject: Re: sendmail-8.9.2 claims that "seteuid" is broken - True?
Date: 27 Jan 1999 16:47:03 GMT
Chris Rankin (net.bellsouth@{no.spam}rankinc) wrote:
: Villy Kruse wrote:
: > Anyone run the test program to verify that seteuid is still broken?
[Snip]
: $ t_seteuid
: initial uids (should be 500/0): r/euid=500/0
: after seteuid(1) (should be 500/1): r/euid=500/1
: seteuid(0) failure
: after seteuid(0) (should be 500/0): r/euid=500/1
: MAYDAY! Wrong effective uid
According to the seteuid manpage after first call we have
ruid 500 euid 1 and saved uid 1
In the second call we reqest euid 0, different from any
of the real, effective and saved uid, so we should get
EPERM
: seteuid(2) failure
: after seteuid(2) (should be 500/2): r/euid=500/1
: MAYDAY! Wrong effective uid
: seteuid(0) failure
: after seteuid(0) (should be 500/0): r/euid=500/1
: MAYDAY! Wrong effective uid
This second failure has the same reason as the first
: This system cannot use seteuid
: Well that seems to settle that... unless someone has a comment on the
: t_seteuid program itself.
I think that the problem is in seteuid spec, and Linux probably violates
BSD 4.3 spec. Linux behavior allows to
drop root privilleges. Changing this would possibly open security
holes in some programs.
: Cheers,
: Chris.
--
Waldek Hebisch
[EMAIL PROTECTED] or [EMAIL PROTECTED]
------------------------------
From: "Robert" <[EMAIL PROTECTED]>
Crossposted-To: comp.os.linux.development.apps
Subject: LINKER PROBLEM (INTERACTIVE - SCO - LINUX)
Date: Wed, 27 Jan 1999 18:05:42 +0100
I have a C library for INTERACTIVE Unix ver 2.2.1.
When I try to link it on Linux, I get:
could not read symbols: File format not recognized
Robert
P.S. It works just fine on SCO OpenServer 5.0.4
------------------------------
From: [EMAIL PROTECTED] (Matthew Hannigan)
Subject: Re: - deprecated - why?
Date: 28 Jan 1999 02:10:08 GMT
In article <78oa9v$[EMAIL PROTECTED]>,
david parsons <o r c @ p e l l . p o r t l a n d . o r . u s> wrote:
>In article <77k1jk$k0o$[EMAIL PROTECTED]>,
>Frank T. Lofaro <[EMAIL PROTECTED]> wrote:
>
>>What the heck is Unix98, anyway?
>
> The commercial Unix world rolling over and giving the market to
> NT, that's what.
>
>>How is it diffrent than POSIX, X/OPEN, FIPS, etc?
>
> It's *new*, and it's *improved*, and it's *better* because it's
> *new* and *improved*.
>
> ____
> david parsons \bi/ First, we kill all the standards committees.
> \/
Aren't you being a little too cynical?
Conventional wisdom says that Unix has to get standardised
to some extent at least or NT will rule. Your first
sentence seems to carry the opposite view.
Care to explain?
--
-Matt
------------------------------
From: [EMAIL PROTECTED] (Leslie Mikesell)
Crossposted-To: alt.os.linux,comp.os.linux.development.apps,comp.os.linux.setup
Subject: Re: Why I'm dumping Linux, going back to Windblows
Date: 27 Jan 1999 22:29:26 -0600
In article <[EMAIL PROTECTED]>,
Murray Spork <[EMAIL PROTECTED]> wrote:
>OK -- but I'm sure that most unix commands follow Pareto's law -- 20%
>of the options/flags etc. are used 80% of the time and 80% of the
>options are only used 20% of the time.
Perhaps, but the obscure 20% are the ones where people need the
most help... Keep in mind that if you are a beginner and are
having trouble using one system in one way you probably don't
understand the scope of the possibilities and the things that
people commonly do on other kinds of machines with other variations
of unix.
>No -- the rest of the man pages can stay as is with every flag/
>option/ syntax etc described. But a simple example of useage at the
>end greatly helps. Even if the example isn't exactly the one you are
>looking for -- it usually gives you a good clue as to syntax etc. I am
>thinking for example of the "find" command. Until I saw somebody give
>an example of its use on usenet -- I could not figure it out myself
>from the man pages.
You really need to digest the man page for the shell you use before
you worry about command line syntax for any other program, because
with only a few exceptions the syntax is all the same. (dd is an
exception, find is slightly strange because you need to prevent
the shell from parsing certain things).
Les Mikesell
[EMAIL PROTECTED]
------------------------------
From: Ken Sills <[EMAIL PROTECTED]>
Subject: How do you dynamically pass port addresses to a device driver?
Date: Wed, 27 Jan 1999 12:24:25 -0500
I am writing a device driver for a CCD camera (for astronomical
imaging). The CCD interface card is a very simple ISA port i/o card.
This card has 12 registers (base_address + REG_*) that I need to write
to, but which port will be written to varies in such a way that
hard-coding isn't useful. How do I pass the port address to the module
so that my write command puts data on the right address? I'm really
hoping that I don't have to make a device for each register, and then
open up 12 file descriptors in my acquisition program. Do I get around
this by having the port address be a global variable that I set with
ioctl before each write? I find it worrisome that I haven't been able
to find any information about this on the web...am I missing something
fundamental here?
Thanks in advance!
Ken Sills
(to email back, just remove the obvious part of the address)
------------------------------
From: [EMAIL PROTECTED] (David T. Blake)
Crossposted-To: comp.os.linux.advocacy
Subject: Re: Modest next goal for Linux
Date: 27 Jan 1999 08:56:28 -0800
[EMAIL PROTECTED] (bill davidsen) writes:
>Liang-Shing Ng <[EMAIL PROTECTED]> wrote:
>>I think if this problem can be solved, then most of the perceived
>>sluggishness of GTK and KDE (mem hog etc) will be bypassed (if not
>>solved). Then I will be really happy.
>>By the way, I am using an VOP5PC (Very Old Pentium Class Personal
>>Computer) P75 with 24MB ram. Don't laugh. The guanranteed response
>>problem has to be solved, and has to be solved especially on old
>>systems!
>It is solved. Add memory until response improves, then double what you
>have. For X 32MB is adequate if you don't do much, otherwise go to 64MB.
>With memory prices where they are now, no developer will be spending
>time solving a problem most people don't have.
>
>Or can X and just run text.
Or, seek RAM minimal applications and window managers.
Use fvwm, the original version.
Use rxvt instead of xterm.
Don't run a lot of big applications at once, ie: netscape plus
emacs plus gimp = a whole lotta RAM usage.
I've comfortably run X and fvwm in this way on a 486/75 with
28 M RAM (and before that with only 8 M RAM without using
X).
You don't have to use GNOME/KDE, and if you are really RAM
limited, this is a nice alternative.
--
Dave Blake
[EMAIL PROTECTED]
------------------------------
From: [EMAIL PROTECTED] (Matthew D Allen)
Crossposted-To: comp.os.linux.development.apps
Subject: Shared memory weirdness
Date: 27 Jan 1999 12:10:17 -0500
Imagine the following scenario: you have a program that forks off into
several child processes all of which need to communicate with another
process. I'm doing this via shared memory, and how I did it was to put the
pointers to the shared memory in a header file, have everyone include that
file, then in the initialization routine of the program, do the shmget and
the shmat stuff, and finally have two error free pointers - one is a pointer
to an array of pointers, and the other is a pointer to a struct. Both data
types are structs that I made.
When I call a funtion to initialize this, everything is peachy, but for some
reason, no matter what happens, the first time EITHER the child or the parent
tries to touch the data, (not necessarily change, even access) the data gets
reset to some wierd value.
I have say MasterSharedData *MASTER; that pointer points to the shared
memory, ie the return of shmat, and I initialize MASTER->masterID=1; later on
, one of the child processes does this: if(MASTER->masterID==MAXSTACKSIZE){
MASTER->masterID=0; } AS SOON as it tries to access that memory,
MASTER->masterID is set to -1. (??????)
I've reviewed the code and nothing seems to be wrong with it, but the weird
part is that not only is there an error in that MASTER->masterID gets set to
-1 on access, but it's consistant. It's ALWAYS -1 that it gets set to.
(masterID is an int)
Is there anything wrong with forking and using shared memory segments for
coordination? I've considered using semaphores, which I'm not using
currently, but as far as synchronization is concerned, I'm sure that nothing
else is accessing that data when it goes awry. Could it have something to do
with the fact that each child process of a fork gets a copy of all the
varaibles? Still, MASTER should be pointing to the right mem location.
Any suggestions?
David Allen
--
http://members.xoom.com/uruk/index.html - Linux software development
This signature file is $10 shareware. Send in $200 for the full
registered version!
------------------------------
Subject: ipchains and syslog
From: Johan Kullstam <[EMAIL PROTECTED]>
Date: 24 Jan 1999 18:57:01 -0500
i am using an ipchains firewall with my 2.2.0 kernel. i log various
denials, and i get them in /var/log/messages. i do not want these in
/var/log/messages. how would i redirect them to another file, say
/var/log/security?
man, ipchains-howto and dejanews fail to say anything.
--
Johan Kullstam [[EMAIL PROTECTED]] Don't Fear the Penguin!
------------------------------
From: Olav Woelfelschneider <[EMAIL PROTECTED]>
Subject: Re: sendmail-8.9.2 claims that "seteuid" is broken - True?
Date: Wed, 27 Jan 1999 21:14:14 +0100
Waldek Hebisch <[EMAIL PROTECTED]> wrote:
WH> I think that the problem is in seteuid spec, and Linux probably violates
WH> BSD 4.3 spec. Linux behavior allows to
WH> drop root privilleges. Changing this would possibly open security
WH> holes in some programs.
So do I have any chance to switch back and forth between root and non-root
by other means?
--
Olav "Mac" W�lfelschneider [EMAIL PROTECTED]
PGP fingerprint = 06 5F 66 B3 2A AD 7D 2D B7 19 67 3C 95 A7 9D AF
Mer mu� doch nur emol e bissje nochdenke. -- Mundstuhl
------------------------------
From: Olav Woelfelschneider <[EMAIL PROTECTED]>
Subject: Re: How do you dynamically pass port addresses to a device driver?
Date: Wed, 27 Jan 1999 21:21:31 +0100
Ken Sills <[EMAIL PROTECTED]> wrote:
KS> This card has 12 registers (base_address + REG_*) that I need to write
KS> to, but which port will be written to varies in such a way that
KS> hard-coding isn't useful.
Some thoughts:
- Do you really need a driver? A suid root program could just gain
port access at the beginning and then give up root. Further on
the program can use the ports itself. This is practical if your
device is so special that a device driver is overkill. After all,
a context switch to kernel space is expensive, isn't it?
- You could set up an ioctl call which gets the port address and the data
to write as a parameter. Another call could get just an address and
read back data for you.
- Finally you could use seek().
The app uses a seek() call to set the address, then uses read() or
write() to access it. However, in your case where there are only a
few registers, I think this is not practical.
For an example, look at the joystick driver, this one is as simple as a
driver can be.
Maybe you tell us more about your project...
--
Olav "Mac" W�lfelschneider [EMAIL PROTECTED]
PGP fingerprint = 06 5F 66 B3 2A AD 7D 2D B7 19 67 3C 95 A7 9D AF
Mer mu� doch nur emol e bissje nochdenke. -- Mundstuhl
------------------------------
From: [EMAIL PROTECTED] (Bennett Todd)
Subject: Re: Root RAID different from Boot RAID? and other RAID issues
Date: Wed, 27 Jan 1999 17:52:30 GMT
I don't know anything about the state of Linux's RAID suport, can't help
there. But from my experience working with these kinds o' things (mostly
Clariion and Conley raid boxes, and ODS and Veritas, on Suns), I've come to
the firm opinion that I don't like mirroring or any other kind o' sexy RAID on
the boot drive. Instead, when setting up such high-availability or
high-performance systems, I strongly prefer to manually mirror the boot drive;
set up a script that will rsync the filesystems on the working boot drive over
to the spare, then make any edits required to make it directly bootable right
where it sits (editing device names in /etc/fstab, updating boot blocks,
whatever). Then decide when to run it. Depending on what I'm trying to protect
against, sometimes I like to run it late at night, to catch daily changes, or
at the very end of the boot process to capture the latest-known-good bootable
configuration. Mirroring and RAID-5 and suchlike hacks lovingly preserve the
commonest failure mode, stupid human screwups that make a system unbootable.
-Bennett
------------------------------
From: Loren Osborn <[EMAIL PROTECTED]>
Subject: Re: Parallel C for Linux
Date: Wed, 27 Jan 1999 09:22:08 -0800
Tom Goodale wrote:
>
> Vitor Pedro Bonucci Pias wrote:
> >
> > I have my system running Dual pentium II 450.
> >
> > The system runing fine with kernel-2.2.0-pre7,
> >
> > and i would like to know if there is a Parallel C
> >
> > compiler for Linux to explore the Parallelisme.
> >
> > Thanks
> >
> > Pedro Pias
>
> I don't know of any parallel c compilers, but if you can put up with
> distributed memory parallelism, you could use pvm or mpi.
If you're talking about compile-time exploitation of parallelism, I
believe that there is a parallel version of 'make' that which will
compile several files simulteaneously.
Loren
------------------------------
From: Richard Jones <[EMAIL PROTECTED]>
Subject: Re: How can I build a Linux system from scratch - NO distribution?
Date: Mon, 25 Jan 1999 23:54:01 +0000
Stefan Monnier <[EMAIL PROTECTED]>
wrote:
:>>>>> "Richard" == Richard Jones <[EMAIL PROTECTED]> writes:
:> My real problem is that I only want to refuse
:> queries when the dial-up link is down. When the
: In your script that takes to link down (or brings it up), change the
: config for the resolver. This can either be by
: 3 - changing named's config and `kill -HUP' it.
This is possible, but a bit ugly.
: I'm sure there are a few more ways to get the same result. A more generic
: way might be to make sure that when the link is down any access to something
: that's not local will result in an immediate `no route to host' so as to
: avoid timeouts. But that precludes dial-on-demand.
This doesn't work. The problem is that the
clients (which are on another machine) poll
the nameserver every 5, 10, 20, 40 seconds.
The nameserver sees that there is no route
to host, but doesn't send back a negative
response. It (seems to) just forget about
the request and log an error to syslog, so
the clients still block endlessly.
Rich.
--
- Richard Jones. Linux contractor London and SE areas. -
- Very boring homepage at: http://www.annexia.demon.co.uk/ -
- You are currently the 1,991,243,100th visitor to this signature. -
- Original message content Copyright (C) 1998 Richard Jones. -
------------------------------
From: Richard Jones <[EMAIL PROTECTED]>
Subject: Re: getting notified on file change?
Date: Mon, 25 Jan 1999 23:50:10 +0000
M Sweger <[EMAIL PROTECTED]> wrote:
: Malte Starostik ([EMAIL PROTECTED]) wrote:
: : Hi!
: : In the Win32 API there are FindFirstChangeNotification & co. to set up
: : events that are triggered when files is created, deleted or changed in a
: : specified directory.
: : Is there something alike in Linux, so I can get a signal when a file is
: : changed?
: : Thanx,
: : -Malte
: You may also want to extend the capability to directory change too!
: Since at times I would like to monitor a directory that would tell me
: when a file is put into a directory, modified and deleted plus its
: priveleges. Note: a directory is just a file and the data in it is the
: list of files etc. I've tried the Unix command "tail -f" on the
: directory structure, but this just doesn't cut it.
It's a classic problem. Try polling the
directory's mtime. It's not very clean,
but it seems to work.
Rich.
--
- Richard Jones. Linux contractor London and SE areas. -
- Very boring homepage at: http://www.annexia.demon.co.uk/ -
- You are currently the 1,991,243,100th visitor to this signature. -
- Original message content Copyright (C) 1998 Richard Jones. -
------------------------------
From: [EMAIL PROTECTED]
Subject: Forcing FAT-like behaviour on the ext2fs
Date: Thu, 28 Jan 1999 06:40:42 GMT
Hello again! I know this sounds strange, but for reasons it would be too long
to explain I'd really like to have the ext2fs on some of my disk partitions
behave very much like the old FAT, in the sense that: 1) whenever a new file
is created, it is allocated a chunk of contiguous space (independently of how
much data is written into the file) in the outernmost possible region of the
partition. 2) whenever a file grows beyond the space it was allocated, it is
allocated a new chunk of space (the size of the first) either in the
outernmost possible region of the partition, or perhaps sequentially after
the first chunk if possible (I do not really care, either of these two
policies would suit me equally well).
Of course, this approach can either produce severe fragmentation, if the
chunks are sufficiently small, or it can get to waste a lot of space, if the
chunks are large, as I would like to get on my system, and is generally far
less efficient than the ext2fs approach based on block groups; however, it is
simpler to analyze and control what's going on, and in some very specialized
cases (such as mine) this approach might even be slightly more efficient than
the "standard", block group based ext2fs.
I believe, from hints in a couple of articles I have retrieved from this
group, that it IS possible to force this abnormal behaviour in the ext2fs,
perhaps by changing some parameters in the source code or using things like
tune2fs... how? Can I set the one paramenter of this primitive filesystem,
i.e. the "chunk size", to VERY LARGE values (say, from half a megabyte up to
20 megabytes)?.
Thanks a lot in advance for any help
Enoch Peserico
============= Posted via Deja News, The Discussion Network ============
http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
------------------------------
** FOR YOUR REFERENCE **
The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:
Internet: [EMAIL PROTECTED]
You can send mail to the entire list (and comp.os.linux.development.system) via:
Internet: [EMAIL PROTECTED]
Linux may be obtained via one of these FTP sites:
ftp.funet.fi pub/Linux
tsx-11.mit.edu pub/linux
sunsite.unc.edu pub/Linux
End of Linux-Development-System Digest
******************************