Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* Re: 2.2.14pre13 - exception in __copy_user when running mount()
@ 1999-12-16 23:04 Michal Jaegermann
  1999-12-17  0:38 ` David S. Miller
  1999-12-20 23:05 ` Where Kan I get latest MILO sources ? Uncle George
  0 siblings, 2 replies; 8+ messages in thread
From: Michal Jaegermann @ 1999-12-16 23:04 UTC (permalink / raw)
  To: linux-kernel; +Cc: alan, axp-list, linux-alpha

Ok, this particular code change in 2.2.14-pre1[34] is responsible
for an exception in __copy_user on every attemp to mount or unmount
a file system (at least ext2 file system).

--- linux-2.2.14/fs/super.c	Sun Dec  5 15:24:34 1999
+++ linux-2.2.14p/fs/super.c	Thu Dec 16 10:21:38 1999
@@ -983,6 +983,7 @@
 	if (!data)
 		return 0;
 
+#if 0
 	vma = find_vma(current->mm, (unsigned long) data);
 	if (!vma || (unsigned long) data < vma->vm_start)
 		return -EFAULT;
@@ -991,13 +992,13 @@
 	i = vma->vm_end - (unsigned long) data;
 	if (PAGE_SIZE <= (unsigned long) i)
 		i = PAGE_SIZE-1;
-	if (!(page = __get_free_page(GFP_KERNEL))) {
+#else
+	i = PAGE_SIZE;		
+#endif		
+	if (!(page = get_free_page(GFP_KERNEL))) {
 		return -ENOMEM;
 	}
-	if (copy_from_user((void *) page,data,i)) {
-		free_page(page); 
-		return -EFAULT;
-	}
+	copy_from_user((void *) page,data,i);
 	*where = page;
 	return 0;
 }

Who own to this change, why it was done and what is missing?

An exception in question appears to happen in the follwing code
from arch/alpha/lib/copy_user.S:

........
   100		subq $0,1,$0
   101		addq $6,1,$6
   102		addq $7,1,$7
   103		bne $0,$57
   104		br $31,$41
   105		.align 4
   106	$43:
   107		beq $4,$65
   108		.align 5
   109	$66:
   110		EXI( ldq $1,0($7) )   <---- here!!!
   111		subq $4,8,$4
   112		EXO( stq $1,0($6) )
   113		addq $7,8,$7
   114		subq $0,8,$0
   115		addq $6,8,$6
   116		bne $4,$66
................

   Michal


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

* Re: 2.2.14pre13 - exception in __copy_user when running mount()
  1999-12-16 23:04 2.2.14pre13 - exception in __copy_user when running mount() Michal Jaegermann
@ 1999-12-17  0:38 ` David S. Miller
  1999-12-17  0:38   ` David S. Miller
                     ` (3 more replies)
  1999-12-20 23:05 ` Where Kan I get latest MILO sources ? Uncle George
  1 sibling, 4 replies; 8+ messages in thread
From: David S. Miller @ 1999-12-17  0:38 UTC (permalink / raw)
  To: michal; +Cc: linux-kernel, alan, axp-list, linux-alpha

   From: Michal Jaegermann <michal@ellpspace.math.ualberta.ca>
   Date:   Thu, 16 Dec 1999 16:04:46 -0700 (MST)

   Ok, this particular code change in 2.2.14-pre1[34] is responsible
   for an exception in __copy_user on every attemp to mount or unmount
   a file system (at least ext2 file system).

 ...

   Who own to this change, why it was done and what is missing?

Alan owns the change, and it was done on purpose, and the behavior you
see is correct, the Alpha port is the problem.

Alpha is buggy for reporting exceptions wrt. user space accesses
in the kernel logs, in fact it's a possible DoS attack on Alpha/Linux
machines.

So Alpha should be fixed.

Later,
David S. Miller
davem@redhat.com


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

* Re: 2.2.14pre13 - exception in __copy_user when running mount()
  1999-12-17  0:38 ` David S. Miller
@ 1999-12-17  0:38   ` David S. Miller
  1999-12-17  2:33   ` Dan Frasnelli
                     ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: David S. Miller @ 1999-12-17  0:38 UTC (permalink / raw)
  To: michal; +Cc: linux-kernel, alan, axp-list, linux-alpha

   From: Michal Jaegermann <michal@ellpspace.math.ualberta.ca>
   Date:   Thu, 16 Dec 1999 16:04:46 -0700 (MST)

   Ok, this particular code change in 2.2.14-pre1[34] is responsible
   for an exception in __copy_user on every attemp to mount or unmount
   a file system (at least ext2 file system).

 ...

   Who own to this change, why it was done and what is missing?

Alan owns the change, and it was done on purpose, and the behavior you
see is correct, the Alpha port is the problem.

Alpha is buggy for reporting exceptions wrt. user space accesses
in the kernel logs, in fact it's a possible DoS attack on Alpha/Linux
machines.

So Alpha should be fixed.

Later,
David S. Miller
davem@redhat.com

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/


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

* Re: 2.2.14pre13 - exception in __copy_user when running mount()
  1999-12-17  0:38 ` David S. Miller
  1999-12-17  0:38   ` David S. Miller
@ 1999-12-17  2:33   ` Dan Frasnelli
  1999-12-17  9:53   ` Uncle George
       [not found]   ` <199912170044.TAA15491@devserv.devel.redhat.com>
  3 siblings, 0 replies; 8+ messages in thread
