Assuming I have the IP 10.23.233.34 I would like to simply swap the 233 for 234. The first, second, and last octet are unknown. The thir
10.23.233.34
233
234
$byte = qr/(?:\d{1,2}|1\d\d|2[0-4]\d|25[0-5])/; s/($byte)\.($byte)\.(23[34])\.($byte)/join '.', $1, $2, 467-$3, $4/e;