LONGTIME friends Leonardo DiCaprio and Orlando Bloom are at war over Bloom’s wife, “Victoria’s Secret” model Miranda Kerr.

Just days after the Aussie beauty and Orlando announced they were ending their three-year marriage, “Wolf of Wall Street” star Leo started hitting on Miranda, determined to

out of respect for her marriage. About a month ago Orlando told Leo that he and Miranda were splitting up and he was brokenhearted over it. Leo comforted his pal, saying, ‘I know better than anybody – there are plenty of other fish in the sea.’”

Then Leo, 39, turned around and asked 30-year-old Miranda – mom of Orlando’s 2-year-old son Flynn – out on a date.

As The ENQUIRER recently reported, Leo has been under pressure to have a child because his mom Irmelin is desperate to be a grandmother.

“Orlando was shocked that a friend would stab him in the back so callously,” said the source. “He told Leo to lay off, at least until his divorce is final.”

But Leo may have some serious competition as Miranda is reportedly dating Australian billionaire James Packer, 46.

Still, the source said that Orlando, 36, grumbled to another pal: “With friends like Leo, who needs enemies!”