application
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

application

Started by ignazio, 25 May, 2005, 17:26:08

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

ignazio

hi boys and possible to create a script not to make to enter the hub the 56 Kbps 28.8Kbps Modem ISDN
do you believe both possible to do her/it??


thanks and you excuse for my English 8)




jiten

Give this a try:
Settings = { 
	["28.8Kbps"] = 0,
	["56Kbps"] = 0,
	["Modem"] = 0,
	["ISDN"] = 0,
}

MyINFOArrival = function(user,data)
	local Connection = user.sConnection
	if (Settings[Connection] == 0) and not user.bOperator then
		user:SendData(frmHub:GetHubBotName(),Connection.." Connections are not allowed in this hub. Disconnecting...")
		user:Disconnect()
	end
end
Best regards

ignazio

thanks  jiten  :D

jiten

You're welcome :]

CaSaNoVa

And to take redirect too?

6Marilyn6Manson6

#5
Try this (not tested ):

hub = "address.here"

Settings = { 
	["28.8Kbps"] = 0,
	["56Kbps"] = 0,
	["Modem"] = 0,
	["ISDN"] = 0,
}

MyINFOArrival = function(user,data)
	local Connection = user.sConnection
	if (Settings[Connection] == 0) and not user.bOperator then
		user:SendData(frmHub:GetHubBotName(),Connection.." Connections are not allowed in this hub. Redirecting...")
		user:SendData(frmHub:GetHubBotName(),"Redirecting to: "..hub.."")
		user:SendData(frmHub:GetHubBotName(),"Redirecting to: "..hub.."|$ForceMove "..hub.."|")	
	end
end


c ya

jiten

A bit better:
DoRedirect = 0 --  1: Redirect all users; 1: Disables redirection
Address = "address.no-ip.com"

Settings = { 
	["28.8Kbps"] = 0,
	["56Kbps"] = 0,
	["Modem"] = 0,
	["ISDN"] = 0,
}

MyINFOArrival = function(user,data)
	local Connection = user.sConnection
	local msg = Connection.." Connections are not allowed in this hub. Disconnecting..."
	if (Settings[Connection] == 0) and not user.bOperator then
		if DoRedirect == 1 then user:Redirect(Address, msg) end
		user:SendData(frmHub:GetHubBotName(), msg) user:Disconnect()
	end
end
Cheers

imby

QuoteOriginally posted by jiten
Give this a try:
Settings = { 
	["28.8Kbps"] = 0,
	["56Kbps"] = 0,
	["Modem"] = 0,
	["ISDN"] = 0,
}

MyINFOArrival = function(user,data)
	local Connection = user.sConnection
	if (Settings[Connection] == 0) and not user.bOperator then
		user:SendData(frmHub:GetHubBotName(),Connection.." Connections are not allowed in this hub. Disconnecting...")
		user:Disconnect()
	end
end
Best regards

What's the most efficient way of only checking Regs (3) and normal users (-1)? (not VIP or higher)

uffetjur

this way to set it up - reading the connection info tag is more or less useless... settings have no functions in dc-protokoll with FulDC you can type your on connection settings in the box like - "razorblade" or whatever

only way to check is to test uploadspeed and even this is not 100%
Somewhere in Cyberspace

imby

QuoteOriginally posted by uffetjur
this way to set it up - reading the connection info tag is more or less useless... settings have no functions in dc-protokoll with FulDC you can type your on connection settings in the box like - "razorblade" or whatever

only way to check is to test uploadspeed and even this is not 100%

Thanks but 1 in 200 people tend to use fuldc in my hub. and I do have a way to moderate speed which will work, and no , it doesn't involve kicking all those who give less than 2 KB/s (for example). This script will be useful because there's no point in allowing those who are guaranteed to be unable to make my minimum requirements into my hub. In the disconnection message from the bot I'll include, if you haven't filled your connection speed in properly, and have a high connection speed, feel free to do so. If you want to come in and fake your connection, you wont get past the human checks. Obviously it'll be written more professionally than that, with details how to do so, and I'll make it concise.