From: Dan Frasnelli @ 1999-12-17  2:33 UTC (permalink / raw)
  To: axp-list; +Cc: alan, davem

(2.2.14pre report)

> Alpha is buggy for reporting exceptions wrt. user space accesses
> in the kernel logs, in fact it's a possible DoS attack on Alpha/Linux
> machines.

Dave is correct.  Under digi^H^H^H tru64, you can toggle reporting
of exceptions thrown by userland processes.  I disable exception reporting 
with my "production" 2.2 mods; unless you are debugging quirky 
code, their presence is more annoying than helpful.
Linux is not alone, either.  Its been my experience with tru64 that the 
level of 'noise' warrants the option to turn off the reporting entirely. 
--
Dan Frasnelli
Security analyst


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

* Re: 2.2.14pre13 - exception in __copy_user when running mount()
  1999-12-17  0:38 ` David S. Miller
  1999-12-17  0:38   ` David S. Miller
  1999-12-17  2:33   ` Dan Frasnelli
@ 1999-12-17  9:53   ` Uncle George
       [not found]   ` <199912170044.TAA15491@devserv.devel.redhat.com>
  3 siblings, 0 replies; 8+ messages in thread
From: Uncle George @ 1999-12-17  9:53 UTC (permalink / raw)
  To: axp-list; +Cc: linux-kernel, linux-alpha

I guess I got lost getting in the middle of this dialog.  What is exactly
buggy - alpha hardware - alpha software ?
Why would a DoS ( whatever that networking term be ) be more prevalent on
alpha.  What does either have to do with mount by 'root'.
gat


David S. Miller wrote:

>
> Alan owns the change, and it was done on purpose, and the behavior you
> see is correct, the Alpha port is the problem.
>
> Alpha is buggy for reporting exceptions wrt. user space accesses
> in the kernel logs, in fact it's a possible DoS attack on Alpha/Linux
> machines.
>
> So Alpha should be fixed.
>




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

* Re: 2.2.14pre13 - exception in __copy_user when running mount()
       [not found]     ` <19991217075331.V829@mff.cuni.cz>
@ 1999-12-17 11:57       ` David S. Miller
  0 siblings, 0 replies; 8+ messages in thread
From: David S. Miller @ 1999-12-17 11:57 UTC (permalink / raw)
  To: jakub; +Cc: alan, michal, linux-kernel, axp-list, linux-alpha

   Date: Fri, 17 Dec 1999 07:53:31 +0100
   From: Jakub Jelinek <jakub@redhat.com>

   > True but the simple page copy breaks in fun ways on some kernels
   > and with smb/ncpmount, so Im going to revert it to get 2.2.14 out
   > of the door, then give in and do a fs==ds test for 2.2.15pre

   In that case we need to find another solution for sparc64 though
   into 2.2.14.

I note in passing that I did send Alan a patch which did it the
"check for KERNEL_DS" way, but he said he had taken care of it
already :-)

Later,
David S. Miller
davem@redhat.com


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

* Where Kan I get latest MILO sources ?
  1999-12-16 23:04 2.2.14pre13 - exception in __copy_user when running mount() Michal Jaegermann
  1999-12-17  0:38 ` David S. Miller
@ 1999-12-20 23:05 ` Uncle George
  1999-12-21  1:57   ` Thorsten Kranzkowski
  1 sibling, 1 reply; 8+ messages in thread
From: Uncle George @ 1999-12-20 23:05 UTC (permalink / raw)
  To: axp-list

any one know ?
gat



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

* Re: Where Kan I get latest MILO sources ?
  1999-12-20 23:05 ` Where Kan I get latest MILO sources ? Uncle George
@ 1999-12-21  1:57   ` Thorsten Kranzkowski
  0 siblings, 0 replies; 8+ messages in thread
From: Thorsten Kranzkowski @ 1999-12-21  1:57 UTC (permalink / raw)
  To: axp-list

On Mon, Dec 20, 1999 at 06:05:16PM -0500, Uncle George wrote:
> any one know ?
> gat
> 


http://www.stefan-reinauer.de/Milo/source

It builds against kernel 2.2
With a little polishing I just got it working for my Noname :-)
binutils 2.9.5.0.22, gcc 2.95.2

Thorsten

-- 
| Thorsten Kranzkowski         Internet: dl8bcu@gmx.net                        |
| Mobile: ++49 161 7210230        Snail: Niemannsweg 30, 49201 Dissen, Germany |
| Ampr: dl8bcu@db0nei.#nrw.deu.eu, dl8bcu@marvin.dl8bcu.ampr.org [44.130.8.19] |


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

end of thread, other threads:[~1999-12-22 22:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1999-12-16 23:04 2.2.14pre13 - exception in __copy_user when running mount() Michal Jaegermann
1999-12-17  0:38 ` David S. Miller
1999-12-17  0:38   ` David S. Miller
1999-12-17  2:33   ` Dan Frasnelli
1999-12-17  9:53   ` Uncle George
     [not found]   ` <199912170044.TAA15491@devserv.devel.redhat.com>
     [not found]     ` <19991217075331.V829@mff.cuni.cz>
1999-12-17 11:57       ` David S. Miller
1999-12-20 23:05 ` Where Kan I get latest MILO sources ? Uncle George
1999-12-21  1:57   ` Thorsten Kranzkowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox