Giter VIP home page Giter VIP logo

anadrop's Introduction

anadrop - geração automatizada de script DNS RPZ from url do pdf da Anatel

  • Baixa arquivo pdf da url enviada pela Anatel
  • Extrair as URLS para serem bloqueadas
  • Gerar arqvuivo para DNS bind, para uso do PTZ

Para rodar via prompt de comando:

  cd /anatel
  ./import_from_url.py https://sistemas.anatel.gov.br/anexar-api/publico/anexos/download/5e68ae83f4826fdb20f8f553447008f3

Para rodar localmente:

  Coloque o arquivo PDF baixado da url da Anatel em /anatel
  cd /anatel
  ./import_from_file.py arquivo.pdf

Para baixar o arquivo DNS pronto para uso:

http://anadrop.mycore.com.br:1984/anadrop

Conteúdo anadrop.sh:

  • local do script no bind [ /etc/bind/scripts/anadrop.sh ]:

#!/bin/sh wget --no-check-certificate --tries=3000 --retry-connrefused --timeout=10 --dns-timeout=8 --wait=7 --waitretry=3 http://anadrop.mycore.com.br:1984/anadrop -O /etc/bind/rpz/db.rpz.zone.hosts systemctl restart bind9

Crontab:

echo '00 00 \* \* \* root sh /etc/bind/scripts/anadrop.sh' >> /etc/crontab

anadrop © 2024, Mycore Tecnologia - Released under the MIT License.

anadrop's People

Contributors

marcioaraujo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.