1) THE SHEPHERD WHO DENIED RECEIVING THE SHEEP
QUESTION: The Gemara relates an incident in which a shepherd denied that he had received any sheep from the owner, and later witnesses testified that he ate two of the sheep that were deposited with him. The Gemara says that according to Rebbi Chiya -- who maintains that the testimony of witnesses is equivalent to Hoda'as Piv (his own admission) -- the shepherd must make a Shevu'ah of "Modeh b'Miktzas" that he did not receive the rest of the sheep. Abaye asks, why is the shepherd trusted to swear if he has been proven by the witnesses to be a thief? The Shevu'ah of a thief is not accepted! (See TOSFOS to 5b, DH d'Chashid, and 3b, DH b'Chulei.) The Gemara answers that indeed the thief is not trusted and does not swear. Instead, Beis Din allows the claimant to swear that his claim is true and to collect from the thief. This follows the enactment of the Chachamim that whenever a Shevu'ah needs to be administered to a thief, Beis Din is to transfer the Shevu'ah to the claimant and allow him to swear and collect the money he claims.
How does this enactment of the Chachamim apply in the case of the shepherd? The Gemara earlier (4a) explains that Rebbi Chiya cannot derive from his Kal va'Chomer (or Tzad ha'Shaveh) that witnesses force a person to make a Shevu'ah of "Modeh b'Miktzas" when the person is "Huchzak Kafran." The Kal va'Chomer teaches only that when the defendant is not "Huchzak Kafran" he must make a Shevu'ah. Accordingly, Rebbi Chiya should have no source that a Shevu'ah of "Modeh b'Miktzas" should be made by the shepherd in this case, since he is "Huchzak Kafran" (witnesses testified that the shepherd willfully denied the claim in order to avoid returning an object that was entrusted with him). Since there is no source for such a Shevu'ah, there should be no source to allow the claimant to make a Shevu'ah and collect. (TOSFOS DH Iy, according to MAHARAM and SHITAH MEKUBETZES)
ANSWERS:
(a) TOSFOS answers that since a Kal va'Chomer teaches that one must make a Shevu'ah when witnesses testify that he owes part of a loan, the same should apply to a Pikadon (deposit). There should be no reason to distinguish between a loan and a Pikadon.
The words of Tosfos are difficult to understand. There is a clear distinction between a loan and a Pikadon. For the case of witnesses who testify about a loan, a Kal va'Chomer teaches that the defendant must swear. For the case of witnesses who testify about a Pikadon, there is no source for the Shevu'ah! (The principle of "Lo Pelug" normally does not apply to laws learned from the Torah.)
Perhaps Tosfos means that the Chachamim instituted that Beis Din should allow the claimant to make a Shevu'ah and collect even in the case of a Pikadon since, when witnesses testify about a loan, they obligate the defendant to make a Shevu'ah d'Oraisa, and if the defendant is "Huchzak Kafran" the Chachamim allow the claimant to make a Shevu'ah and collect. Even though the Chachamim do not give the claimant the right to make a Shevu'ah and collect when the Shevu'ah is only mid'Rabanan, in this case the Shevu'ah was never placed on the defendant and then reversed onto the claimant. Rather, the Chachamim instituted in the first place that the claimant make a Shevu'ah and collect.
(b) Other Rishonim do not ask the question of Tosfos. Perhaps they understand that "Huchzak Kafran" is not actually used as a Pircha to the Tzad ha'Shaveh in the Gemara earlier (4a). Rather, the Gemara means that even if a Tzad ha'Shaveh could teach that two witnesses can require a person to make a Shevu'ah of "Modeh b'Miktzas," the defendant should be exempt from a Shevu'ah if he is "Huchzak Kafran" simply because he is not trusted to swear. (Although the Gemara uses the words "Mah l'ha'Tzad ha'Shaveh..." which imply a Pircha, its intention is to say simply that a liar cannot swear, as Rashi and the Ritva explain. See MAHARAM and TORAS CHAIM, who ask why the Gemara does not say outright that a liar cannot swear.) Accordingly, the Gemara clearly is justified in saying that the defendant really should swear because of the Tzad ha'Shaveh, but since he is unable to swear the Chachamim reverse the Shevu'ah and allow the claimant to make the Shevu'ah and collect.
There is strong reason to suggest that "Huchzak Kafran" is not a Pircha: it is not consistent with the logic of a normal Pircha. Normally, a Pircha shows that the cases from which the Halachah is being derived (Ed Echad and Hoda'as Piv, in the case here) are more Chamur than the case to which the Halachah is applied (Hoda'as Edim), and therefore the Halachah cannot be derived from these two cases. "Huchzak Kafran," however, does not weaken the power of the witnesses. On the contrary, it is because of the power of witnesses that they are able to make the defendant a "Kafran." Rather, "Huchzak Kafran" introduces an entirely new reason to exempt the defendant from a Shevu'ah in the case of witnesses (Hoda'as Edim). This cannot be used as a Pircha on a Tzad ha'Shaveh. (RITVA, 4a)
Tosfos understands the Gemara literally, that it is asking a Pircha from "Huchzak Kafran," because he follows his own opinion as expressed elsewhere. Later (5b), Tosfos (DH d'Chashid) writes (in his first answer) that mid'Oraisa even a thief is trusted to swear. As such, "Huchzak Kafran" cannot provide grounds to disallow a thief from making a Shevu'ah. Rather, it must be a Pircha on the Tzad ha'Shaveh. (See Insights to 4a.)

5b----------------------------------------5b

2) ONE WHO FALSELY DENIES THAT HE OWES A LOAN
QUESTION: The Gemara teaches that a person who is found to be Kofer b'Pikadon -- who falsely denies that an object was deposited with him to watch -- becomes Pasul l'Edus, disqualified from serving as a witness. He becomes Pasul l'Edus, however, only when witnesses testify that the Pikadon was in his possession at the time he denied it.
In contrast, one who is found to be Kofer b'Milveh -- who denies that he owes a loan -- remains a valid witness. Presumably, this is true even when witnesses testify that a sum of money equal to the amount of the loan was in his possession at the time he denied it.
Why should he be eligible to give testimony if he has the money with which to pay and yet still refuses to pay? Even though he is denying only a loan and not a Pikadon, he still should be Pasul l'Edus since it is clear that he is not merely stalling for time but that he has no intention to pay back at all! (RITVA)
ANSWER: The RITVA answers that even when a person has the amount of money equal to the amount of the loan, it is assumed that he owes an equal amount to another creditor, and that other creditor is pressing him harder for the repayment of the loan (or, alternatively, it is assumed that he needs the money for any other, more pressing purpose). Therefore, it is assumed that he is merely stalling for time and he indeed intends to pay back the loan.
In contrast, when one denies that he owes a Pikadon, since he is not permitted to use the Pikadon for his own personal use he is presumed to be a thief and has no intention to pay it back at all. (See also SHITAH MEKUBETZES in the name of "MORI.")
3) ONE WHO FALSELY DENIES THAT HE OWES A "PIKADON"
QUESTIONS: The Gemara teaches that one who is shown to be Kofer b'Milveh -- who denies that he owes a loan -- remains a valid witness and may give testimony. In contrast, one who is found to be Kofer b'Pikadon -- who falsely denies that an object was deposited with him to watch -- becomes Pasul l'Edus, disqualified from serving as a witness. RASHI explains that when a person denies that he owes a Pikadon, it cannot be assumed that he is merely stalling for time ("Mishtamet") and that he intends to pay back later, because one is not permitted to use a Pikadon for his own personal use.
Rashi is bothered by a question: When the Shomer denies owing the Pikadon, perhaps he indeed is stalling for time. Perhaps the Shomer lost the Pikadon through his own negligence and thus is obligated to reimburse the owner with money, and he is stalling for time since he presently has no money with which to pay. Rashi (DH b'Pikadon) answers that if the Pikadon was lost (through Peshi'ah, his own negligence), the Shomer would not stall for time, but he would exempt himself from liability by claiming that the loss was not due to any negligence on his part. Since he did not claim that the Pikadon was lost but rather he denied that he ever received the Pikadon, it is assumed that he intends to steal the Pikadon and keep it for himself. (Although Rashi refers to a Shomer Chinam who is exempt from liability in cases of Geneivah v'Aveidah, the same logic applies to a Shomer Sachar and a Sho'el. When they lose the item and want to delay paying the owner, they should claim that the item was lost through "Ones," or that it was "Meisah Machmas Melachah," rather than claiming that they never received the item in the first place.)
(a) If a Shomer is considered Kofer b'Pikadon when he denies that he received the item since he did not claim that it was lost, why does the Gemara say later that one who is Kofer b'Pikadon is Pasul l'Edus only when witnesses testify that the item is in his possession? He should be Pasul l'Edus even when the item is not in his possession since he denied the entire Pikadon!
(b) Why would the Shomer consider it an option to claim that the object was lost, in place of denying that he ever received it? If he claims that it was lost, he must make a Shevu'as ha'Shomrim and swear that he was not negligent in watching it. In contrast, if he claims that he never received it, he is Kofer ha'Kol, and one who is Kofer ha'Kol (who denies owing anything) is exempt from making any Shevu'ah! (Otzar Mefarshei ha'Talmud in the name of YAD SHEL SHLOMO.)
ANSWERS:
(a) RASHI's intention is to explain what the Gemara assumed before it concluded that the witnesses must testify that the Pikadon is in the Shomer's possession in order to make him a Kofer b'Pikadon. At this point in the Gemara, the Gemara still assumed that one who is Kofer b'Pikadon is Pasul l'Edus even when it is not known that the Pikadon is in his possession. For some reason, it is not assumed that he is trying to stall for time. Why did the Gemara assume that he is not trying to stall for time? Rashi explains that the Gemara thought that if he was trying to stall for time, he would not have denied the entire Pikadon, but he would have exempted himself in another way, such as by saying that the item was destroyed in a manner for which he is not liable.
The Gemara rejects this explanation because of Rami bar Chama's Beraisa which teaches that if a Shomer denies owing part of a Pikadon, he must make a Shevu'ah of "Modeh b'Miktzas" in order to support his claim. The Gemara proves from here that although the Shomer denies ever receiving that portion of the Pikadon, he is still suspected of merely stalling for time so that he can repay his debt eventually. From this ruling it is clear that there is no reason to assume that the Shomer would have claimed that he lost it had he planned on eventually paying it back. Because of this, the Gemara concludes that one who is Kofer b'Pikadon is Pasul l'Edus only when witnesses testify that the Pikadon is in his possession. (This also seems to be the way the RAMBAN here understands the words of Rashi.)
(b) Rashi's explanation follows the position of Rami bar Chama, which the Gemara cites shortly. According to Rami bar Chama, if the Shomer claims that the entire Pikadon was lost, he does not have to make a Shevu'ah. He makes a Shevu'ah only if he claims that part of it was lost and part of it was never given to him. The Gemara proves from a Beraisa that even according to Rami bar Chama, it is assumed that one who is Kofer b'Pikadon is attempting to stall for time unless it can be proven that the Pikadon was in his possession at the time he denied having it. (M. Kornfeld)
The YAD SHEL SHLOMO answers differently. He explains that Rashi is consistent with his opinion expressed in Bava Kama (107a, DH Me'iz u'Me'iz), where he writes that even if a Shomer of a Pikadon is Kofer ha'Kol he still makes a Shevu'ah mid'Oraisa. Hence, the Shomer gains nothing by denying the entire Pikadon, because even if he denies it he still must make a Shevu'ah mid'Oraisa.
However, it is not logical to assume that Rashi requires every case of a Shomer to make a Shevu'ah when denies that he owes a Pikadon and is Kofer ha'Kol. Why should Beis Din believe the claimant's own word that there was a Pikadon in order to require the defendant to make a Shevu'ah? Rather, it appears that Rashi refers to a situation in which both the claimant and the defendant agree that there was a Pikadon, but the defendant claims that the object was lost (or destroyed through "Ones" or "Meisah Machmas Melachah") and that he therefore is exempt from any payment. In such a case, those who argue with Rami bar Chama require the defendant to make a Shevu'ah d'Oraisa (Shevu'as ha'Shomrim) that he was not negligent with the object. It is to this Shevu'ah which Rashi refers when he says that the Shevu'ah applies even to a case of Kofer ha'Kol, unlike Rami bar Chama. However, in the case of the Gemara here, when the defendant denies that he ever received a Pikadon, he does not have to swear.