A gain of function responsible for the production of a cancerigenic metabolite.