Password protection on server

Easy to use IRC implementation for Unity.
Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Password protection on server

Postby Raiddevs » Sun Nov 12, 2017 11:34 am

I tried to contact you regarding a password protected server, you post a reply in asset store but unfortunatly thats not the issue. Adding the server password to the channel password doesnt work, i need to add the password for the server on connection (ip, port, PASSWORD) but have been unable to modify the script to handle this.

Any ideas on a modified code for this, i always use protected irc servers to keep botters out and wont remove it to use a script like this, just needs modifying.

Any ideas would be greatly welcomed but in the meantime ill continue to modify the script

(no successfull connection as of yet)

Rick

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Tue Nov 14, 2017 2:33 am

Hi there,

the script does it as far as I know, in the standard IRC way.
which is:
JOIN #channelName password

according to spec 2812, you can use:
JOIN &channelName password

so maybe change the # to a & on line 675?

Let me know if that doesn't work.
If your IRC server requires something else, I can help you if you tell me what the syntax is to apply the password.

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Password protection on server

Postby Raiddevs » Wed Nov 15, 2017 7:37 am

To join our IRC server you require a password to connect, this is done automatically in the game but i need a line to add to say that when you try to connect to our chat in the game after logging in it automatically inputs

There are no passwords on the channels as we only use 2 channels, 1 as the main game chat and the other is for the admins and mods(using IRC clients).

Connect to server (IP)(Port)
Password for server - This is whats needed
Identify user

currently at the moment when you log in the game and open the chat panel it connects to server - then disconnects for PASSWORD MISMATCH.

We use a password protected server so we dont get invaded by bot users looking to cause trouble from our server and safeguards the users in the chat.

Ive seen other IRC chat scripts that use a server password connection but can not implement it into your script and we dont wanna mess about with it too much.

If i remove the server password it connects fine, no issues but we need that extra security for our players.

Sorry if this is a pain but was hoping to edit the script to allow for this security function.

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Thu Nov 16, 2017 1:53 am

Hmm, if I understand correctly what you mean...

According to the spec at section 3.1.1 there is a way to provide a connection password.
You can provide it with the keyword PASS

Hence, in line 351, before the nick is sent, try adding the following

Code: Select all

streamOUT.WriteLine("PASS " + yourServerPassword );
streamOUT.Flush();


I haven't tested this, but it's worth a shot...

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Password protection on server

Postby Raiddevs » Fri Nov 17, 2017 9:56 am

Tried adding that code but nothing

Connects to server

Looks up name

ping/pong

disconnects


(*stuck now and will stare into space for a few days and see if the solution can be found*)

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Fri Nov 17, 2017 1:26 pm

If you have other software that successfully connects to the server, you can either instrument it or you can run a network sniffer at the same while you run it.

The network sniffer will easily pick out the IRC messages and you can see exactly what is being sent.
Then, the problem just becomes making sure the same exact message is sent from this IRC client.

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Wed Dec 20, 2017 12:15 am

HarlandGo wrote:Hi Dez, what's a network sniffer? I've never heard of that term before.


It's just a software tool you can run on your computer that will analyze all incoming/outgoing traffic on your network card.
You can use it to see exactly what is coming and going and one of the things its helpful for is debugging network software. You can learn a lot just by browsing the content of raw packets.

Here is one I have used before, that is free and fairly handy:
https://www.wireshark.org/#download

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Password protection on server

Postby Raiddevs » Tue Jan 16, 2018 7:22 pm

Changed server and no server password so connects now perfectly......but

on android the android keyboard opens whenever someone sends a message to the chat. Can the inputfield be changed to a standard text box or focus taken away from the inputfield?

emojis not supported???

how do i get coloured names for moderators???

apart from that we got it all working great and with a bit of fine tweaking this is gonna be awesome.

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Thu Jan 18, 2018 3:19 pm

Nice ^ _ ^

As far as emoji's and colored names, I am afraid those are outside of the purview of EasyIRC.
Code it up! :)

Let me know if you have any issues with EasyIRC and I will be happy to help.

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Password protection on server

Postby Raiddevs » Sat Jan 20, 2018 11:33 am

Thx. Not sure how to code emojis into this chat but wil probably find something out there on google to help. Looking at the scripts im thinking that you can use code to identify anyone in the user list with a @ ~ or & symbol and code a colour to that.(any ideas on this??? would be helpful and great addition to the code)

will look into it but thanks for the help and loving the chat so far

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Mon Jan 22, 2018 4:34 am

as far as emoji's I have used this gui package:
https://assetstore.unity.com/packages/t ... en-ui-2413

ngui is a pain in the ass in my view, but it does provide an easy way to add icons and custom characters to text.


As far as color, that is easy enough with default unity syntax <color=#123456>text</color> iirc.

good luck :)

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Coloured nicks and text

Postby Raiddevs » Tue Feb 06, 2018 2:05 pm

Still no joy with this :?

what im trying to do is set 2 colours for this chat.

Red - admins
Blue = moderators

both admin and moderators use an IRC client to monitor the chat (not from inside the game / EasyIRC)

Regular users messages and nicks are grey which has been set in the demo script you supplied.

ive set colours in IRC but still comes through to the EasyIRC as grey nick and grey message.

Getting frustrated.....

HELP

User avatar
dez
L.F.A. TEAM
Posts: 423
Joined: Thu Jun 02, 2005 11:16 pm
Contact:

Re: Password protection on server

Postby dez » Tue Feb 06, 2018 4:45 pm

>>ive set colours in IRC but still comes through to the EasyIRC as grey nick and grey message.

This has nothing to do with Easy IRC.
It has everything to do with whatever GUI system you are using to show the text.
What GUI system is it? Then you can look at the docs for that system and find your answer.
If it is Unity's default, then I already wrote the answer for you in the message above.

Raiddevs
New face
Posts: 7
Joined: Sun Nov 12, 2017 11:29 am

Re: Password protection on server

Postby Raiddevs » Wed Feb 07, 2018 4:58 pm

Its nothing to do with EasyIRC???

Mods and admins use Andchat, IRCcloud, AndroidIRC and many others on their phones.
Some connect through mIRC on their computers.

Everything for the EasyIRC was set up ok and works.

Using what you said "<color=#123456>TEXT</color> is fine but that only changes the colour of the TEXT you send NOT the username, plus, not typing all that every time we want to send a message to the EasyIRC.

i looked in the READ ME file you sent and was thinking i might have been able to set admin and mod messages there, using the parseIRCdata() but that didn't work either.

This is a total pain in the butt t.b.h and will just leave it all grey.


Return to “Easy IRC Chat”

Who is online

Users browsing this forum: No registered users and 1 guest