Things are not looking up for Angelina Jolie in her lengthy custody battle with Brad Pitt over their children.

A judge threw the books at Jolie today, according to official court documents that were leaked.

The humanitarian has been ordered to give Mr. Pitt more access to their six children — Maddox, 16, Pax, 14, Zahara, 13, Shiloh, 12, and 9-year-old twins Vivienne and Knox.

Jolie, who filed for divorce from Pitt in the fall of 2016, is being accused of keeping the clan away from their father and making it hard for him to call them.

It was also revealed that Jolie reads through her children’s text messages and the judge has asked her to end that odd habit.

The judge told the actress in part: “…not having a relationship with their father is harmful to them.”

If she does not respect the new rules, she could lose custody of her children.

The judge added: “If the minor children remain closed down to their father and depending on the circumstances surrounding this condition, it may result in a reduction of the time they spend with [Jolie] and may result in the Court ordering primary physical custody to [Pitt],

A source told Hollywood Life that Jolie is upset and added: “Angelina is emotional and concerned over Brad’s increase in custody, and the time he will be spending with their children this summer. It has been a rough year for all of them, so she is worried about what is best for them constantly. She has no more choice in the matter, so she feels a bit helpless, and a loss of control.”

The insider went on to reveal: “Angelina is trying to make the best of it and wants them to have stability and structure. However, she still struggles whenever the kids are away from her, even when they are with their father. It is difficult for her to be away from the kids, but she is working a lot this summer too, so she has no choice but to go along with the judge’s orders and have faith that the kids time with Brad will be safe and good for them.”