The White House berated Samsung's strategy of using a selfie of President Obama and Boston Red Sox star David Ortiz as a marketing tool on Thursday, CNN Money reported.

Taken earlier this week, the moment was captured by Ortiz during a visit to the White House. After taking the photo, Ortiz shared it with his fans on Twitter.

Samsung, who has an endorsement deal with Ortiz, went ahead and re-tweeted the post to its 5.2 million followers.

However, the move was rebuked by the White House for turning the distribution of the photo into a promotional strategy by the electronics company, CNN Money reported.

"I can say that as a rule, the White House objects to attempts to use the president's likeness for commercial purposes," White House press secretary Jay Carney said Thursday. "And we certainly object in this case."

It wasn't clear whether the White House lawyers have contacted Samsung. Carney refused to comment on "counsel's discussions."

Samsung told the Boston Globe on Tuesday that it was "thrilled to see the special, historic moment David Ortiz captured with his Galaxy Note 3."

"When we heard about the visit to the White House, we worked with David and the team on how to share images with fans. We didn't know if or what he would be able to capture using his Note 3 device."

The selfie happened to be spontaneous, and a moment that the president seemed to enjoy, according to CNN Money.

"Alright come on, let's get a good picture here," Obama told Ortiz after the slugger presented him with a Red Sox jersey.

"Actually, do you mind if I take my own?" Ortiz countered.

"Oh, he wants to do a selfie," Obama said, drawing laughter from the crowd. "It's the Big Papi selfie."

Ortiz, however, claimed the picture to be an unscripted moment.

"I wasn't trying to do anything," Ortiz told the Boston Globe. "It just happened in that moment. It was a fun thing. I signed that deal with Samsung a few months ago. They didn't know what would happen. Nobody did."