summaryrefslogtreecommitdiff
path: root/src/users.cpp
AgeCommit message (Collapse)Author
2007-02-191) Fix for nickname overruled with new cullList stuff -- we have to change ↵brain
their nick, its not safe to quit them as it messes up the nick hash. 2) Add a mute flag for users, so we can drop commands from users who have been placed on the cullList. This is independent of the actual cullList and can be used as a general mute flag e.g. by shun modules. 3) Fix /kill to also not quit the user immediately, remove need for CMD_USER_DELETED return anywhere in the code. *** THIS NEEDS TESTING BY QA *** git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6596 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-17Change /msg $* to have the correct source the same way /notice $* doesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6588 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-08Check for ::ffff:x.x.x.x ips in user resolver, and if we see one initiate an ↵brain
ipv4 PTR lookup rather than ipv6 git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6550 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-08"is now your hidden host" -> "is now your displayed host". Wording fits ↵brain
better when uncloaking git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6549 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-05Fix typobrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6505 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-05Fix for allowing dns lookups to work in mixed protocol modebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6504 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-05Now working in svn:brain
Client connections and port bindings on both ipv4 and ipv6 Server port bindings on both ipv4 and ipv6 Now broken due to this: cloaking (cloaks ipv4 users in an odd way when built as ipv6 enabled) DNS (query fd doesnt init properly) ...probably other stuff. Stay tuned. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6503 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-05Not safe for use yetbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6502 e03df62e-2008-0410-955e-edbf42e46eb7
2007-02-05Move quitting of clients to a central Cull List, and do quitting outside ↵peavey
userrec and in main loop. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6497 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-17Debug the spoutmouth outputbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6363 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-17Make this more sensiblebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6362 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-17Log client output, so we can actually see what we're sending out, and make ↵brain
more sense of stuff git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6361 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-15Crusade to remove debug from stable and tested parts of the core and base ↵brain
modules. Most of the code here being de-noised hasnt had a crash or bug in it for many months, if not a year so the debug output is useless noise in the logfile when trying to trace a bug in a REAL problem area. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6356 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-07Document dns caching, add a "bool cached" to OnLookupComplete method in ↵brain
Resolver, and and add " -- cached" to end of 'looking up your host' string if their result is a cached result git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6254 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-07DNS caching stuff (almost done)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6252 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-07DNS Stuff - this wont work right yet, it will soon (tm)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6250 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-07Move all /WHOWAS related out of core and into cmd_whowas.peavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6249 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-07Add TTL stuff to dns system (pass it to inherited objects)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6247 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-03Fix lusers breakage introduced by latest set of optimizationsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6219 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-03SirOlli gets credit for this fix, because he was the only one willing to ↵brain
work with us till we cracked it :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6218 e03df62e-2008-0410-955e-edbf42e46eb7
2007-01-02Fix for crash in desync of whowas lists on rehash. Also less mem leakage on ↵peavey
adding to whowas. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6217 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-31Cache invalidation in the wrong place, fixes FHOST remote host change bugbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6187 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-30Fix broken cloaking introduced by last commit (we need to invalidate the ↵brain
cache after setting the new string, not before) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6181 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-30Cached GetFullRealHost etc.brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6179 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-30Tweaks to instantiate less stuff when writing to a bunch of usersbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6172 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-30Tons of optimization of WriteChannel, WriteChannelWithServ, WriteCommon etc, ↵brain
dont call userrec::GetFullHost or snprintf for every item, call it just once. Turns O(n) calls for every write into O(~1) calls per write. Remove some debug from the socketengines which makes debugging hard on large channels (write availability message) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6171 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-30Add unregistered user counter, this may also fix the (minor) m_conn_lusers ↵brain
shows current connection as unregged git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6170 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-24Fix a bug in whowas that could desync list.peavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6091 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-24Fix loop when quitting multiple users (this is probably whats eating cpu)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6084 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-23Hash rehashing changebrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6080 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-22Remove useless debugbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6062 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-22Refactor connect allow/deny linesbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6061 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-21Proper fix for CS server crash, forgot to delete chanrec* from users ↵peavey
chanlist on PurgeEmptyChannels() git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6052 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-21Crude hotfix to what's been crashing chatspikepeavey
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6051 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-19When we handle a READ event on a user, return immediately.brain
This is because the read event may remove the user, in which case the !empty and quituser check below will address invalid data! git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6049 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-16Add stuff so that the core catches CoreException properlybrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6017 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-15Jesus, look who's the commit whore today. More header updates, and removal ↵w00t
of namespacing. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5996 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-15Try harder to make sure the ERROR string gets sent when closing a connectionbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5994 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-15Cleaning up irrelevent stuff in channels.cppbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5993 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14Remove misc debugbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5991 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14Fix silly bug of the day.brain
User was only getting a userrec::chans entry added if they had any privelages on the channel. If they werent opped, voiced, or halfopped on join, no entry in the hash. Silly brain now added a: user->chans[Ptr] = 0; :p git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5990 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14Change how users are quit if they get a write error during the things they do.brain
Instead of QuitUser inside FlushWriteBuffer() (potentially *UNSAFE*), go back to using SetWriteError(), but to ensure we dont get a cascade of bad write events from the socket engine, QuitUser the user before returning in userrec::HandleEvent, after we can gaurantee ALL other reading or writing is done. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5987 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14Refactor userrec::chans.brain
Old way: A vector of ucrec, MAXCHANS in size by default populated by NULLS, so you have to scan the vector to find an empty slot when joining a user, parting a user etc New way: std::map<chanrec*, char> (the char holds their basic core permissions on the channel [voice, halfop, op]) This increases speed a ton, and removes some wtf-age. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5986 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-14Refactoring:brain
1) Chain together a resize and an append, to improve the buffer read efficiency 2) eliminate a const char* pointer by doing it purely with string, saving a data copy 3) use iterators rather than ints and vector::size() for spooling motd and rules files to users 4) change a usage of !length() to empty() to make it more readable git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5985 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-13Improve the way 005 ISUPPORT is sent to users when they connect, cache it in ↵brain
a much more sane format which is much simpler to spool to them git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5978 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-12Improve how we handle ELINEs on connect, turn O(2n) into O(n) (thats the ↵brain
best we can do with g/k/z/q checks for now :( ) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5968 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-12New clone counting mechanism (this isnt tested yet)brain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5967 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-10Correctly handle write eventsbrain
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5920 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-10Fix bug found on barafranca, where quitting the user causes a cascade of ↵brain
error state notifications without actually quitting the user until much later, wasting cpu time git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5919 e03df62e-2008-0410-955e-edbf42e46eb7
2006-12-03Make this look less insane :Pw00t
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5835 e03df62e-2008-0410-955e-edbf42e46eb7