All of lore.kernel.org
 help / color / mirror / Atom feed
From: "cyx_mail" <cyx_mail@foxmail.com>
To: linux-ppp@vger.kernel.org
Subject: Re: Re: Re: from which hook , I can get the usrname that pppd used?
Date: Fri, 16 May 2008 00:43:46 +0000	[thread overview]
Message-ID: <200805160843456429537@foxmail.com> (raw)
In-Reply-To: <200805151619318592147@foxmail.com>

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="windows-1254", Size: 2167 bytes --]

ok, Thanks for your patient. I'm going to write a PPPoE Proxy base on the pppoe-server and pppd, the proxy acts both as "server" and "clent". So it acquire the usrname from the peer which connect to the proxy and establish a connection to the real pppoe-server(or BAS),so I have to acquire this two kinds of user names from pppd. any suggestions?


2008-05-16                   

cyx_mail 



·¢¼þÈË£º James Carlson 
·¢ËÍʱ¼ä£º 2008-05-16  03:16:16 
ÊÕ¼þÈË£º cyx 
³­ËÍ£º linux-ppp 
Ö÷Ì⣺ Re: Re: from which hook , I can get the usrname that pppd used? 
 
cyx writes:
> Thank for your help! username that  I want to get is the one pppd  read from chap-secret or pap-secret, I think they my be store in an global var?
I'm afraid you're still not being specific enough.
pppd can be configured to behave as an authenticator ("server"), an
authenticatee ("client"), both, or neither.
When configured as an authenticator, pppd will acquire a name from the
peer and will validate that identity.  The resulting validated peer
name appears in the peer_authname[] array.
When configured as an authenticatee, the name pppd presents to the
peer for identification is in the our_name[] array.
This is all in the pppd/auth.c module, which is common to all
authentication schemes (including PAP and CHAP).  If you're trying to
write code that integrates with pppd, I *strongly* recommend spending
the time to read through the pppd source code.  The layout of the code
is fairly logical, so it's not hard to read, and there are substantial
and informative comments in many places.
(Note that it's really not proper to talk about "users" here.  PPP is
a layer two technology; there are no "users."  There are only peers.)
-- 
James Carlson         42.703N 71.076W         <carlsonj@workingcode.com>
--
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to majordomo@vger.kernel.org
__________ NOD32 3090 (20080509) Information __________
This message was checked by NOD32 antivirus system.
http://www.nod32cn.com
ÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þšiþ)í…æèw*\x1fjg¬±¨\x1e¶‰šŽŠÝ¢jÿ¾\a«þG«éÿ¢¸\f¢·¦j:+v‰¨ŠwèjØm¶Ÿÿþø\x1e¯ù\x1e®w¥þŠàþf£¢·hšâúÿ†Ù¥

      parent reply	other threads:[~2008-05-16  0:43 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-15  8:19 from which hook , I can get the usrname that pppd used? cyx_mail
2008-05-15 13:57 ` James Carlson
2008-05-15 14:53 ` cyx
2008-05-15 19:14 ` James Carlson
2008-05-16  0:43 ` cyx_mail [this message]

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=200805160843456429537@foxmail.com \
    --to=cyx_mail@foxmail.com \
    --cc=linux-ppp@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.