*** res.c       Thu Apr  5 07:40:08 2001
--- res.c       Thu Apr  5 07:44:13 2001
***************
*** 1579,1584 ****
--- 1579,1600 ----
                aCache  *cp;
        int     i;
  
+        /* only let opers spew the dns cache, with a bit of initiative
+           a user could match partial hostnames/ips of a user with the
+           list from here and their masked host.
+ 
+           thanks for FiRE for pointing this bug/error/feature out :D
+            -- ph3wl 4/4/01
+         */
+        if (!IsServer(sptr) && !IsOper(sptr) && !IsMe(sptr)) {
+               sendto_one(sptr, err_str(ERR_NOPRIVILEGES), me.name, parv[0]);
+               return 0;
+       }
+ 
        if (parv[1] && *parv[1] == 'l') {
                for(cp = cachetop; cp; cp = cp->list_next)
                    {
