R Shlomo Luria, in Yam Shel Shelomo Bava Kamma 5:35, discusses the status of property nowadays declared by its owner cherem for Kohanim. He takes a strong position against the validity of modern Kohanim's claim to the priesthood. He writes:
בעו"ה אין לנו היחוס, כמו שהיה בזמן הבית. או אפילו אחר החורבן, בימי התנאים והאמוראים. שהיו עדיין נזהרים בתרומות ובטהרות, והיה קרוב מימי הבית. ועדיין היה יחוסיהם בידיהם. ובעונותינו מרוב אריכות הגלות וגזירות וגירושים נתבלבלו. והלואי שלא יהא נתבלבל זרע קדש בחול. אבל זרע כהנים ולוים קרוב לודאי שנתבלבלו. ואם לא כולו, הרוב נתבלבל, כמעשה דאליהו ז"ל עם הלוים, הידוע בדברי רז"ל. ואם לא הרוב, בודאי קרוב למחצה נתבלבלו. וא"כ ניתי לידי תקלה, שמא יתן לכהן שאינו כהן. ויהיה עדיין כהקדש ממש
Because of our many sins, we don't have proper lineage like they had in the times of the Temple or even after in the days of the Tannaim and Amoraim, for they were still careful with tithes and laws of purity and they were closer [temporally] to the Temple and still had their documents of lineage. And in our sins through the long time of the exile, decrees and expulsions we have become mixed up. [All we can hope for is that] we have not mixed up Jewish and not Jewish lineage, but the lineage of priests and Levites are almost certainly mixed up; if not all of them, at least most of them are mixed up...and if not most than close to half are mixed up. If so, we might have a problem if someone gives [cherem property] to a Kohein who isn't a Kohein, and the property will remain sanctified.
Despite this extreme position, he concludes:
ובודאי בדיעבד...נותן לכהנים אפילו בזמן הזה, כמו שפסק הרמב"ם. כי מכח האי חומרא לית לן רשות להפסיד ממון של כהנים. רק שלכתחילה יזהר.
Certainly, after the fact [if one already declared something cherem], one should give the property to a Kohein even nowadays...because by virtue of this stringency [quoted above] we do not have the right to deprive Kohanim of their money. But from the outset, one should be careful [to not declare things cherem].
In other words, if not for his issue with the lineage of modern Kohanim, he would be ok declaring things cherem for them even lechatchilah.
However, in Yam Shel Shelomo Chullin 8:4 he writes:
אין אנו נוהגין ליתנה אפילו לכהן קטן, וכ"ש לגדול שטבל לקריו, דאין לנו היחס, ואין אנו יודעים אם הוא כהן אמיתי...
We do not give [Challah from the Diaspora] to Kohein children and certainly not to an adult Kohein who has dipped in a Mikva [who are permitted to eat Challah of the Diaspora even if they have contracted other impurities per Shulchan Aruch YD 322:5] because we don't have [proper] lineage and we don't know if he is a real Kohein...
He goes on to say that we don't give Challah of the Diaspora to such a Kohein even on Pesach, where by not giving it to him to cook, we are forced to allow it to sit and become Chametz (cf OC 457)!
What I don't understand if why he is so stringent regarding Challah of the Diaspora, where the prohibition of a non-Kohein eating it is rabbinic (and a weak rabbinic one at that), but he is willing to allow a Kohein to take cherem property, where the prohibition of a non-Kohein benefiting from it is a full-blown biblical prohibition. Am I misreading the sources? Don't both cases involve potentially depriving the Kohanim of their rightful property? Why is R Luria lenient by cherem but not by Challah of the Diaspora?