![]() |
|
|
#1 |
|
Архивный участник
Join Date: May 2005
Posts: 63
|
I know that some game passwords online checkers are exists now, so there a way to make this process slowly.
This is SQL Server side modification, already checked under SQL2005 EXPRESSS 1) you need to add table user_auth_log to lin2db Code:
USE [lin2db] GO SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO SET ANSI_PADDING ON GO CREATE TABLE [dbo].[user_auth_log]( [sid] [int] IDENTITY(1,1) NOT NULL, [account] [varchar](14) COLLATE Cyrillic_General_CI_AS NULL, [success] [tinyint] NOT NULL CONSTRAINT [DF_user_auth_log_success] DEFAULT ((2)), [dt] [datetime] NOT NULL CONSTRAINT [DF_user_auth_log_dt] DEFAULT (getdate()) ) ON [PRIMARY] GO SET ANSI_PADDING OFF 2) You need to modify lin2db..ap_GPwd stored procedure: Code:
set ANSI_NULLS OFF set QUOTED_IDENTIFIER OFF GO ALTER PROCEDURE [dbo].[ap_GPwd] @account varchar(14), @pwd binary(16) output AS --exec ap_GPwd_log @account -- Created By darkangel -- 20xx.xx.19 -- updated 20xx.xx.14 by KEMBL -- set Account's auth logging -- updated 20xx.xx.31 Logrus, Drone -- added login counts per time check SET NOCOUNT ON if (SELECT COUNT(*) FROM lin2db..user_auth_log WHERE account=@account AND DATEDIFF(mi, dt, GETDATE()) < 16) > 4 OR (SELECT COUNT(*) FROM lin2db..user_auth_log WHERE account=@account AND DATEDIFF(ss, dt, GETDATE()) < 3) > 0 BEGIN INSERT INTO user_auth_log (account,success) VALUES (@account, 0) SET NOCOUNT OFF SELECT @pwd = 0xC3371572F8F9BF71A8D31A1EB2436D6C END ELSE BEGIN INSERT INTO user_auth_log (account,success) VALUES (@account, 1) SET NOCOUNT OFF SELECT @pwd=password FROM user_auth with (nolock) WHERE account=@account END So, now rules are: 5 login tryes per 15 minutes and not less than 2 seconds between tryes. One more bad things exists with this code Change binary 16 string in value @pwd Code:
SELECT @pwd = 0xC3371572F8F9BF71A8D31A1EB2436D6 P.S. If you have got hex fix (or other) to login two users with one char (for self clone, selling and dupe resources), please share it. Torune's patch is great, but ability for char cloning still exists. |
|
|
|
|