Use implementations from platform lib

Change-Id: Ic92b3960d73c4f6c89e43491031d386f41754b46
Use common cJSON

Change-Id: Ic145eb819a3273b862f082bdcd2ea406e9909966