you need administrative rights to fetch this
Do you? Win32::SystemInfo works with user privileges. And the module is reading from the Registry too. Addendum: It is using a combination of Win32::TieRegistry and the GetSystemInfo function from Win32::API. Here's the relevant function.
use Win32::SystemInfo; use Data::Dumper; my %phash; Win32::SystemInfo::ProcessorInfo(%phash); print Dumper (\%phash);
Yields on my system, running as normal user:
$VAR1 = { 'Processor3' => { 'Identifier' => 'Intel64 Family 6 Model 60 + Stepping 3', 'ProcessorName' => 'Intel(R) Core(TM) i5-4 +440 CPU @ 3.10GHz', 'VendorIdentifier' => 'GenuineIntel', 'MHZ' => 3093 }, 'NumProcessors' => 4, 'Processor2' => { 'MHZ' => 3093, 'VendorIdentifier' => 'GenuineIntel', 'Identifier' => 'Intel64 Family 6 Model 60 + Stepping 3', 'ProcessorName' => 'Intel(R) Core(TM) i5-4 +440 CPU @ 3.10GHz' }, 'Processor0' => { 'MHZ' => 3093, 'VendorIdentifier' => 'GenuineIntel', 'ProcessorName' => 'Intel(R) Core(TM) i5-4 +440 CPU @ 3.10GHz', 'Identifier' => 'Intel64 Family 6 Model 60 + Stepping 3' }, 'Processor1' => { 'ProcessorName' => 'Intel(R) Core(TM) i5-4 +440 CPU @ 3.10GHz', 'Identifier' => 'Intel64 Family 6 Model 60 + Stepping 3', 'VendorIdentifier' => 'GenuineIntel', 'MHZ' => 3093 } };


holli

You can lead your users to water, but alas, you cannot drown them.

In reply to Re^2: Need help with Win32::TieRegistry by holli
in thread Need help with Win32::TieRegistry by CrashBlossom

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.