Common Commands Part 3

Video Activity
Join over 3 million cybersecurity professionals advancing their career
Sign up with
or

Already have an account? Sign In »

Time
1 hour 43 minutes
Difficulty
Intermediate
CEU/CPE
2
Video Transcription
00:00
Hello, everyone. I'm instructor Gerry Roberts, and this is Power Shell scripting in this video. We're gonna talk about how to get some computer information, and we're gonna use the C. I am Incense
00:12
Command.
00:14
So to do that, we're gonna look at sea. I am. Instance,
00:18
we're gonna look at
00:20
the get see I am in since command. Then we're gonna look at some classes for CM and since which are the 1 32 deaths up
00:29
when 32 bios when 32 processor and win 32 computer system classes
00:37
using C. I am instance to get computer information.
00:41
Now we can use the C. I am instance to get information about a computer. See, I am actually stands for comment. Information module.
00:49
This particular module works with W M I A.
00:53
Which is the Windows management instrumentation
00:56
together. Information. You may be familiar with W M I. If you've worked with remote computers before,
01:06
get see I am in. Since command is a command that we actually use to get the information about a computer
01:15
with the command, you have to specify it item you want to get. That's where the dash class name portion comes into play. This particular parameter allows you to specify which class of information you want to get.
01:30
Another parameter. You can use his dash computer name.
01:34
Yeah, if you're reminding the command locally, you don't have to use computer name. Computer name is used solely for when you're working with another computer other than the one that you're currently using.
01:46
So that would be, say, if you're connecting remotely to another server or another client and trying to gather information about it.
01:55
So a couple classes for our C I. Am instance,
02:00
the 1st 1 is Win 30 to underscore Desktop.
02:04
This particular one does what it sounds like, and it gets information about the desktop. You know, gather information about all the desktops on the specified computer, whether or not they are in use.
02:15
The next one is Win 30 to underscore biased. This one also does what it sounds like and gets information for the BIOS as well as you. Fi
02:28
processor is another one we can use, and the wind 30 to Underscore Processor does exactly what it sounds like. A swell and gets information for your processor or processors of that computer.
02:40
The wind 30 to underscore. Computer system is another useful class in this class. List information about the computer manufacturer and model.
02:53
And it's now time for a short demo so we can take a look at sea. I am instance in action.
03:00
Now that we have power show up, we can take a look at the get See I am. And since in action.
03:07
So when you're doing that, you didn't get C I and instance
03:10
space
03:12
Tash class name and you specify which class you want to get information about. We're gonna go through the couple. We went through the power point. Just see you take a look at what that looks like.
03:23
So the 1st 1 we're gonna do is win 30 to underscore Best top
03:29
Net shows us that there are a couple of desktops in this particular machine. There's a system, a local service, a network service. There's mine. And there's of course, the default.
03:42
Yeah,
03:43
all these settings air located in your registry. Now the next one we want to look at is going to be by us information till we d'oh get tea. I am since
03:54
class name win 30 to underscore.
04:00
Yes,
04:01
and now we have information about the BIOS.
04:08
Next, we'll take a look at processor,
04:11
so it's get Dash C I and Incense bash. Last name When? 32 processor
04:26
there. I have more information about my processor. You know, if I want to make that look a little bit better, I could pipe in a format lis,
04:35
and you would get a little bit better output so you could read it.
04:39
Now, one thing you will want to notice here
04:44
is that when you're pulling this information and doing the commands, this is not a case sensitive module. So anytime you do get see, I am instance, You don't have to be very careful about the case. Last one we're gonna d'oh
05:00
is we're gonna do the win 30 to underscore computer system
05:05
and you get information about the particular computer. Now again, this is one of the ones you're probably gonna wanna format list, so it looks a little bit better.
05:15
But you get the idea there that these particular classes give you quite a bit of information about different pieces on your system. These air super useful, especially in an enterprise environment, when you're trying to get information about all of the computers that are working on the network.
05:32
So you have a better idea of a baseline as well as what you're working with
05:38
and whether you need to do updates or you need to change out. Equipment also noticed that when I put in, get deaf. See, I am instance I didn't do the dash class name.
05:50
This is one of those instances which the parameter order counts so you could put the value in and not have to do the parameter name itself. The parameter still required just not the name.
06:05
Now that we've finished our demo, it's on to quiz.
06:10
So this post assessment question
06:13
wants you to know if you wanted to list information about the computer bias. Which C I am is since class would you use
06:19
would you use the wind 30 to underscore computer system
06:24
The wind 32 by us,
06:26
the wind 30 to underscore by us or the wind 30 to underscore processor.
06:31
So go ahead, give you a second to see if you can figure that out. You can also posit video if you'd like.
06:41
All right. The answer is C win 30 to underscore bus. Remember when 30 to underscore. Boss is a classic contains information about the bios and the UV.
06:51
So in this video,
06:55
we learned some information about getting computer information using get dash C. I am instance.
Up Next