> For the complete documentation index, see [llms.txt](https://hazmiae.gitbook.io/writeups/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hazmiae.gitbook.io/writeups/underthewire-century.md).

# 🐈⬛ 🐈⬛ UnderTheWire Century

### Century 0-1

![](/files/0LZsDuUqA2qt2e0II0n5)

![](/files/8G3Jaio18U7vcpbwCTkW)

![](/files/BfJlliEzvg9MSRpsAfZY)

![](/files/cn6ZhmIyfGAjoEWOQ9se)

<mark style="color:green;">**century**</mark>

### Century 1-2

Challenge ask us to find build verison of PowerShell instance.&#x20;

![](/files/onj95lRmXa7rlkxn8jMm)

According to this [microsoft module](https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_powershell_editions?view=powershell-7.2), we can list the detail of our PS using `$PSVersionTable` command.

![](/files/dflUgW8ogjH8BJQ67zTw)

<mark style="color:green;">**10.0.14393.4583**</mark>

### Century 2-3

![](/files/tj3hgY4EOD5deiQJF45K)

![](/files/zhHAf5feK6Xk9DgcVPqA)

`Invoke-WebRequest` has the same function as wget command according to <https://linuxhint.com/run-wget-powershell/>.

<mark style="color:green;">**invoke-webrequest443**</mark>

### Century 3-4

![](/files/VP4QUNCcWp1fDIya8WkE)

We can use `(Get-ChildItem | Measure-Object)`.Count to get the total number of files in a directory.&#x20;

* Get-ChildItem = Equivalent to dir , get the items and child items in a folder or registry key.
* Measure-Object = measure the property of the command. There are various measurement parameters are available. For example, Average, Count, sum, maximum, minimum.
* .Count = to specify output for count only.

![](/files/AUUhXjkMxJpEOWHziGnc)

<mark style="color:green;">**123**</mark>

### Century 4-5

![](/files/qse244V3scu12HgYT4ys)

CD to the directory either by pressing tab or specify directory name using '\file'.

![](/files/qKgNHgDvoHmAzwgNLLRq)

<mark style="color:green;">**5548**</mark>

### Century 5-6

![](/files/ZnyfqCmUTNWeJRkQNmpe)

According to [PS module](https://docs.microsoft.com/en-us/powershell/module/activedirectory/get-addomain?view=windowsserver2022-ps), we can use `Get-ADDomain -Current LoggedOnUser` to get the domain information for the domain of the currently logged on user.

![](/files/7syTE7QBUbp1Xs2oV63J)

<mark style="color:green;">**underthewire3347**</mark>

### Century 6-7

![](/files/qog1thpZQMXYD8hw2B5j)

Use option -Directory to only get folders. `(Get-ChildItem -Directory | Measure-Object).Count`&#x20;

![](/files/aRTkUs6BaAGmqKvLMevB)

<mark style="color:green;">**197**</mark>

### Century 7-8

![](/files/O2Fq09mpAPWKNGCschYc)

Use gci with -Recurse to repeat the command in all subfolder in the directory and specify the file name with -Filter.

![](/files/5cx5xnZGmfEAlVpL2ZLd)

<mark style="color:green;">**7points**</mark>

### Century 8-9

![](/files/PWqcxBbEUnN9iHUsBT0b)

We can use `Get-Unique` which is the equivalent of uniq to get the non repeated words in the file. Then we use `Measure-Object` to count the unique entries.

![](/files/eUp5pq6DlRGPTxe6sQCq)

<mark style="color:green;">**696**</mark>

### Century 9-10

![](/files/fO1mcRwvv2jDbylZ20gP)

We use [GetContent](https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.management/get-content?view=powershell-7.2) with [-Delimiter](https://www.mssqltips.com/sqlservertip/5427/parsing-strings-from-delimiters-in-powershell/) " " to split the words into an array and find the 161st word by using Select -Index 160.( Array starts from 0).

![](/files/P5Unht3pSVZ7DsQxltUS)

<mark style="color:green;">pierid</mark>

### Century 10-11

![](/files/qt6SxzVfDhefqphw56Kt)

According to the answer from StackOverFlow, we can use `Get-WmiObject` cmdlet to get more details and information of a windows 32 service. Then we can use findstr [wuauserv](https://www.windows-commandline.com/start-stop-windows-update-service/)(windows update service) which is the equivalent of grep to get the  details of windows update service.

![](/files/qpfZXyMYjZrZvpK3eBj4)

![](/files/aL4OCloIrMuxuX3WXpkZ)

<mark style="color:green;">**windowsupdates110**</mark>

### Century 11-12

![](/files/hzhAu6OTXTBQuiaAyGLD)

We can use gci -recurse -hidden 2>$null to find any hidden file in a directory.

* hidden = find file with only hidden property.
* 2>$null = discard error.

![](/files/FAqVNATNC8zntQ0a3sWW)

![](/files/lG1dT6dSmhPt0eqjrFYN)

<mark style="color:green;">**secret\_sauce**</mark>

### Century 12-13

![](/files/PLo25O1sy2mKaMZrdqID)

We use [Get-ADDomainController](https://docs.microsoft.com/en-us/powershell/module/activedirectory/get-addomaincontroller?view=windowsserver2022-ps) to get Active Directory domain controllers name.&#x20;

![](/files/P0sivUktoTOeDfyktnqo)

After finding the domain controller name, we can use `Get-ADComputer -Identity "UTW" -Properties * | Select Name, Description`  to get the description of our AD name.

* Get-ADComputer = get active directory computer details.
* -Identity "UTW" = specify our AD name.
* -Properties \* = list all possible properties.
* Select Name, Description = filter out the only parameter we want.

![](/files/gexJcbt9GK8fH99kDrvF)

<mark style="color:green;">**i\_authenticate\_things**</mark>

### Century 13-14

![](/files/MmcrgBLzkFPORDRa8MLD)

Use getcontent with Measure-Object -Word to only get words amount.

![](/files/KPBJ6y7yI6FhaI506xWA)

<mark style="color:green;">**755**</mark>

### Century 14-15

![](/files/n0RFEXx4Udg8TA0S6vVy)

Use getcontent with -Delimiter to split words into array. Then use findstr ^polo (^to specify whole word only) to grep polo. Lastly use count to count the number of polo words in the file.

![](/files/9skRhwLzUOzRaHTBIum4)

<mark style="color:green;">**153**</mark>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://hazmiae.gitbook.io/writeups/underthewire-century.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
