+ Responder ao Tópico



  1. #1
    fjacunha
    Visitante

    Padrão Snort Bloqueia arquivos em anexos enviados por E-mail

    Galera estou com um pequeno probleminha, nadei dando um procurada na documentação das regras do snort mias não consigo solucionar o problemas, aparentemente a virus.rules sai bloqueando tudo que é em aenexo. Estou precisando liberar só o envio dos arquivos, PPS, PPT, e RTF via smtp. mais não estou sabendo fazer a implementação da regra no virus.rules
    segue uma copia do meu virus.rules
    Alguém poderia me ajudar.
    Agradeço antecipadamente
    Francisco Cunha

    # Copyright 2001-2005 Sourcefire, Inc. All Rights Reserved
    #
    # This file may contain proprietary rules that were created, tested and
    # certified by Sourcefire, Inc. (the "VRT Certified Rules") as well as
    # rules that were created by Sourcefire and other third parties and
    # distributed under the GNU General Public License (the "GPL Rules"). The
    # VRT Certified Rules contained in this file are the property of
    # Sourcefire, Inc. Copyright 2005 Sourcefire, Inc. All Rights Reserved.
    # The GPL Rules created by Sourcefire, Inc. are the property of
    # Sourcefire, Inc. Copyright 2002-2005 Sourcefire, Inc. All Rights
    # Reserved. All other GPL Rules are owned and copyrighted by their
    # respective owners (please see www.snort.org/contributors for a list of
    # owners and their respective copyrights). In order to determine what
    # rules are VRT Certified Rules or GPL Rules, please refer to the VRT
    # Certified Rules License Agreement.
    #
    #
    # $Id: virus.rules,v 1.28.2.1.2.1 2005/05/16 22:17:52 mwatchinski Exp $
    #------------
    # VIRUS RULES
    #------------
    #
    # We don't care about virus rules anymore. BUT, you people won't stop asking
    # us for virus rules. So... here ya go.
    #
    # There is now one rule that looks for any of the following attachment types:
    #
    # ade, adp, asd, asf, asx, bat, chm, cli, cmd, com, cpp, diz, dll, dot, emf,
    # eml, exe, hlp, hsq, hta, ini, js, jse, lnk, mda, mdb, mde, mdw, msi, msp,
    # nws, ocx, pif, pl, pm, pot, pps, ppt, reg, rtf, scr, shs, swf, sys, vb,
    # vbe, vbs, vcf, vxd, wmd, wmf, wms, wmz, wpd, wpm, wps, wpz, wsc, wsf, wsh,
    # xlt, xlw
    #

    alert tcp $HOME_NET any -> $EXTERNAL_NET 25 (msg:"**reset** VIRUS OUTBOUND bad file attachment"; flow:to_server,established; content:"Content-Disposition|3A|"; nocase; pcre:"/filename\s*=\s*.*?\.(?=[abcdehijlmnoprsvwx])(a(d[ep]|s[dfx])|c([ho]m|li|md|pp)|d(iz|ll|ot)|e(m[fl]|xe)|h(lp|sq|ta)|jse?|m(d[abew]|s[ip])|p(p[st]|if|[lm]|ot)|r(eg|tf)|s(cr|[hy]s|wf)|v(b[es]?|cf|xd)|w(m[dfsz]|p[dmsz]|s[cfh])|xl[tw]|bat|ini|lnk|nws|ocx)[\x27\x22\n\r\s]/iR"; classtype:suspicious-filename-detect; sid:721; rev:8; resp:rst_all

  2. #2

    Padrão Snort Bloqueia arquivos em anexos enviados por E-mail

    cara o seguinte cada conjunto de letras entre | | especifica um tipo de extensão, ae depois o conjunto que tiver dentro disso especifica o tipo de anexo ex: aqui ele esta barrando pps e ppt |p(p[st]| então se quiser so deixar pps vc tira o t de dentro das [] e pronto.

    falows

  3. #3
    fjacunha
    Visitante

    Padrão Snort Bloqueia arquivos em anexos enviados por E-mail

    Ruyneto

    Cara, funcionou, como eu não pensei nisso!! heheheh Obrigado mesmo, pela força, devia ter prestado mais atenção nesse arquivo.

    Abraços
    Chico

  4. #4

    Padrão Snort Bloqueia arquivos em anexos enviados por E-mail

    Tranquilo, é que a primeira vista ele pareçe mesmo complicado mesmo, mas se prestar atenção da de manjar, mas qq coisa so postar ae no forum que o pessoal ajuda, e tambem visite o wiki e se der poste algo tb lá, under-linux.org/wiki


    falows