C ++如何通过win32 api检索文件权限和所有权 [英] C++ How to retrieve a file permission and ownership via win32 api
问题描述
我一直在网上搜索如何使用win32 api检索文件的权限和所有权,但我没有回答。
I've been searching over the internet how to retrieve permissions and ownership of a file using win32 api, and yet I have no answer.
我是新的与win32 api,从互联网上读一些指南,试图分析一些代码
与这个api关联,仍然我无能。
I'm new with the win32 api , read some guides from the internet, tried to analyze some code associating with this api and still I'm clueless.
帮助我一些建议或一些方向,提示等。
Could you guys help me out with some piece of advice or some directions , tips etc.
对不起,我不能更具体的,通过添加一些代码,我没有看到任何原因导入任何我自己的代码,因为唯一剩余的功能是检索此信息,其余是简单的(用户界面等)。
I'm sorry that I can't be more specific than that by adding some code, I don't see any reason to import any code of my own since the only remaining function is the one retrieving this information and the rest is simple(User interface and etc).
推荐答案
请参阅此示例使用 GetSecurityInfo
和 LookupAccountSid
函数查找文件的所有者。
See this example which finds the owner of a file using GetSecurityInfo
and LookupAccountSid
functions.
这篇关于C ++如何通过win32 api检索文件权限和所有权的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!