Skip to content

Instantly share code, notes, and snippets.

@nicolov
Created July 10, 2016 11:05
Show Gist options
  • Save nicolov/42664c615621aae026dbdef365d5eabd to your computer and use it in GitHub Desktop.
Save nicolov/42664c615621aae026dbdef365d5eabd to your computer and use it in GitHub Desktop.
Get SIP credentials for Telecom Italia softphone
#!/usr/bin/env bash
# Thanks http://superuser.com/questions/218340/
MAC_ADDR=00-60-2F`dd bs=1 count=3 if=/dev/random 2>/dev/null |hexdump -v -e '/1 "-%02X"'`
PHONE_NUMBER="12345678"
# Thanks http://www.giorgioravera.it/?p=169
curl -k \
-u 8Z6PlbuD6VFR8KLr:admin \
--data "Action=GetConfig&ClientID=$MAC_ADDR&Cli=$PHONE_NUMBER" \
https://modemtelecom.homenet.telecomitalia.it:8443/SIPGwConfig
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment