public inbox for linux-msdos@vger.kernel.org
 help / color / mirror / Atom feed
From: Stas Sergeev <stssppnn@yahoo.com>
To: linux-msdos@vger.kernel.org
Subject: Re: IPX without suidroot
Date: Fri, 02 Aug 2002 16:38:40 +0400	[thread overview]
Message-ID: <3D4A7D50.205@yahoo.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 339 bytes --]

Hello.

Grigory Batalov wrote:
> Ok, I've applied patch and can get some debug now.
Good. But I still don't like that
debuggung tricks so I think just
ripping out the buggy code is OK.

> get RIP packets if I haven't root privilegies.)
Seems like that.
Please apply the attached patch
instead of the previous one and
redo the log please.


[-- Attachment #2: ipx_root.diff --]
[-- Type: text/plain, Size: 2046 bytes --]

--- src/dosext/net/net/ipx.c	Fri Jul 19 02:04:37 2002
+++ src/dosext/net/net/ipx.c	Thu Aug  1 17:30:44 2002
@@ -443,18 +443,6 @@
   }
 
   opt = 1;
-  /* turn on socket debugging */
-  if (debug_level('n')) {
-    enter_priv_on();
-    if (setsockopt(sock, SOL_SOCKET, SO_DEBUG, &opt, sizeof(opt)) == -1) {
-      leave_priv_setting();
-      n_printf("IPX: could not set socket option for debugging: %s.\n", strerror(errno));
-      /* I can't think of anything else to return */
-      return (RCODE_SOCKET_TABLE_FULL);
-    }
-    leave_priv_setting();
-  }
-  opt = 1;
   /* Permit broadcast output */
   enter_priv_on();
   if (setsockopt(sock, SOL_SOCKET, SO_BROADCAST,
--- src/dosext/net/net/ipxglt.c	Tue Mar 19 19:45:49 2002
+++ src/dosext/net/net/ipxglt.c	Fri Aug  2 16:29:20 2002
@@ -107,21 +107,16 @@
 	leave_priv_setting();
 	if(sock==-1)
 	{
+		n_printf("IPX: could not open IPX socket: %s.\n", strerror(errno));
 		goto GLTExit;
 	}
 	
-	/* Socket debugging */
 	enter_priv_on();
-	if(setsockopt(sock,SOL_SOCKET,SO_DEBUG,&opt,sizeof(opt))==-1)
-	{
-		leave_priv_setting();
-		goto CloseGLTExit;
-	}
-	
 	/* Permit broadcast output */
 	if(setsockopt(sock,SOL_SOCKET,SO_BROADCAST, &opt,sizeof(opt))==-1)
 	{
 		leave_priv_setting();
+		n_printf("IPX: could not set socket option for broadcast: %s.\n", strerror(errno));
 		goto CloseGLTExit;
 	}
 	
@@ -133,6 +128,7 @@
 	if(setsockopt(sock,SOL_SOCKET,IPX_TYPE,&opt,sizeof(opt))==-1)
 	{
 		leave_priv_setting();
+		n_printf("IPX: could not set socket option for type: %s.\n", strerror(errno));
 		goto CloseGLTExit;
 	}
 	
@@ -143,6 +139,7 @@
 	if(bind(sock,(struct sockaddr *)&ipxs,sizeof(ipxs))==-1)
 	{
 		leave_priv_setting();
+		n_printf("IPX: could not bind socket to address: %s\n", strerror(errno));
 		goto CloseGLTExit;
 	}
 	leave_priv_setting();
@@ -172,6 +169,7 @@
 	        {
 			leave_priv_setting();
                         retCode = -2;
+			n_printf("IPX: sendto() failed: %s\n", strerror(errno));
         		goto CloseGLTExit;
 	        }
 		leave_priv_setting();

             reply	other threads:[~2002-08-02 12:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-08-02 12:38 Stas Sergeev [this message]
2002-08-02 13:47 ` IPX without suidroot Grigory Batalov
  -- strict thread matches above, loose matches on Subject: below --
2002-08-02 17:19 Stas Sergeev
2002-08-02 21:43 ` Grigory Batalov
2002-08-05  5:47 ` Grigory Batalov
2002-08-02 14:37 Stas Sergeev
2002-08-02 15:52 ` Grigory Batalov
2002-08-01 14:02 Stas Sergeev
2002-08-02 10:52 ` Grigory Batalov
2002-08-01 10:36 Grigory Batalov
2002-08-01 11:58 ` Reinhard Karcher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3D4A7D50.205@yahoo.com \
    --to=stssppnn@yahoo.com \
    --cc=linux-msdos@vger.kernel.org \
    --cc=stas.orel@mailcity.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox