serial_num and device_id fields are not necessarily null-terminated.

Before this it was impossible to use all 16 bytes of serial number, and
client always got serial number NULL-terminated, that is not required.

MFC after:	2 weeks
Ticket:		#5230

(cherry picked from commit f13b1f884484db04939563945a046f40f0580f85)