Comments (4)
I have never hear that WMI would require permissions to use on the local machine.
According to this, you don't need any special permissions:
https://stackoverflow.com/questions/24295301/does-wmi-access-in-net-required-administrative-privileges
You only need permissions to use WMI on a remote computer, but my library doesn't do that.
Do you have an example where Hardware.Info
would require any special permissions?
from hardware.info.
I have a customer who uses this on their machines. In this case our application which uses Hardware.Info to verify if ram, disk storage etc. is available at startup fails since application is not able to access underlying OS functionalities, which causes WMI to fail. Hence I requested for a method/check to verify if WMI is accessible or not.
from hardware.info.
I see. It would really help me if you would provide me with the steps to replicate this failure, so I would know what the problem is.
Just show me the minimal code necessary for this failure to happen.
from hardware.info.
I didn't find any mentions of WMI failing on a local machine due to lack of permissions.
If you don't show me how this failure happens - what exception is thrown - then I can't do anything to fix it.
If the problem is that the user needs administrator privileges, then you can check that yourself:
https://stackoverflow.com/questions/5953240/check-for-administrator-privileges-in-c-sharp
using System.Security.Principal;
bool isAdministrator;
using (WindowsIdentity identity = WindowsIdentity.GetCurrent())
{
WindowsPrincipal principal = new WindowsPrincipal(identity);
isAdministrator = principal.IsInRole(WindowsBuiltInRole.Administrator);
}
I will not add this to my library.
from hardware.info.
Related Issues (20)
- Not work in console app HOT 2
- VideoController.AdapterRAM does not report > 4GB HOT 4
- Very little info seems to be collected on Debian HOT 2
- Network speed is set to 0 or set to long.MaxValue in certain circumstances HOT 7
- System.Management currently is only supported for Windows desktop applications HOT 3
- Network interfaces cannot be refreshed when the available address families are restricted with systemd HOT 11
- On Win7 system, an exception is triggered with the message 'Could not locate Performance Counter with specified category name 'Processor Information', counter name '% Processor Performance' HOT 2
- `WmiNetUtilsHelper` exception if `PublishTrimmed` is `true` HOT 3
- Not all Monitors/Screens returned on Windows HOT 5
- Incorrent CPU information for multiprocessor platforms on Linux HOT 3
- CPU usage HOT 2
- Use semantic versioning for package releases HOT 1
- Lack of information on Linux HOT 9
- Computer Model and Manufacturer HOT 2
- GPU Usage Infomation
- Drive info not available in Linux HOT 5
- About the timeout exception. HOT 3
- Question: Obtaining CPU Utilization Metrics HOT 5
- Curious about AOT compilation HOT 2
- Windows support without WMI HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from hardware.info.