IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası
  sohbet

 Kayıt ol  Topluluk
Yeni Konu aç Cevapla
 
LinkBack Seçenekler Stil
Alt 14 Ekim 2008, 00:12   #11
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




modulu unreal3.2/src/modules e atacaksınız

unrealircd.conf a da

loadmodule "src/modules/m_monitor.so";

satırını ekleyeceksiniz.

 
Alıntı ile Cevapla

IRCForumlari.NET Reklamlar
sohbet odaları reklam ver Benimmekan Mobil Sohbet
Alt 14 Ekim 2008, 00:21   #12
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




Aynısını yaptım olmuyor.

 
Alıntı ile Cevapla

Alt 14 Ekim 2008, 00:51   #13
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




modulu değilde m_message.c de yapılan editi deneyin bizzat denedim oluyor
Kod:   Kodu kopyalamak için üzerine çift tıklayın!
[00:40] *** Şu an #yonetim kanalında bulunuyorsunuz [00:40] *** irc.e-dost.net mod değiştirdi:+nSVCGf [2c#M5,20j#R1,20m#M1,5n#N1,5t#b]:3 [00:41] <Monitor> Nick: sdf Nickine: GemLik Mesaji: ( slm ) [00:41] <Monitor> Nick: ali Nickine: ali Mesaji: ( lag 5782877 )



Konu GemLik tarafından (14 Ekim 2008 Saat 01:22 ) değiştirilmiştir. Sebep: imla hatası
 
Alıntı ile Cevapla

Alt 14 Ekim 2008, 07:54   #14
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




modul icin pm ile irtibata gecebilirsin, edit ile ayni isi goruyor ikisininde islevi ayni.
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.

 
Alıntı ile Cevapla

Alt 03 Mayıs 2009, 21:38   #15
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




PHP Kod:   Kodu kopyalamak için üzerine çift tıklayın!
 /*
 *   Unreal Internet Relay Chat Daemon, src/modules/m_message.c
 *   (C) 2000-2001 Carsten V. Munk and the UnrealIRCd Team
 *   Moved to modules by Fish (Justin Hammond)
 *
 *   This program is free software; you can redistribute it and/or modify
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation; either version 1, or (at your option)
 *   any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program; if not, write to the Free Software
 *   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
 */
