ionline
发表于 2011-1-29 12:43:07
好像有限制吧。。
广东林001
发表于 2011-1-30 10:53:12
ccxxzz 发表于 2011-1-15 23:33 static/image/common/back.gif
V1.1.0只提供给注册客户的
怎样才能成为注册客户?
ccxxzz
发表于 2011-2-16 02:15:42
本帖最后由 ccxxzz 于 2011-2-16 02:36 编辑
做的最简单的客户拨号端,就一个文件,不管客户的机器中宽带连接是否建立;加密传输的字符为密码前面加上 xnzy 四个字母,如果启用加密,那么需要在认证核心端修改下这个
Control=1
REM ==================================
REM 设置系统是否启用客户端拨号加密传输
REM ==================================
Controlpass=xnzy
REM =====================================
REM 客户端拨号加密传输字符,为空不加密
REM 如果设置,则需要特殊的拨号软件如星空类
REM =====================================
下 载在这里,强行断开,不会弹出系统的重拨界面。防止路由是很好的,如需要按月、按天加密或者其他加密,你提供方法,在服务段采用同样的自动加密算法,反正CHAP密码是很难跟踪的,防菜鸟路由必杀!不相信他拨号每天有空去做解密跟踪再去写路由,况切chap协议算法还是很复杂的,不是PAP所能比的!所以他们只能猜测字典法,等他穷举破解出密码,已经过去N个小时,采用一定算法的拨号客户端说不定明天密码又变化了!想做路由的高级客户,就纯粹是这些浪费高级客户的时间。
原始代码的RAS文件在这里:
unit Ras;
interface
uses
Windows, SysUtils;
{$DEFINE WINVER400}
const
rasapi32 = 'rasapi32.dll';
UNLEN = 256; // Maximum user name length
PWLEN = 256; // Maximum password length
CNLEN = 15; // Computer name length
DNLEN = CNLEN;// Maximum domain name length
RAS_MaxDeviceType = 16;
RAS_MaxPhoneNumber = 128;
RAS_MaxIpAddress = 15;
RAS_MaxIpxAddress = 21;
{$IFDEF WINVER400}
RAS_MaxEntryName = 256;
RAS_MaxDeviceName = 128;
RAS_MaxCallbackNumber = RAS_MaxPhoneNumber;
{$ELSE}
RAS_MaxEntryName = 20;
RAS_MaxDeviceName = 32;
RAS_MaxCallbackNumber = 48;
{$ENDIF}
RAS_MaxAreaCode = 10;
RAS_MaxPadType = 32;
RAS_MaxX25Address = 200;
RAS_MaxFacilities = 200;
RAS_MaxUserData = 200;
RASCS_OpenPort = 0;
RASCS_PortOpened = 1;
RASCS_ConnectDevice = 2;
RASCS_DeviceConnected = 3;
RASCS_AllDevicesConnected = 4;
RASCS_Authenticate = 5;
RASCS_AuthNotify = 6;
RASCS_AuthRetry = 7;
RASCS_AuthCallback = 8;
RASCS_AuthChangePassword= 9;
RASCS_AuthProject = 10;
RASCS_AuthLinkSpeed = 11;
RASCS_AuthAck = 12;
RASCS_ReAuthenticate = 13;
RASCS_Authenticated = 14;
RASCS_PrepareForCallback= 15;
RASCS_WaitForModemReset = 16;
RASCS_WaitForCallback = 17;
RASCS_Projected = 18;
{$IFDEF WINVER400}
RASCS_StartAuthentication = 19;
RASCS_CallbackComplete = 20;
RASCS_LogonNetwork = 21;
{$ENDIF}
RASCS_SubEntryConnected = 22;
RASCS_SubEntryDisconnected= 23;
RASCS_PAUSED = $1000;
RASCS_Interactive = RASCS_PAUSED;
RASCS_RetryAuthentication = (RASCS_PAUSED + 1);
RASCS_CallbackSetByCaller = (RASCS_PAUSED + 2);
RASCS_PasswordExpired = (RASCS_PAUSED + 3);
RASCS_DONE = $2000;
RASCS_Connected = RASCS_DONE;
RASCS_Disconnected = (RASCS_DONE + 1);
// If using RasDial message notifications, get the notification message code
// by passing this string to the RegisterWindowMessageA() API.
// WM_RASDIALEVENT is used only if a unique message cannot be registered.
RASDIALEVENT = 'RasDialEvent';
WM_RASDIALEVENT = $CCCD;
// TRASPROJECTION
RASP_Amb = $10000;
RASP_PppNbf = $0803F;
RASP_PppIpx = $0802B;
RASP_PppIp = $08021;
RASP_Slip = $20000;
type
THRASCONN = THandle;
PHRASCONN = ^THRASCONN;
TRASCONNSTATE = DWORD;
PDWORD = ^DWORD;
PBOOL = ^BOOL;
TRASDIALPARAMS = packed record
dwSize : DWORD;
szEntryName : array of Char;
szPhoneNumber : array of Char;
szCallbackNumber : array of Char;
szUserName : array of Char;
szPassword : array of Char;
szDomain : array of Char;
{$IFDEF WINVER401}
dwSubEntry : DWORD;
dwCallbackId : DWORD;
{$ENDIF}
szPadding : array of Char;
end;
PRASDIALPARAMS = ^TRASDIALPARAMS;
TRASDIALEXTENSIONS = packed record
dwSize : DWORD;
dwfOptions : DWORD;
hwndParent : HWND;
reserved : DWORD;
end;
PRASDIALEXTENSIONS = ^TRASDIALEXTENSIONS;
TRASCONNSTATUS = packed record
dwSize : DWORD;
RasConnState : TRASCONNSTATE;
dwError : DWORD;
szDeviceType : array of char;
szDeviceName : array of char;
szPadding : array of Char;
end;
PRASCONNSTATUS = ^TRASCONNSTATUS;
TRASCONN = packed record
dwSize : DWORD;
hRasConn : THRASCONN;
szEntryName: array of char;
{$IFDEF WINVER400}
szDeviceType : array of char;
szDeviceName : array of char;
{$ENDIF}
szPadding : array of Char;
end;
PRASCONN = ^TRASCONN;
TRASENTRYNAME = packed record
dwSize : DWORD;
szEntryName: array of char;
szPadding : array of Char;
end;
PRASENTRYNAME = ^TRASENTRYNAME;
TRASENTRYDLG = packed record
dwSize : DWORD;
hWndOwner : HWND;
dwFlags : DWORD;
xDlg : LongInt;
yDlg : LongInt;
szEntry : array of char;
dwError : DWORD;
Reserved : DWORD;
Reserved2 : DWORD;
szPadding : array of Char;
end;
PRASENTRYDLG = ^TRASENTRYDLG;
TRASPROJECTION = integer;
TRASPPPIP = record
dwSize: DWORD;
dwError : DWORD;
szIpAddress : array of char;
end;
function RasDialA(RasDialExtensions: PRASDIALEXTENSIONS;
PhoneBook : PChar;
RasDialParams : PRASDIALPARAMS;
NotifierType: DWORD;
Notifier : Pointer;
RasConn : PHRASCONN
): DWORD; stdcall;
function RasGetErrorStringA(
uErrorValue : DWORD; // error to get string for
szErrorString : PChar; // buffer to hold error string
cBufSize : DWORD // size, in characters, of buffer
): DWORD; stdcall;
function RasHangupA(RasConn: THRASCONN): DWORD; stdcall;
function RasConnectionStateToString(nState : Integer) : String;
function RasGetConnectStatusA(
hRasConn: THRASCONN; // handle to RAS connection of interest
lpRasConnStatus : PRASCONNSTATUS // buffer to receive status data
): DWORD; stdcall;
function RasEnumConnectionsA(
pRasConn : PRASCONN; // buffer to receive connections data
pCB : PDWORD; // size in bytes of buffer
pcConnections : PDWORD // number of connections written to buffer
) : DWORD; stdcall
function RasEnumEntriesA(
Reserved : Pointer; // reserved, must be NIL
szPhonebook : PChar; // full path and filename of phonebook file
lpRasEntryName : PRASENTRYNAME; // buffer to receive entries
lpcb : PDWORD; // size in bytes of buffer
lpcEntries : PDWORD // number of entries written to buffer
) : DWORD; stdcall;
function RasGetEntryDialParamsA(
lpszPhonebook : PChar; // pointer to the full path and filename of the phonebook file
lprasdialparams : PRASDIALPARAMS; // pointer to a structure that receives the connection parameters
lpfPassword : PBOOL // indicates whether the user's password was retrieved
) : DWORD; stdcall;
function RasEditPhonebookEntryA(
hWndParent : HWND; // handle to the parent window of the dialog box
lpszPhonebook : PChar; // pointer to the full path and filename of the phonebook file
lpszEntryName : PChar// pointer to the phonebook entry name
) : DWORD; stdcall;
//function RasEntryDlgA(
// lpszPhonebook : PChar; // pointer to the full path and filename of the phone-book file
// lpszEntry : PChar; // pointer to the name of the phone-book entry to edit, copy, or create
// lpInfo : PRASENTRYDLG// pointer to a structure that contains additional parameters
// ) : DWORD; stdcall;
function RasCreatePhonebookEntryA(
hWndParent : HWND; // handle to the parent window of the dialog box
lpszPhonebook : PChar // pointer to the full path and filename of the phonebook file
) : DWORD; stdcall;
function RasGetProjectionInfoA(
hRasConn : THRASCONN; // handle that specifies remote access connection of interest
RasProjection : TRASPROJECTION; // specifies type of projection information to obtain
lpProjection: Pointer; // points to buffer that receives projection information
lpcb : PDWORD // points to variable that specifies buffer size
) : DWORD; stdcall;
function RasGetIPAddress: string;
implementation
{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function RasConnectionStateToString(nState : Integer) : String;
begin
case nState of
RASCS_OpenPort: Result := '打开ADSL拨号端口';
RASCS_PortOpened: Result := 'ADSL端口已经打开';
RASCS_ConnectDevice: Result := '正在连接ADSL设备';
RASCS_DeviceConnected: Result := 'ADSL设备已经连接好';
RASCS_AllDevicesConnected:Result := '所有设备已经连接好';
RASCS_Authenticate: Result := '开始ADSL拨号过程';
RASCS_AuthNotify: Result := '用户名或密码错误';
RASCS_AuthRetry: Result := 'ADSL断开重试';
RASCS_AuthCallback: Result := '回叫请求';
RASCS_AuthChangePassword: Result := '改变密码请求';
RASCS_AuthProject: Result := '网络连接成功';
RASCS_AuthLinkSpeed: Result := '连接速度计算';
RASCS_AuthAck: Result := 'Authentication Acknowledged';
RASCS_ReAuthenticate: Result := 'Reauthentication Started';
RASCS_Authenticated: Result := '正在断开ADSL连接';
RASCS_PrepareForCallback: Result := '准备回叫';
RASCS_WaitForModemReset: Result := '等待ADSL复位';
RASCS_WaitForCallback: Result := '等待回叫';
RASCS_Projected: Result := '拨号控制';
{$IFDEF WINVER400}
RASCS_StartAuthentication:Result := 'Start Authentication';
RASCS_CallbackComplete: Result := 'Callback Complete';
RASCS_LogonNetwork: Result := '登陆网络';
{$ENDIF}
RASCS_SubEntryConnected: Result := '';
RASCS_SubEntryDisconnected: Result := '';
RASCS_Interactive: Result := 'Interactive';
RASCS_RetryAuthentication:Result := 'Retry Authentication';
RASCS_CallbackSetByCaller:Result := 'Callback Set By Caller';
RASCS_PasswordExpired: Result := 'Password Expired';
RASCS_Connected: Result := '已经连接';
RASCS_Disconnected: Result := '已经断开连接';
else
Result := 'Connection state #' + IntToStr(nState);
end;
end;
{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function RasGetIPAddress: string;
var
RASConns : TRasConn;
dwSize : DWORD;
dwCount : DWORD;
RASpppIP : TRASPPPIP;
begin
Result := '';
RASConns.dwSize := SizeOf(TRASConn);
RASpppIP.dwSize := SizeOf(RASpppIP);
dwSize := SizeOf(RASConns);
if RASEnumConnectionsA(@RASConns, @dwSize, @dwCount) = 0 then begin
if dwCount > 0 then begin
dwSize := SizeOf(RASpppIP);
RASpppIP.dwSize := SizeOf(RASpppIP);
if RASGetProjectionInfoA(RASConns.hRasConn,
RASP_PppIp,
@RasPPPIP,
@dwSize) = 0 then
Result := StrPas(RASpppIP.szIPAddress);
end;
end;
end;
{* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *}
function RasDialA; external rasapi32 name 'RasDialA';
function RasGetErrorStringA; external rasapi32 name 'RasGetErrorStringA';
function RasHangUpA; external rasapi32 name 'RasHangUpA';
function RasGetConnectStatusA; external rasapi32 name 'RasGetConnectStatusA';
function RasEnumConnectionsA; external rasapi32 name 'RasEnumConnectionsA';
function RasEnumEntriesA; external rasapi32 name 'RasEnumEntriesA';
function RasGetEntryDialParamsA; external rasapi32 name 'RasGetEntryDialParamsA';
function RasEditPhonebookEntryA; external rasapi32 name 'RasEditPhonebookEntryA';
//function RasEntryDlgA; external rasapi32 name 'RasEntryDlgA';
function RasCreatePhonebookEntryA; external rasapi32 name 'RasCreatePhonebookEntryA';
function RasGetProjectionInfoA; external rasapi32 name 'RasGetProjectionInfoA';
end.
webhelp
发表于 2011-2-16 11:26:55
不错,软件用了效果不错,大家要顶,要支持。
medreams
发表于 2011-2-16 12:31:16
下来测试下!!!
ccxxzz
发表于 2011-2-16 15:30:54
还是放出了MSSQL版本的,这下好了,XP就不能玩我这个认证了。必定系统为能装MSSQL的才行了!
fjingxu
发表于 2011-2-16 15:53:50
楼主自己的地址下载时,毒霸提示有木马,请检查一下。
ccxxzz
发表于 2011-2-16 16:42:09
本帖最后由 ccxxzz 于 2011-2-16 16:47 编辑
大家放心,软件经过卡巴 和瑞星检测的,卡巴是行为动作杀毒,不会有假的,软件自己写的,绝不会放毒到里面,否则就是欠道德或者违背我写软件的规则啊,更会影响到软件的推广和使用,那就是害人害己啊!软件也没有放任何后门,软件也绝不会去访问某个远程地址或者发送邮件,注意下端口安全就可以了!
踏雪飞狐
发表于 2011-2-18 21:54:34
看上去很不错。辛苦了
ccxxzz
发表于 2011-2-27 00:35:39
本帖最后由 ccxxzz 于 2011-2-27 00:50 编辑
V1.1.2再次推出一下,把MSCHAP V1转到正式认证,PAP是明码认证,原来不想做,现在这个协议干脆用来做模糊认证;加入前台开单程序、结算程序、打印模块;代理模块。
个人写软件,V1.1.2源代码达到了63M,完善的速度会慢下来了,因为查找的BUG的速度慢了很多!不过编译后只有4M多一点。
fchzlj
发表于 2011-2-28 00:33:47
基本结构还是不错的,就是界面有待加强,呵呵!
qinfei
发表于 2011-2-28 01:19:43
这个程序确实很好,但是我不会用啊?天啊,得让我同学看看才行,呵呵。支持楼主
48555247
发表于 2011-3-8 17:02:01
好东西需要顶一顶
xiaxue_203
发表于 2011-3-9 00:14:03
ccxxzz 发表于 2010-7-14 17:54 static/image/common/back.gif
小区网络校园网络最精简的认证系统,如果不是,劈我砖头!
实现了与ROS无缝连接,在线控制、踢人,帐号唯一 ...
安装测试结果:失败
软件已经和数据库连接,和ros估计也对接上了。客户端拨号时老是显示”正在核对用户名和密码“
但是在认证系统里显示的确实”认证许可!“,在ros的log里看到radius timeout,不知道何故?
ccxxzz
发表于 2011-3-9 01:41:00
本帖最后由 ccxxzz 于 2011-3-9 02:07 编辑
呵呵,找我QQ,帮你一下!
一个ROS NAT,多个接入ROS,用户在多个ROS中漫游上网应用,请看图
用户CXZ在192。168。0。8和192。168。0。10两个ROS中漫游,方便校园网建设。成功应用于广西某高校认证。
软件又加到了70M,痛苦啊!
页:
2
3
4
5
6
7
8
9
10
11
[12]
13
14
15
16