The White House mocked GOP nominee Donald Trump and Sen. Ted Cruz for trying to prevent the Commerce Department from transferring technical oversight of the Internet to an international body.

"It doesn't withstand scrutiny," President Obama's spokesman Josh Earnest said on Thursday.

"It also strikes me as a curious position for a self-described small government conservative to shut down the government to ensure that the federal government can continue to control the Internet," Earnest said of Cruz. "It doesn't make any sense."

Cruz is trying to stop the multi-year transition that will leave the Internet Corporation for Assigned Names and Numbers in control of things such as naming Internet domains, by attaching a provision to a must-pass package that would keep the government funded past the Oct. 1 start of the new fiscal year.

Trump on Wednesday threw his support behind Cruz's effort.