Insecure use of strcpy allowed for potential buffer overflow vulnerabili...

...ties.

Several of these changes have been replaced with the more secure strncpy. Due to the Contiki being the largest IoT platform, security should be a primary concerned.
As pointed out by @gebart this should be

```C
strncpy(urlptr, host, sizeof(url) - (urlptr - url));
```

Same goes for the next line.