You have no options but to trust the manufacturer or produce the device yourself. Therefore, it's important to verify the credibility of the factory producer before buying. As for buying from retailers, it is important to buy only from authorized retailers who are losted in the manufaturer website.
However, there are always some possible risks like a third part manipulation during/before shipping by replacing the devices with others fake or modified. It's important to test the device and activate it in main manufactur website, and avoid buying from unknown retailers.