Nope. These guys are not employed by NASCAR, and NASCAR has no say about what types of legal extracurricular activities they participate in. Could a driver's contract with his employer, a race team, state "no racing outside of NASCAR", or similar? I think it could, but I don't think I've ever heard of such a thing.