protection against malformed urls