uffetjur

what my point is - This setting has no affect at all to the P2p Protocol
If you want to have control over speed , run a regged only hub where upload /or download speed is included in the nick... and as curiosa lotsa users has connections that this standard dc aint got a settings for...

xDSL comes in many different connection types, T1, T3 is an american standard and doesnt really tell what your connection is
Somewhere in Cyberspace

imby

QuoteOriginally posted by uffetjur
what my point is - This setting has no affect at all to the P2p Protocol
If you want to have control over speed , run a regged only hub where upload /or download speed is included in the nick...

I've already stated my way of soing things will be effective, don't waste your time preaching to someone who has been running a hub for 1.5 years. I know scripts like these are ineffective on a standard hub setup.

Quoteand as curiosa lotsa users has connections that this standard dc aint got a settings for...

"there's no point in allowing those who are guaranteed to be unable to make my minimum requirements into my hub."

QuotexDSL comes in many different connection types, T1, T3 is an american standard and doesnt really tell what your connection is

"there's no point in allowing those who are guaranteed to be unable to make my minimum requirements into my hub."

DSL, T1 etc has the potential to be fast, a dial up modem is never fast.

plop

T1/T3 isn't an american standard @ all.
neither is it different from a standard ISDN line.
what is different is the amount of ISDN channels it uses.
ppl mostly have ISDN2 @ there homes, this means 2 ISDN channels.
T1 is 24 ISDN channels in america/japan and 30 in europe.
T3 is 672 ISDN channels in america and 480 in japan/europe.

the problems with the mistake of speed comes from the users.
ISDN lines are synchrone, unlike most dsl/cable connections which are nearly always a-synchrone.
this means ISDN has the same upload speed as there download.
like we know cable/dsl nearly allways have a lower upload speed then download (the 1st s from sdsl is from synchrone).
next comes the problem from half and full duplex.
ISDN has a up and down channel (you can speak while the other side speaks).
in most country's they only serve half duplex cable/dsl lines, which means traffice "either" goes up "or" down.
if a user then uploads @ full speed there is no place for downloading, it has 2 wait (hence the slow down in downloading).

many ppl who have a cable/dsl connection think that if they can download @ 1.5Mb/s or more think they have a T1 connection.
they are hereby causing the confusion/mistakes.
with a T1/T3 connection you can be absolutly sure about the speed (taking in count the place they live).

final point: measuring the actual speed of the user is only possible if you have a faster connection then the other side.
and that you and the other side aren't using the connection for anything else then the speed check.

plop
http://www.plop.nl lua scripts/howto\'s.
http://www.thegoldenangel.net
http://www.vikingshub.com
http://www.lua.org

>>----> he who fights hatred with hatred, drives the spreading of hatred <----<<

imby

I changed

Settings = { 

	["28.8Kbps"] = 0,

	["56Kbps"] = 0,

	["Modem"] = 0,

	["ISDN"] = 0,

}



MyINFOArrival = function(user,data)

	local Connection = user.sConnection

	if (Settings[Connection] == 0) and not user.bOperator then

		user:SendData(frmHub:GetHubBotName(),Connection.." Connections are not allowed in this hub. Disconnecting...")

		user:Disconnect()

	end

end

to:

Settings = { 

	["28.8Kbps"] = 0,

	["56Kbps"] = 0,

	["Modem"] = 0,

	["ISDN"] = 0,

}



MyINFOArrival = function(user,data)

	local Connection = user.sConnection

	if (Settings[Connection] == 0) and user.iProfile == -1 or user.iProfile == 3 then

		user:SendData(frmHub:GetHubBotName(),Connection.." Connections are not allowed in this hub. Disconnecting...")

		user:Disconnect()

	end

end

Is this the best way of doing it?

SMF spam blocked by CleanTalk