Configurando Sonicwall via CLI

Por: Dr. Delso Bonfante | July 10, 2013

Configurando Sonicwall via CLI

Olá, meu nome é Diego Luisi e no artigo de hoje demonstrarei alguns comandos de como criar regras no SONICWALL usando o SSH.

Criando um Serviço

configure
service
add "SMTPS_587_TCP"
ip-type 6
port-begin 587
port-end 587
end
finished

Exemplo de IP-TYPES

Please provide the ip-type parameter. Acceptable values are:/s
1(ICMP),
2(IGMP),
6,(TCP),
17(UDP)
47(GRE),
50(ESP),
51(AH),
88(EIGRP),
89(OSPF),
103(PIMSM),
115(L2TP).

Criando Grupos de Serviços

configure
service-group
add <nome_do_grupo> # nome do grupo
service SMTPS_587_TCP # Adicionando serviços criados anteriormente
service SMTP
service FTP
end

Criando o Objeto

configure
address-object "NOME DO OBJETO"
host
zone LAN #AQUI VC TROCA A ZONA
end

Criando Grupos de Objetos

configure
address-group "GRUPO-TESTE"
address-object "HOST-MAIL01"
address-object "HOST-MAIL02"
address-object "GROUP-SERVIDORES"
address-object "HOST-NB-DIRETORI"
end

Criando política de NAT

configure
nat
add
orig-src Any # # ou de enter para que seja Mostrado uma lista de objetos disponíveis
trans-src Original
orig-dst "WAN Primary IP" # OU UM OBJETO CRIADO ANTERIORMENTE
trans-dst WEB_SERVER_IIS
orig-svc HTTP
trans-svc Original
inbound-interface Any
outbound-interface Any
comment "NAT CRIADA VIA CLI"
info # Com o Comando info, vc verifica como a regra ficou
end
finished

Um agradecimento especial ao Ernander Marcus Lataliza Rosendo pela colaboração neste artigo.

CSSA

CSSA

 

 

 

 


LOREM

dluisi

🚀 Enthusiastic about the DevOps culture and focused on Open Source technologies, I am passionate about automation, with 20 years of experience as a SysAdmin, currently working as an SRE, always open to learning new technologies and procedures to improve every day more as a professional. 👀 I’m interested in Open Source projects (Linux, CNCF, GitOps and Tools) 📚 I’m currently increasing my skills on AWS, K8S, Python, Backstage and some automations tools like Argo (CD, Autopilot, Events, Rollouts and Workflows). 🌱 Goals: Increase my programming skills. 💞 I love old and good Rock and Roll, on weekends traveling on a Harley Davidson.