Sometimes you will get errors back from Amazon while listing about invalid UPC/EAN codes. if this happens, you can check the validity of the UPC/EAN code at this link:
This tool is provided by the organization that oversees barcode assigning. Use 'search by barcode'. The results of the form needs to pull up a company name when you search by Trade Item Ownership. If it does return a company name, the UPC code should be valid.