This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Invited or not? - that is the question...

Old posts that have not been replied to for several years.
Locked
P
Photon
Op
Posts: 170
Joined: Wed Aug 28, 2002 8:00 am
Location: Liverpool, England

Invited or not? - that is the question...

Post by Photon »

Hi .. this may be one for the official mail list, but we'll see...

I'm writing a piece of code to invite users to any invite only channels the bot knows about as they auth. I'm doing this with a piece of code such as the following :

Code: Select all

if (u_addinvite(chan, invite, from, cmt, expire_time,sticky))
      add_mode(chan, '+', 'I', invite);
Thing is I'm then telling all the other bots on the net to invite the user to any channels they know of the user in that are invite only... so if there are two bots in the same channel, then there stands a chance of the user getting two invites to the same channel.
  • 1. Is this dangerous? or just messy? I couldnt see any safety in u_addinvite to prevent this happening. I'm assuming ircD has the sense not to print a 'user invited you to #blah' message twice... although it IS a different user... hmm.

    2. How can I tell if a user already has an invite to this channel? After searching the tellinvite (display invites on channel code) I got a bit confused - I know how to find the invites section in the channel structure, but I'm not sure how you tell what relates to whom...
t
tainted
Master
Posts: 239
Joined: Sun May 12, 2002 8:00 pm
Location: chicago
Contact:

Post by tainted »

Well some networks I believe use a channel mode for invites, but another way could be to pick a random bot (not too hard to code) and make just that one bot do the invite. On efnet at least, you will get invites from every user/bot that invites you. On a large botnet that would be very messy, not to mention unnessesary.
P
Photon
Op
Posts: 170
Joined: Wed Aug 28, 2002 8:00 am
Location: Liverpool, England

Post by Photon »

Yeah .. as has already been pointed out to me the mode trick may not work with most ircD's - I assumed it did, 'cos of the way eggdrop does it internally... back to good old fashioned

Code: Select all

dprintf(DP_SERVER, "INVITE %s %s\n", pNick, pChan->name);
methinks.

the point of passing it across the botnet was this.

Bot clank sits in #Clank, bot clunk sits in #clunk. Both channels are +i, and the user in question is an op/voice in both of them. When this user auths with Clank, then he will get invited to #Clank and #Clunk without having to seperately auth with both Clank and Clunk. Make sense?

What I could do, of course is pass across the botnet the channels I have already invited the user to. Makes life easier I suppose.
Locked