Involved in the biosynthetic pathway to 4-hydroxyindole-3-carbonyl nitrile (4-OH-ICN), a cyanogenic metabolite required for inducible pathogen defense. Converts indole-3-carbonyl nitrile (ICN) into 4-OH-ICN (PubMed:26352477). Can hydroxylate xanthotoxin (8-methoxypsoralen) to form 5-hydroxyxanthotoxin (5-hydroxy-8-methoxypsoralen) in vivo and in vitro (PubMed:18291319). O2 + reduced [NADPH--hemoprotein reductase] + xanthotoxin = 5-hydroxyxanthotoxin + 2 H(+) + H2O + oxidized [NADPH--hemoprotein reductase] indole-3-carbonyl nitrile + O2 + reduced [NADPH--hemoprotein reductase] = 4-hydroxy-indole-3-carbonyl nitrile + H(+) + H2O + oxidized [NADPH--hemoprotein reductase] Up-regulated upon pathogen infection. Increased susceptibility to virulent Pseudomonas syringae. Plants overexpressing CYP82C2, can hydroxylate and subsequently glycosylate 8-methoxypsoralen. Belongs to the cytochrome P450 family. Extended C-terminus.