public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
From: Kelvin Lawson <klawson@ad-holdings.co.uk>
To: ecos-discuss@sources.redhat.com
Subject: [ECOS] Re: Problems with ppp and Windows
Date: Thu, 17 Jun 2004 14:04:00 -0000	[thread overview]
Message-ID: <cas8d6$qaf$1@sea.gmane.org> (raw)
In-Reply-To: <1087470300.31564.22.camel@famine>

Hi Øyvind,

> I've put together a memory allocation debug feature patch... 
> 
> http://ecos.sourceware.org/ml/ecos-discuss/2004-06/msg00161.html

It looks useful, thanks for that.

>>I think the proper place to add some debug notification is at the usage 
>>points of network mallocs. In the case of PPP, after the MALLOC() 
>>failed, it ought to have done something about it or printed some debug, 
>>rather than just carrying on broken.
> 
> Does it make any sense at all to bring up the PPP connection if these
> initial allocations fail?

Well that depends. If only a VJC allocation fails then it may be 
possible to bring up a PPP interface that refuses to negotiate VJC. I 
don't know if we really need to worry about providing this kind of 
fallback operation though.

> Note that I saw the lockup on accept() even if the VJC compression
> buffers could be allocated.

Your generic malloc fail patch should be pretty useful then, to catch 
any kind of allocation failing.

>>For PPP there are a bunch of configuration options that aren't covered 
>>by the cyg_ppp_options_t structure. I've added a few options here to 
>>handle authorisation for dialin connections. Similarly you could extend 
>>it to disable things like VJ compression to reduce the memory requirements.
> 
> Care to share? :-)

Certainly. I'm just experimenting with it at the moment though, so I'm 
not yet confident that it should go into the eCos tree. But in the 
meantime if you want to investigate, here's a summary:

. Set auth_required = 1 if you want to require authentication from the 
other end.
. Set wo->neg_chap and wo->neg_upap to 1 depending on which you want to 
use for authentication (see lcp.c)
. You can extend cyg_ppp_options_t to accomodate the above 3 options.
. Finally fix up the functions in auth.c to do your username/password 
lookup (maybe you want them in a fixed array, or read a password file 
off a disk or whatever). For CHAP, you can use get_secret() to look up 
the user/pass. For PAP, use check_passwd(), ensuring that 
have_pap_secret() returns 1. Also think about whether you will accept 
the IPs offered by the peer, and see function ip_addr_check().

Cheers,
Kelvin.


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

  reply	other threads:[~2004-06-17 14:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1087322512.28254.ezmlm@ecos.sourceware.org>
2004-06-15 21:36 ` [ECOS] " Øyvind Harboe
2004-06-16  9:55   ` [ECOS] " Kelvin Lawson
2004-06-16 12:24 ` [ECOS] " Øyvind Harboe
2004-06-17  9:08   ` [ECOS] " Kelvin Lawson
2004-06-17 11:05     ` Øyvind Harboe
2004-06-17 14:04       ` Kelvin Lawson [this message]
2004-04-22 15:14 [ECOS] " Øyvind Harboe
2004-06-15 10:30 ` [ECOS] " Kelvin Lawson

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='cas8d6$qaf$1@sea.gmane.org' \
    --to=klawson@ad-holdings.co.uk \
    --cc=ecos-discuss@sources.redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).