Asterisk silent brute force
Posted: Thu Aug 29, 2013 2:03 pm
Hi Guys,
I just encountered a brute force attempt on a box that wasn't throwing any errors into the CLI. It was using 1.4.44-vici that came with Vicibox 4.0.3. Has anyone experienced this yet? I strace'd asterisk and got this:
close(39) = 0
sendto(10, "SIP/2.0 100 Trying\r\nVia: SIP/2.0"..., 368, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, 16) = 368
sendto(10, "SIP/2.0 401 Unauthorized\r\nVia: S"..., 465, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, 16) = 465
poll([{fd=10, events=POLLIN}], 1, 1) = 1 ([{fd=10, revents=POLLIN}])
recvfrom(10, "REGISTER sip:209.X.X.X SIP/2."..., 4095, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, [16]) = 333
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 39
connect(39, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("198.7.57.40")}, 16) = 0
However nothing was showing in the logs or CLI for something like fail2ban to catch. They were probably running somewhere in the neighborhood of 1000 queries or more a second. Just wondering if anyone else has encountered this and if its just an issue with that version of asterisk. Unfortunately there are remotely logged in agents on this system and it needs to allow registration from outside.
I just encountered a brute force attempt on a box that wasn't throwing any errors into the CLI. It was using 1.4.44-vici that came with Vicibox 4.0.3. Has anyone experienced this yet? I strace'd asterisk and got this:
close(39) = 0
sendto(10, "SIP/2.0 100 Trying\r\nVia: SIP/2.0"..., 368, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, 16) = 368
sendto(10, "SIP/2.0 401 Unauthorized\r\nVia: S"..., 465, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, 16) = 465
poll([{fd=10, events=POLLIN}], 1, 1) = 1 ([{fd=10, revents=POLLIN}])
recvfrom(10, "REGISTER sip:209.X.X.X SIP/2."..., 4095, 0, {sa_family=AF_INET, sin_port=htons(5102), sin_addr=inet_addr("198.7.57.40")}, [16]) = 333
socket(PF_INET, SOCK_DGRAM, IPPROTO_IP) = 39
connect(39, {sa_family=AF_INET, sin_port=htons(5060), sin_addr=inet_addr("198.7.57.40")}, 16) = 0
However nothing was showing in the logs or CLI for something like fail2ban to catch. They were probably running somewhere in the neighborhood of 1000 queries or more a second. Just wondering if anyone else has encountered this and if its just an issue with that version of asterisk. Unfortunately there are remotely logged in agents on this system and it needs to allow registration from outside.