I need to read and modify extended file attributes in a .NET 5 console application that must work on Windows and Linux (assuming that the files system supports those attributes).
This question has been asked with too(?) specific contexts before:
- Custom File Properties (from 2013, no cross-platform)
- Getting ANY extended file attribute in C# (from 2015, focusing on special cases or platform-specific solutions)
- Obtaining file extended properties in .Net Core (from 2017, cross-platform, but restricted to some special attributes)
So some years later I want to ask again in a very generic way about those extended file attributes to get a definitive, working, cross-platform answer. About those attributes from the Wikipedia article "Extended file attributes". I want to add arbitrary ones (not restricted to Title or Author or something). Any key/value pair.
Which .NET APIs should I use?