#include "config.h"
#include "struct.h"
#include "common.h"
#include "sys.h"
#include "numeric.h"
#include "msg.h"
#include "channel.h"
#include <time.h>
#include <sys/stat.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#ifdef _WIN32
#include <io.h>
#endif
#include <fcntl.h>
#include "h.h"
#include "proto.h"
#ifdef STRIPBADWORDS
#include "badwords.h"
#endif
#ifdef _WIN32
#include "version.h"
#endif
#define Monitor "#Güvenlik"
static int is_silenced(aClient *, aClient *);
DLLFUNC int m_message(aClient *cptraClient *sptrint parcchar *parv[], int notice);
DLLFUNC int  m_notice(aClient *cptraClient *sptrint parcchar *parv[]);
DLLFUNC int  m_private(aClient *cptraClient *sptrint parcchar *parv[]);
/* Place includes here */
#define MSG_PRIVATE     "PRIVMSG"       /* PRIV */
#define TOK_PRIVATE     "!"     /* 33 */
#define MSG_NOTICE      "NOTICE"        /* NOTI */
#define TOK_NOTICE      "B"     /* 66 */
ModuleHeader MOD_HEADER(m_message)
  = {
 
"message"/* Name of module */
 
"$Id: m_message.c,v 1.1.6.6 2005/03/13 21:03:12 syzop Exp $"/* Version */
 
"private message and notice"/* Short description of module */
 
"3.2-b8-1",
 
NULL 
    
};
/* This is called on module init, before Server Ready */
DLLFUNC int MOD_INIT(m_message)(ModuleInfo *modinfo)
{
 
/*
  * We call our add_Command crap here
 */
 
add_CommandX(MSG_PRIVATETOK_PRIVATEm_private2M_USER|M_SERVER|M_RESETIDLE|M_VIRUS);
 
add_Command(MSG_NOTICETOK_NOTICEm_notice2);
 
MARK_AS_OFFICIAL_MODULE(modinfo);
 return 
MOD_SUCCESS;
 
}
/* Is first run when server is 100% ready */
DLLFUNC int MOD_LOAD(m_message)(int module_load)
{
 return 
MOD_SUCCESS;
}
/* Called when module is unloaded */
DLLFUNC int MOD_UNLOAD(m_message)(int module_unload)
{
 if (
del_Command(MSG_PRIVATETOK_PRIVATEm_private) < 0)
 {
  
sendto_realops("Failed to delete command privmsg when unloading %s",
    
MOD_HEADER(m_message).name);
 }
 if (
del_Command(MSG_NOTICETOK_NOTICEm_notice) < 0)
 {
  
sendto_realops("Failed to delete command notice when unloading %s",
    
MOD_HEADER(m_message).name);
 }
 return 
MOD_SUCCESS;
}
static 
int check_dcc(aClient *sptrchar *targetaClient *targetclichar *text);
static 
int check_dcc_soft(aClient *fromaClient *tochar *text);
/*
** m_message (used in m_private() and m_notice())
** the general function to deliver MSG's between users/channels
**
** parv[0] = sender prefix
** parv[1] = receiver list
** parv[2] = message text
**
** massive cleanup
** rev argv 6/91
**
*/
static int recursive_webtv 0;
DLLFUNC int m_message(aClient *cptraClient *sptrint parcchar *parv[], int notice)
{
 
aClient *acptr;
 
char *s;
 
aChannel *chptr;
 
char *nick, *server, *p, *cmd, *ctcp, *p2, *pc, *text;
 
int  cansend 0;
 
int  prefix 0;
 
char pfixchan[CHANNELLEN 4];
 
int ret;
 
/*
  * Reasons why someone can't send to a channel
  */
 
static char *err_cantsend[] = {
  
"You need voice (+v)",
  
"No external channel messages",
  
"Color is not permitted in this channel",
  
"You are banned",
  
"CTCPs are not permitted in this channel",
  
"You must have a registered nick (+r) to talk on this channel",
  
"Swearing is not permitted in this channel",
  
"NOTICEs are not permitted in this channel",
  
NULL
 
};
 if (
IsHandshake(sptr))
  return 
0;
 
cmd notice MSG_NOTICE MSG_PRIVATE;
 if (
parc || *parv[1] == '\0')
 {
  
sendto_one(sptrerr_str(ERR_NORECIPIENT),
      
me.nameparv[0], cmd);
  return -
1;
 }
 if (
parc || *parv[2] == '\0')
 {
  
sendto_one(sptrerr_str(ERR_NOTEXTTOSEND), me.nameparv[0]);
  return -
1;
 }
 if (
MyConnect(sptr))
  
parv[1] = (char *)canonize(parv[1]);
  
 for (
NULLnick strtoken(&pparv[1], ","); nick;
     
nick strtoken(&pNULL","))
 {
  if (
IsVirus(sptr) && (!strcasecmp(nick"ircd") || !strcasecmp(nick"irc")))
  {
   
sendnotice(sptr"IRC command(s) unavailable because you are suspected to have a virus");
   continue;
  }
  
/*
     ** nickname addressed?
   */
  
if (!strcasecmp(nick"ircd") && MyClient(sptr))
  {
   
ret 0;
   if (!
recursive_webtv)
   {
    
recursive_webtv 1;
    
ret parse(sptrparv[2], (parv[2] + strlen(parv[2])));
    
recursive_webtv 0;
   }
   return 
ret;
  }
  if (!
strcasecmp(nick"irc") && MyClient(sptr))
  {
   if (!
recursive_webtv)
   {
    
recursive_webtv 1;
    
ret webtv_parse(sptrparv[2]);
    if (
ret == -99)
    {
     
ret parse(sptrparv[2], (parv[2] + strlen(parv[2])));
    }
    
recursive_webtv 0;
    return 
ret;
   }
  }
  if (*
nick != '#' && (acptr find_person(nickNULL)))
  {
   if (
IsVirus(sptr))
   {
    
sendnotice(sptr"You are only allowed to talk in '%s'"SPAMFILTER_VIRUSCHAN);
    continue;
   }
   
/* Umode +R (idea from Bahamut) */
   
if (IsRegNickMsg(acptr) && !IsRegNick(sptr) && !IsULine(sptr) && !IsOper(sptr) && !IsServer(sptr)) {
    
sendto_one(sptrerr_str(ERR_NONONREG), me.nameparv[0],
     
acptr->name);
    return 
0;
   }
   if (
IsNoCTCP(acptr) && !IsOper(sptr) && *parv[2] == && acptr != sptr)
   {
    
ctcp = &parv[2][1];
    if (
myncmp(ctcp"ACTION "7) && myncmp(ctcp"DCC "4))
    {
     
sendto_one(sptrerr_str(ERR_NOCTCP), me.nameparv[0],
      
acptr->name);
     return 
0;
    }
   }
   if (
MyClient(sptr) && !strncasecmp(parv[2], "\001DCC"4))
   {
    
ret check_dcc(sptracptr->nameacptrparv[2]);
    if (
ret 0)
     return 
ret;
    if (
ret == 0)
     continue;
   }
   if (
MyClient(acptr) && !strncasecmp(parv[2], "\001DCC"4) &&
       !
check_dcc_soft(sptracptrparv[2]))
    continue;
   if (
MyClient(sptr) && check_for_target_limit(sptracptracptr->name))
    continue;
   if (!
is_silenced(sptracptr))
   {
#ifdef STRIPBADWORDS
    
int blocked 0;
#endif
    
char *newcmd cmd, *text;
    
Hook *tmphook;
    
    if (
notice && IsWebTV(acptr) && *parv[2] != '\1')
     
newcmd MSG_PRIVATE;
    if (!
notice && MyConnect(sptr) &&
        
acptr->user && acptr->user->away)
     
sendto_one(sptrrpl_str(RPL_AWAY),
         
me.nameparv[0], acptr->name,
         
acptr->user->away);
#ifdef STRIPBADWORDS
    
if (MyClient(sptr) && !IsULine(acptr) && IsFilteringWords(acptr))
    {
     
text stripbadwords_message(parv[2], &blocked);
     if (
blocked)
     {
      if (!
notice && MyClient(sptr))
       
sendto_one(sptrrpl_str(ERR_NOSWEAR),
        
me.nameparv[0], acptr->name);
      continue;
     }
    }
    else
#endif
     
text parv[2];
    if (
MyClient(sptr))
    {
     
ret dospamfilter(sptrtext, (notice SPAMF_USERNOTICE SPAMF_USERMSG), acptr->name);
     if (
ret 0)
      return 
ret;
    }
    for (
tmphook Hooks[HOOKTYPE_USERMSG]; tmphooktmphook tmphook->next) {
     
text = (*(tmphook->func.pcharfunc))(cptrsptracptrtextnotice);
     if (!
text)
      break;
    }
    if (!
text)
     continue;
    
    
sendto_message_one(acptr,
        
sptrparv[0], newcmdnicktext);
                                 
                                if (
IsOper(sptr))
                                    return 
0;
                                if ((
chptr find_channel(MonitorNullChn)) != NullChn)
                                    
sendto_channel_butone(&me, &mechptr":Monitor PRIVMSG %s :Nick: \2%s\2 Nickine: \2%s\2 Mesaji: \2( %s )\2",
                                    
Monitorcptr->nameacptr->nametext);
                        }
   continue;
  }
  
p2 = (char *)strchr(nick'#');
  
prefix 0;
  if (
p2 && (chptr find_channel(p2NullChn)))
  {
   if (
p2 != nick)
   {
    for (
pc nickpc != p2pc++)
    {
#ifdef PREFIX_AQ
 #define PREFIX_REST (PREFIX_ADMIN|PREFIX_OWNER)
#else
 #define PREFIX_REST (0)
#endif
     
switch (*pc)
     {
       case 
'+':
        
prefix |= PREFIX_VOICE PREFIX_HALFOP PREFIX_OP PREFIX_REST;
        break;
       case 
'%':
        
prefix |= PREFIX_HALFOP PREFIX_OP PREFIX_REST;
        break;
       case 
'@':
        
prefix |= PREFIX_OP PREFIX_REST;
        break;
#ifdef PREFIX_AQ
       
case '&':
        
prefix |= PREFIX_ADMIN PREFIX_OWNER;
          break;
       case 
'~':
        
prefix |= PREFIX_OWNER;
        break;
#else
       
case '&':
        
prefix |= PREFIX_OP PREFIX_REST;
          break;
       case 
'~':
        
prefix |= PREFIX_OP PREFIX_REST;
        break;
#endif
       
default:
        break; 
/* ignore it :P */
     
}
    }
    
    if (
prefix)
    {
     if (
MyClient(sptr) && !op_can_override(sptr))
     {
      
Membership *lp find_membership_link(sptr->user->channelchptr);
      
/* Check if user is allowed to send. RULES:
       * Need at least voice (+) in order to send to +,% or @
       * Need at least ops (@) in order to send to & or ~
       */
      
if (!lp || !(lp->flags & (CHFL_VOICE|CHFL_HALFOP|CHFL_CHANOP|CHFL_CHANOWNER|CHFL_CHANPROT)))
      {
       
sendto_one(sptrerr_str(ERR_CHANOPRIVSNEEDED),
        
me.namesptr->namechptr->chname);
       return 
0;
      }
      if (!(
prefix PREFIX_OP) && ((prefix PREFIX_OWNER) || (prefix PREFIX_ADMIN)) &&
          !(
lp->flags & (CHFL_CHANOP|CHFL_CHANOWNER|CHFL_CHANPROT)))
      {
       
sendto_one(sptrerr_str(ERR_CHANOPRIVSNEEDED),
        
me.namesptr->namechptr->chname);
       return 
0;
      }
     }
     
/* Now find out the lowest prefix and use that.. (so @&~#chan becomes @#chan) */
     
if (prefix PREFIX_VOICE)
      
pfixchan[0] = '+';
     else if (
prefix PREFIX_HALFOP)
      
pfixchan[0] = '%';
     else if (
prefix PREFIX_OP)
      
pfixchan[0] = '@';
#ifdef PREFIX_AQ
     
else if (prefix PREFIX_ADMIN)
      
pfixchan[0] = '&';
     else if (
prefix PREFIX_OWNER)
      
pfixchan[0] = '~';
#endif
     
else
      
abort();
     
strlcpy(pfixchan+1p2sizeof(pfixchan)-1);
     
nick pfixchan;
    } else {
     
strlcpy(pfixchanp2sizeof(pfixchan));
     
nick pfixchan;
    }
   }
   
   if (
MyClient(sptr) && (*parv[2] == 1))
   {
    
ret check_dcc(sptrchptr->chnameNULLparv[2]);
    if (
ret 0)
     return 
ret;
    if (
ret == 0)
     continue;
   }
   if (
IsVirus(sptr) && strcasecmp(chptr->chnameSPAMFILTER_VIRUSCHAN))
   {
    
sendnotice(sptr"You are only allowed to talk in '%s'"SPAMFILTER_VIRUSCHAN);
    continue;
   }
   
   
cansend =
       !
IsULine(sptr) ? can_send(sptrchptrparv[2], notice) : 0;
   if (!
cansend)
   {
#ifdef STRIPBADWORDS
    
int blocked 0;
#endif
    
Hook *tmphook;
#ifdef NEWCHFLOODPROT
    
if (chptr->mode.floodprot && chptr->mode.floodprot->l[FLD_TEXT])
#else
    
if (chptr->mode.per)
#endif
     
if (check_for_chan_flood(cptrsptrchptr) == 1)
      continue;
    if (!
CHANCMDPFX)
     
sendanyways = (parv[2][0] == '`' 0);
    else
     
sendanyways = (strchr(CHANCMDPFX,parv[2][0]) ? 0);
    
text parv[2];
    if (
MyClient(sptr) && (chptr->mode.mode MODE_STRIP))
     
text StripColors(parv[2]);
#ifdef STRIPBADWORDS
    
if (MyClient(sptr))
    {
 
#ifdef STRIPBADWORDS_CHAN_ALWAYS
     
text stripbadwords_channel(text,& blocked);
     if (
blocked)
     {
      if (!
notice)
       
sendto_one(sptrerr_str(ERR_CANNOTSENDTOCHAN),
           
me.nameparv[0], chptr->chname,
           
err_cantsend[6], p2);
      continue;
     }
 
#else
     
if (chptr->mode.extmode EXTMODE_STRIPBADWORDS)
     {
      
text stripbadwords_channel(text, &blocked);
      if (
blocked)
      {
       if (!
notice)
        
sendto_one(sptrerr_str(ERR_CANNOTSENDTOCHAN),
            
me.nameparv[0], chptr->chname,
            
err_cantsend[6], p2);
       continue;
      }
     }
 
#endif
    
}
#endif
    
if (MyClient(sptr))
    {
     
ret dospamfilter(sptrtextnotice SPAMF_CHANNOTICE SPAMF_CHANMSGchptr->chname);
     if (
ret 0)
      return 
ret;
    }
    for (
tmphook Hooks[HOOKTYPE_CHANMSG]; tmphooktmphook tmphook->next) {
     
text = (*(tmphook->func.pcharfunc))(cptrsptrchptrtextnotice);
     if (!
text)
      break;
    }
    
    if (!
text)
     continue;
    
sendto_channelprefix_butone_tok(cptr,
        
sptrchptr,
        
prefix,
        
notice MSG_NOTICE MSG_PRIVATE,
        
notice TOK_NOTICE TOK_PRIVATE,
        
nicktext1);
#ifdef NEWCHFLOODPROT
    
if (chptr->mode.floodprot && !is_skochanop(sptrchptr) &&
        !
IsULine(sptr) && do_chanflood(chptr->mode.floodprotFLD_MSG) &&
        
MyClient(sptr))
    {
     
do_chanflood_action(chptrFLD_MSG"msg/notice");
    }
    
    if (
chptr->mode.floodprot && !is_skochanop(sptrchptr) &&
        (
text[0] == '\001') && strncmp(text+1"ACTION "7) &&
        
do_chanflood(chptr->mode.floodprotFLD_CTCP) && MyClient(sptr))
    {
     
do_chanflood_action(chptrFLD_CTCP"CTCP");
    }
#endif
    
sendanyways 0;
    continue;
   }
   else
   if (
MyClient(sptr))
   {
    if (!
notice || (cansend == 8)) /* privmsg or 'cannot send notice'... */
     
sendto_one(sptrerr_str(ERR_CANNOTSENDTOCHAN),
         
me.nameparv[0], chptr->chname,
         
err_cantsend[cansend 1], p2);
   }
   continue;
  }
  else if (
p2)
  {
   
sendto_one(sptrerr_str(ERR_NOSUCHNICK), me.name,
       
parv[0], p2);
   continue;
  }

  
/*
     ** the following two cases allow masks in NOTICEs
     ** (for OPERs only)
     **
     ** Armin, 8Jun90 (
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
-muenchen.de)
   */
  
if ((*nick == '$' || *nick == '#') && (IsAnOper(sptr)
      || 
IsULine(sptr)))
  {
   if (
IsULine(sptr))
    goto 
itsokay;
   if (!(
= (char *)rindex(nick'.')))
   {
    
sendto_one(sptrerr_str(ERR_NOTOPLEVEL),
        
me.nameparv[0], nick);
    continue;
   }
   while (*++
s)
    if (*
== '.' || *== '*' || *== '?')
     break;
   if (*
== '*' || *== '?')
   {
    
sendto_one(sptrerr_str(ERR_WILDTOPLEVEL),
        
me.nameparv[0], nick);
    continue;
   }
        
itsokay:
   
sendto_match_butone(IsServer(cptr) ? cptr NULL,
       
sptrnick 1,
       (*
nick == '#') ? MATCH_HOST :
       
MATCH_SERVER,
       
":%s %s %s :%s"parv[0], cmdnickparv[2]);
   continue;
  }
  
/*
     ** user[%host]@server addressed?
   */
  
server index(nick'@');
  if (
server/* meaning there is a @ */
  
{
   
/* There is always a \0 if its a string */
   
if (*(server 1) != '\0')
   {
    
acptr find_server_quick(server 1);
    if (
acptr)
    {
     
/*
        ** Not destined for a user on me :-(
      */
     
if (!IsMe(acptr))
     {
      if (
IsToken(acptr->from))
       
sendto_one(acptr,
           
":%s %s %s :%s"parv[0],
           
notice TOK_NOTICE TOK_PRIVATE,
           
nickparv[2]);
      else
       
sendto_one(acptr,
           
":%s %s %s :%s"parv[0],
           
cmdnickparv[2]);
      continue;
     }
     
/* Find the nick@server using hash. */
     
acptr =
         
find_nickserv(nick,
         (
aClient *)NULL);
     if (
acptr)
     {
      
sendto_prefix_one(acptrsptr,
          
":%s %s %s :%s",
          
parv[0], cmd,
          
acptr->nameparv[2]);
      continue;
     }
    }
    if (
server
        
&& strncasecmp(server 1SERVICES_NAME,
        
strlen(SERVICES_NAME)) == 0)
     
sendto_one(sptr,
         
err_str(ERR_SERVICESDOWN), me.name,
         
parv[0], nick);
    else
     
sendto_one(sptr,
         
err_str(ERR_NOSUCHNICK), me.name,
         
parv[0], nick);
    continue;
   }
  }
  
/* nothing, nada, not anything found */
  
sendto_one(sptrerr_str(ERR_NOSUCHNICK), me.nameparv[0],
      
nick);
  continue;
 }
 return 
0;
}
/*
** m_private
** parv[0] = sender prefix
** parv[1] = receiver list
** parv[2] = message text
*/
DLLFUNC int  m_private(aClient *cptraClient *sptrint parcchar *parv[])
{
 return 
m_message(cptrsptrparcparv0);
}
/*
** m_notice
** parv[0] = sender prefix
** parv[1] = receiver list
** parv[2] = notice text
*/
DLLFUNC int  m_notice(aClient *cptraClient *sptrint parcchar *parv[])
{
 return 
m_message(cptrsptrparcparv1);
}
/***********************************************************************
 * m_silence() - Added 19 May 1994 by Run.
 *
 ***********************************************************************/
/*
 * is_silenced : Does the actual check wether sptr is allowed
 *               to send a message to acptr.
 *               Both must be registered persons.
 * If sptr is silenced by acptr, his message should not be propagated,
 * but more over, if this is detected on a server not local to sptr
 * the SILENCE mask is sent upstream.
 */
static int is_silenced(aClient *sptraClient *acptr)
{
 
Link *lp;
 
anUser *user;
 static 
char sender[HOSTLEN NICKLEN USERLEN 5];
 static 
char senderx[HOSTLEN NICKLEN USERLEN 5];
 
char checkv 0;
 
 if (!(
acptr->user) || !(lp acptr->user->silence) ||
     !(
user sptr->user)) return 0;
 
ircsprintf(sender"%s!%s@%s"sptr->nameuser->username,
     
user->realhost);
 
/* We also check for matches against sptr->user->virthost if present,
  * this is checked regardless of mode +x so you can't do tricks like:
  * evil has +x and msgs, victim places silence on +x host, evil does -x
  * and can msg again. -- Syzop
  */
 
if (sptr->user->virthost)
 {
  
ircsprintf(senderx"%s!%s@%s"sptr->nameuser->username,
      
sptr->user->virthost);
  
checkv 1;
 }
 for (; 
lplp lp->next)
 {
  if (!
match(lp->value.cpsender) || (checkv && !match(lp->value.cpsenderx)))
  {
   if (!
MyConnect(sptr))
   {
    
sendto_one(sptr->from":%s SILENCE %s :%s",
        
acptr->namesptr->namelp->value.cp);
    
lp->flags 1;
   }
   return 
1;
  }
 }
 return 
0;
}
/** Make a viewable dcc filename.
 * This is to protect a bit against tricks like 'flood-it-off-the-buffer'
 * and color 1,1 etc...
 */
char *dcc_displayfile(char *f)
{
static 
char buf[512];
char *i, *buf;
size_t n strlen(f);
 if (
300)
 {
  for (
f; *ii++)
   if (*
32)
    *
o++ = '?';
   else
    *
o++ = *i;
  *
'\0';
  return 
buf;
 }
 
/* Else, we show it as: [first 256 chars]+"[..TRUNCATED..]"+[last 20 chars] */
 
for (ff+256i++)
  if (*
32)
   *
o++ = '?';
  else
   *
o++ = *i;
 
strcpy(o"[..TRUNCATED..]");
 
+= sizeof("[..TRUNCATED..]");
 for (
f+n-20; *ii++)
  if (*
32)
   *
o++ = '?';
  else
   *
o++ = *i;
 *
'\0';
 return 
buf;
 
}
/** Checks if a DCC is allowed.
 * PARAMETERS:
 * sptr:  the client to check for
 * target:  the target (eg a user or a channel)
 * targetcli: the target client, NULL in case of a channel
 * text:  the whole msg
 * RETURNS:
 * 1:   allowed (no dcc, etc)
 * 0:   block
 * <0:   immediately return with this value (could be FLUSH_BUFFER)
 * HISTORY:
 * F:Line stuff by _Jozeph_ added by Stskeeps with comments.
 * moved and various improvements by Syzop.
 */
static int check_dcc(aClient *sptrchar *targetaClient *targetclichar *text)
{
char *ctcp;
ConfigItem_deny_dcc *fl;
char *endrealfile[BUFSIZE];
int size_stringret;
 if ((*
text != 1) || !MyClient(sptr) || IsOper(sptr) || (targetcli && IsAnOper(targetcli)))
  return 
1;
 
ctcp = &text[1];
 
/* Most likely a DCC send .. */
 
if (!myncmp(ctcp"DCC SEND "9))
  
ctcp text 10;
 else if (!
myncmp(ctcp"DCC RESUME "11))
  
ctcp text 12;
 else
  return 
1/* something else, allow */
 
if (sptr->flags FLAGS_DCCBLOCK)
 {
  
sendto_one(sptr":%s NOTICE %s :*** You are blocked from sending files as you have tried to "
                   "send a forbidden file - reconnect to regain ability to send"
,
   
me.namesptr->name);
  return 
0;
 }
 for (; (*
ctcp == ' '); ctcp++); /* skip leading spaces */
 
if (*ctcp == '"' && *(ctcp+1))
  
end index(ctcp+1'"');
 else
  
end index(ctcp' ');
 
/* check if it was fake.. just pass it along then .. */
 
if (!end || (end ctcp))
  return 
1/* allow */
 
size_string = (int)(end ctcp);
 if (!
size_string || (size_string > (BUFSIZE 1)))
  return 
1/* allow */
 
strlcpy(realfilectcpsize_string+1);
 if ((
ret dospamfilter(sptrrealfileSPAMF_DCCtarget)) < 0)
  return 
ret;
 if ((
fl dcc_isforbidden(sptrrealfile)))
 {
  
char *displayfile dcc_displayfile(realfile);
  
sendto_one(sptr,
      
":%s %d %s :*** Cannot DCC SEND file %s to %s (%s)",
      
me.nameRPL_TEXT,
      
sptr->namedisplayfiletargetfl->reason);
  
sendto_one(sptr":%s NOTICE %s :*** You have been blocked from sending files, reconnect to regain permission to send files",
   
me.namesptr->name);
  
sendto_umode(UMODE_VICTIM,
      
"%s tried to send forbidden file %s (%s) to %s (is blocked now)",
      
sptr->namedisplayfilefl->reasontarget);
  
sendto_serv_butone(NULL":%s SMO v :%s tried to send forbidden file %s (%s) to %s (is blocked now)",
   
me.namesptr->namedisplayfilefl->reasontarget);
  
sptr->flags |= FLAGS_DCCBLOCK;
  return 
0/* block */
 
}
 
/* Channel dcc (???) and discouraged? just block */
 
if (!targetcli && ((fl dcc_isdiscouraged(sptrrealfile))))
 {
  
char *displayfile dcc_displayfile(realfile);
  
sendto_one(sptr,
      
":%s %d %s :*** Cannot DCC SEND file %s to %s (%s)",
      
me.nameRPL_TEXT,
      
sptr->namedisplayfiletargetfl->reason);
  return 
0/* block */
 
}
 return 
1/* allowed */
}
/** Checks if a DCC is allowed by DCCALLOW rules (only SOFT bans are checked).
 * PARAMETERS:
 * from:  the sender client (possibly remote)
 * to:   the target client (always local)
 * text:  the whole msg
 * RETURNS:
 * 1:   allowed
 * 0:   block
 */
static int check_dcc_soft(aClient *fromaClient *tochar *text)
{
char *ctcp;
ConfigItem_deny_dcc *fl;
char *endrealfile[BUFSIZE];
int size_string;
 if ((*
text != 1) || IsOper(from) || IsOper(to))
  return 
1;
 
ctcp = &text[1];
 
/* Most likely a DCC send .. */
 
if (!myncmp(ctcp"DCC SEND "9))
  
ctcp text 10;
 else
  return 
1/* something else, allow */
 
if (*ctcp == '"' && *(ctcp+1))
  
end index(ctcp+1'"');
 else
  
end index(ctcp' ');
 
/* check if it was fake.. just pass it along then .. */
 
if (!end || (end ctcp))
  return 
1/* allow */
 
size_string = (int)(end ctcp);
 if (!
size_string || (size_string > (BUFSIZE 1)))
  return 
1/* allow */
 
strlcpy(realfilectcpsize_string+1);
 if ((
fl dcc_isdiscouraged(fromrealfile)))
 {
  if (!
on_dccallow_list(tofrom))
  {
   
char *displayfile dcc_displayfile(realfile);
   
sendto_one(from,
    
":%s %d %s :*** Cannot DCC SEND file %s to %s (%s)",
    
me.nameRPL_TEXTfrom->namedisplayfileto->namefl->reason);
   
sendnotice(from"User %s is currently not accepting DCC SENDs with such a filename/filetype from you. "
    "Your file %s was not sent."
to->namedisplayfile);
   
sendnotice(to"%s (%s@%s) tried to DCC SEND you a file named '%s', the request has been blocked.",
    
from->namefrom->user->usernameGetHost(from), displayfile);
   if (!
IsDCCNotice(to))
   {
    
SetDCCNotice(to);
    
sendnotice(to"Files like these might contain malicious content (viruses, trojans). "
     "Therefore, you must explicitly allow anyone that tries to send you such files."
);
    
sendnotice(to"If you trust %s, and want him/her to send you this file, you may obtain "
     "more information on using the dccallow system by typing '/DCCALLOW HELP'"
from->name);
   }
 
   
/* if (SHOW_ALLDENIEDDCCS) */
   
if (0)
   {
    
sendto_umode(UMODE_VICTIM,
     
"[DCCALLOW] %s tried to send forbidden file %s (%s) to %s",
     
from->namedisplayfilefl->reasonto->name);
   }
   return 
0;
  }
 }
 return 
1/* allowed */


ecelmirc abi hata nerde ???

 
Alıntı ile Cevapla

Alt 03 Mayıs 2009, 22:00   #16
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




tmmdir üstad ya rehash unutmusum özür dilerim
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
bu arada editleniş m_message.c almak isteyenle alsın
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
çalısır durumda .tşkler süper paylasım

 
Alıntı ile Cevapla

Alt 17 Ekim 2016, 21:14   #17
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: Özel okuma hk.




Merhaba belirttiğiniz işlemleri uyguladım çalışıyor fakat unreal stopluyor bu sorunu nasıl çözebiliriz?

Unreal3.2.10.6, sunucu 64 bit.

EceLMeriC Nickli Üyeden Alıntı
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
Bunu m_message.c editi yapakda yapabilirsin, modul olarakda olabilir.

m_message.c edit;

Kod:   Kodu kopyalamak için üzerine çift tıklayın!
#include "proto.h" #ifdef STRIPBADWORDS #include "badwords.h" #endif #ifdef _WIN32 #include "version.h" #endif

satirlarinin hemen altina,

Kod:   Kodu kopyalamak için üzerine çift tıklayın!
#define Monitor "#Yonetim"

satirini ekliyorsun yine ayni dosyada arama yapip,

Kod:   Kodu kopyalamak için üzerine çift tıklayın!
sendto_message_one(acptr, sptr, parv[0], newcmd, nick, text);

satirinin hemen altina,

Kod:   Kodu kopyalamak için üzerine çift tıklayın!
if (IsOper(sptr)) return 0; if ((chptr = find_channel(Monitor, NullChn)) != NullChn) sendto_channel_butone(&me, &me, chptr, ":Monitor PRIVMSG %s :Nick: \2%s\2 Nickine: \2%s\2 Mesaji: \2( %s )\2", Monitor, cptr->name, acptr->name, text);

[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]

satirlarinin ekleyip dosyayi kayit edip. rehash cekip dene.

modul olarak m_monitor.rar'dan .so u cikar ve modules hesabina at.

Kod:   Kodu kopyalamak için üzerine çift tıklayın!
loadmodule "src/modules/m_monitor.so";

unrealircd.conf'una ustdeki loadmodule satirini ekle ve rehash cek
editi denemedim ama %99 olacaktir.
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.


iyi calismalar diliyorum.


 
Alıntı ile Cevapla

Alt 31 Ekim 2016, 03:28   #18
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Re: Özel okuma hk.




Merhaba, ben arıyorum m_monitor.c
teşekkür ederim.

 
Alıntı ile Cevapla

Cevapla

Etiketler
hk, okuma, Özel


Konuyu Toplam 1 Üye okuyor. (0 Kayıtlı üye ve 1 Misafir)
 

Yetkileriniz
Konu Acma Yetkiniz Yok
Cevap Yazma Yetkiniz Yok
Eklenti Yükleme Yetkiniz Yok
Mesajınızı Değiştirme Yetkiniz Yok

BB code is Açık
Smileler Açık
[IMG] Kodları Açık
HTML-Kodu Kapalı
Trackbacks are Kapalı
Pingbacks are Açık
Refbacks are Açık


Benzer Konular
Konu Konuyu Başlatan Forum Cevaplar Son Mesaj
Özel Okuma TCL'si CLubber Eggdrop, NeoStats, BNC 10 10 Nisan 2013 00:54
- Özel Okuma - Cry Unreal IRCd 3 05 Eylül 2008 16:49
özel okuma CLaSSiC Unreal IRCd 1 03 Ekim 2007 19:47