Andrew is a friend of mine. Andrew's direct boss is Brian who is the head of the department. Unfortunately Andrew doesn't get enough work from Brian and he often bored and idle there. It also causes some friction between Andrew and other colleagues since other people usually has a lot of work. (He asked for more work from Brian several times before.)
Sometimes Andrew helps other managers. (These managers also report to Brian and they are not between Andrew and Brian in the hierarchy.) Brian insists that he has to know (and accept) every work item that Andrew does.
Today Craig (a manager from his department) gave Andrew a few documents for processing, this kind of work was allowed by Brian formerly. A few hours later Andrew talked with Craig and it turned out that Brian revoked his allowance of this work and Craig wants to hide from Brian that Andrew does this work. The work should have been done by the Craig's already busy employees although Andrew also could do this (and has free time).
Additionally, it seems that this was not the only one occasion, there will be more similar documents next week.
Andrew struggles. He wants to be helpful, wants to avoid further frictions between colleagues but also does not want to do anything which Brian would not like. He could talk to Brian and unfold that he did some unallowed work (and earn a bad reputation from Craig and other colleagues and still be idle), could do the work and earn a bad reputation from Brian if the secret turns out or could just ask Craig to get an allowance from Brian (friction again, Craig said that he does not want to do that). Is there any other option?