Nedarim, Chapter Four, Mishnah Two
This mishnah and the remainder of the chapter teach what a person can do with/for his friend, even though he is under oath not to give any benefit to him.
If one is under a vow not to benefit from his neighbor, [his neighbor] may pay his shekel, pay off his debts, and return a lost article to him.
Where payment is taken for this, the benefit should become sacred property.
When the Temple still stood every Jew had to send a half shekel every year for the upkeep of the Temple. Even if Reuven cannot receive benefit from Shimon, Shimon may pay his half shekel. Similarly, Shimon may pay off Reuvens debts. Both of these are permitted because Shimon is not giving money directly to Reuven.
Shimon may also return a lost object to Reuven because he is only returning to Reuven what is already his. Furthermore, all Shimon is doing is fulfilling the mitzvah of returning lost objects.
If people customarily offer financial rewards to someone who returns a lost object, Shimon may not turn down Reuvens offer of a reward, because by doing so he would be giving financial benefit to Reuven. If Shimon does not want to just take the money, he may donate it to the Temple by making it sacred property.
Other commentators explain that this last clause refers to a case where neither party may benefit from the other. They are still allowed to return each others lost property, for that is a mitzvah. However, if a reward is given it must go to charity. The one who returned the lost object cannot take the reward nor can the one who received it not give the reward, for in either case, someone would have received financial benefit.