#!/usr/bin/perl use warnings; use strict; my $data; $data = <\r 3.0\r 8747\r john.doe.\r 0\r Login Successful\r c12168e0-e34e-4c27-b4a6-be235ff7fa41\r https://example.com/_bers/log.asp?SID=c12168e0-e34e-4c27-b4a6-be235ff7fa41\r XML if ($data =~ /(https:\/\/[^\s]+[$<])/ ) { print "Found: $1\n";