How to: Add/Include folder to Windows 10 Library Remove/Delete folder from Windows 10 Library

If the Library icon is missing from “This PC” please refer to this guide to show it:

How to Fix: Windows 10 Library missing/Missing Library icon in “This PC” & How to: Hide Library in Windows 10

Add/Include folder to Windows 10 Library

1 Open “This PC” or Navigate to the folder that we want to include in the Libraries

2 Right click on the folder that we want to include in the Libraries, Navigate to “Include in library” then select existing library or click on “Create new library” to include it to a new library

Include in library
Include in library

3 In this example we include the “xampp” folder to “Documents” library

Include xampp folder in Documents library
Include xampp folder in Documents library

Remove/Delete/Exclude folder from Windows 10 Library (This will not delete the folder itself)

1 Open “This PC”

2 Navigate to the library which include the folder which we want to remove from, “Documents” library in this case

Library – Documents

3 Right click on the library which includes the folder which we want to remove/delete from, “Documents” in this case, then click on “Properties”

Right on the library, Documents in this case
Right on the library, Documents in this case

4 Click on the folder which we want to remove from library then click on “Remove” button, finally click on “OK” button

Documents Properties
Documents Properties

5 Now the folder is removed from the library

xampp folder removed from Documents library
xampp folder removed from Documents library

Warning: If you right click on the folder then click on Delete from Library, the folder will be deleted!!! (That’s not delete from the library, it actually deletes the folder itself and of course it will disappear from the library as well, sine the folder is gone completely by deleting it). So be careful.


How to Fix: Windows 10 Library missing/Missing Library icon in “This PC” & How to: Hide Library in Windows 10

What is Windows 10 Library in short

The “Libraries” in the red rectangle is Windows 10 Library

Windows 10 - This PC - Libraries
Windows 10 – This PC – Libraries

How to bring it back/Show it, if it’s not there?

1 Right click in one of the areas marked in red rectangle

Windows 10 - This PC - Libraries missing
Windows 10 – This PC – Libraries missing

2 Click on “Show libraries”

Windows 10 - This PC - Show libraries
Windows 10 – This PC – Show libraries

3 Now the Libraries folder is back in This PC

Windows 10 - This PC - Libraries
Windows 10 – This PC – Libraries

How to hide “Libraries” in This PC?

1 Right click in one of the areas marked in red rectangle

Windows 10 - This PC - Hide Libraries
Windows 10 – This PC – Hide Libraries

2 Click on “Show libraries” to uncheck it (Which means hide it)

Windows 10 - This PC - Click on Show libraries to unheck and hide it
Windows 10 – This PC – Click on Show libraries to unheck and hide it

How to: Find out your genuine Windows 10 product key from the computer easily with different methods

1 Using ProductKey

A free software for reviewing Windows product keys.

ProductKey
ProductKey

Download ProduKey (In Zip file)

Download ProduKey for x64

2 Using Registry Editor

1 Use Win + R key combination to launch “Run” Window

Microsoft Windows - Run window
Microsoft Windows – Run window

2 Type regedit, then hit Enter key, Registry Editor Window will appear

Windows 10 Registry Editor
Windows 10 Registry Editor

3 Navigate to following path

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform
Registry Editor - SoftwareProtectionPlatform
Registry Editor – SoftwareProtectionPlatform

You will be able to find your Windows product key besides “BackupProductKeyDefault” key

3 Using PowerShell/Command Prompt

1 Launch command prompt/PowerShell with Admin privilege.

1.1 By using Win + X key, launch the Command Prompt (Admin) or PowerShell (Admin)

2 Execute following command

wmic path softwarelicensingservice get OA3xOriginalProductKey
wmic path softwarelicensingservice get OA3xOriginalProductKey
wmic path softwarelicensingservice get OA3xOriginalProductKey

4 Using PowerShell/Command Prompt with Registry command



1 Launch command prompt/PowerShell with Admin privilege.

1.1 By using Win + X key, launch the Command Prompt (Admin) or PowerShell (Admin)

2 Execute following command

REG QUERY "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v BackupProductKeyDefault
Get value for "BackupProductKeyDefault" from command prompt or PowerShell
Get value for “BackupProductKeyDefault” from command prompt or PowerShell

How to: Add specific/custom folders to Windows index (So that contents will come up in search results in Start Menu)

1 Bring up the “Indexing Options”

1.1 Method 1

1.1.1 Click on Start button to bring up Windows Start menu

Start button
Start button

1.1.2 Type index

Type index
Type index

We will find “Index Options”

1.2 Method 2

1.2.1 Use Win + R key combination to bring up Run window

Microsoft Windows - Run window
Microsoft Windows – Run window

1.2.2 Type control then hit Enter key, Control Panel will appear

Windows 10 Control Panel
Windows 10 Control Panel

1.2.3 Click on “Large icons”

Large icons
Large icons

1.2.4 Click on “Index Options”

Index Options
Index Options

1.3 Method 3

1.3.1 Use Win + R key combination to bring up Run window

Microsoft Windows - Run window
Microsoft Windows – Run window

1.3.2 Type one of following commands then hit Enter key

control.exe srchadmin.dll
 
control /name Microsoft.IndexingOptions
 
rundll32.exe shell32.dll,Control_RunDLL srchadmin.dll

2 Add the desired folder to Windows Index

2.1 Click on “Modify” button

Windows 10 Index Options
Windows 10 Index Options

2.2 Check the desired folders, so that they will be indexed. You can select folders from other drives as well, e.g. D, E, F drive

Windows 10 Indexed Locations
Windows 10 Indexed Locations

(If we can’t find what we want to add to index, we can click on “Show all locations” to show more locations)

2.3 Click on “OK” button to save the changes.

(Next time when the system is updating the index, those folders/contents will be indexed as well)

3 Rebuild Index

If you want to rebuild index instantly, here is how

3.1 After we have clicked on “OK” button, we are back to “Index Options” window again

Windows 10 Indexing Options
Windows 10 Indexing Options

3.2 Click on “Advanced” button

3.3 Click on the “Rebuild” button, now the system will start to rebuild the index (Note: It will take awhile, if you have heaps of files, it will take even longer)

Windows 10 Index Options - Advanced Options
Windows 10 Index Options – Advanced Options

When it’s finished, our files/folders will come up in the search results


How to: Quickly and Easily search a folder, partition or even computer for files in Microsoft Windows

When using Windows built-in search function, it can take ages to search a partition, it will take even longer if you want to search files across all partitions.

Everything is a free filename search software for Windows that can bring up your search results in seconds.

Everything
Everything
  • Small installation file
  • Clean and simple user interface
  • Quick file indexing
  • Quick searching
  • Quick startup
  • Minimal resource usage
  • Small database on disk
  • Real-time updating
  • Multilingual support
  • Has official portable version

Download Everything 1.4.1.935

Installer

64-bit Installer

Portable zip

64-bit Portable zip

Supported Languages

Language pack for Everything

Resource

Official website


Powerful Linux Interactive shell

fish (friendly interactive shell) is a smart and user-friendly command line shell for Linux, macOS, and the rest of the family.

Autosuggestions

Autosuggestion Thumbnail

fish suggests commands as you type based on history and completions, just like a web browser. Watch out, Netscape Navigator 4.0!

Glorious VGA Color

Colors Thumbnail

fish supports 24 bit true color, the state of the art in terminal technology. Behold the monospaced rainbow.

Sane Scripting

Scripting Thumbnail

fish is fully scriptable, and its syntax is simple, clean, and consistent. You’ll never write esac again.

Web Based configuration

Web Config Thumbnail

For those lucky few with a graphical computer, you can set your colors and view functions, variables, and history all from a web page.

Man Page Completions

Man Page Completions Thumbnail

Other shells support programmable completions, but only fish generates them automatically by parsing your installed man pages.

Works Out Of The Box

Works Out of the Box Thumbnail

fish will delight you with features like tab completions and syntax highlighting that just work, with nothing new to learn or configure.

fish can be installed easily on most Linux distros with their default package manager.

Linux

# Debian/Ubuntu/Kali Linux etc.
sudo apt install fish
 
# RHEL/CentOS/Fedora
sudo dns install fish
or, for older version
sudo yum install fish
 
# Archlinux
pacman -S fish
 
# gentoo Linux
emerge fish
 
# void-Linux
xbps-install fish-shell
 
# NixOS
nix-env -i fish
 
# Guix
guix package -i fish
 
# Solus
eopkg install fish
 
# Hombrew
brew install fish

BSD

# FreeBSD
pkg install fish
 
# OpenBSD
pkg_add fish

Windows

# Cygwin
fish is available in setup, in the Shells category.
 
# Windows Subsystem for Linux
sudo apt install fish
or
depend on the Linux distro you've chose, refer to the above "Linux" part to find correct command to use
 
# MSYS2
pacman -S fish

masOS

# Homebrew
brew install fish
 
# MacPorts
sudo port install fish
 
# Installer
https://github.com/fish-shell/fish-shell/releases/download/3.1.0/fish-3.1.0.pkg
 
10.6+: Installs to /usr/local/

Bonus

  • To use, type fish in the terminal then hit Enter key

To check fish version

echo $FISH_VERSION

HTML version help document

help

To switch default shell to fish

sudo chsh -s /usr/bin/fish

To switch back to default bash shell

sudo chsh -s /bin/bash

(If your default shell is zsh)

sudo chsh -s /usr/zsh

Open source/Free tools to find vulnerability in Active Directory (AD) – Grouper2

Grouper2 vs Grouper

Grouper

1 The computer must be joined to the domain with GPMC and RSAT installed

2 User must use Get-GPOReport with PowerShell to generate XML report

3 The report is required by Grouper

4 Users must manually filter out useful data

Grouper2

Grouper2 does not rely on Get-GPOReport, it still needs to parse different types of files format.

1 More accurate file permission detection, no read/write of storage required

2 Won’t ignore GPP password

3 Provide HTML format output

4 Multi-thread support

5 Supports offline mode

Official description

What is it for?

Grouper2 is a tool for pentesters to help find security-related misconfigurations in Active Directory Group Policy.

It might also be useful for other people doing other stuff, but it is explicitly NOT meant to be an audit tool. If you want to check your policy configs against some particular standard, you probably want Microsoft’s Security and Compliance Toolkit, not Grouper or Grouper2.

What does it do?

It dumps all the most interesting parts of group policy and then roots around in them for exploitable stuff.

How is it different from Grouper?

Where Grouper required you to:

  • have GPMC/RSAT/whatever installed on a domain-joined computer
  • generate an xml report with the Get-GPOReport PowerShell cmdlet
  • feed the report to Grouper
  • a bunch of gibberish falls out and hopefully there’s some good stuff in there.

Grouper2 does like Mr Ed suggests and goes straight to the source, i.e. SYSVOL.

This means you don’t have the horrible dependency on Get-GPOReport (hooray!) but it also means that it has to do a bunch of parsing of different file formats and so on (booo!).

Other cool new features:

  • better file permission checks that don’t involve writing to disk.
  • doesn’t miss those GPP passwords that Grouper 1 did.
  • HTML output option so you can preserve those sexy console colours and take them with you.
  • aim Grouper2 at an offline copy of SYSVOL if you want.
  • it’s multithreaded!
  • a bunch of other great stuff but it’s late and I’m tired.

Also, it’s written in C# instead of PowerShell.

How do I use it?

Literally just run the EXE on a domain joined machine in the context of a domain user, and magic JSON candy will fall out.

If the JSON burns your eyes, add -g to make it real pretty.

If you love the prettiness so much you wanna take it with you, do -f "$FILEPATH.html" to puke the candy into an HTML file.

If there’s too much candy and you want to limit output to only the tastiest morsels, set the ‘interest level’ with -i $INT, the bigger the number the tastier the candy, e.g. -i 10 will only give you stuff that will probably result in creds or shells.

If you don’t want to dig around in old policy and want to limit yourself to only current stuff, do -c.

If you want the candy to fall out faster, you can set the number of threads with -t $INT – the default is 10.

If you want to see the other options, do -h.

I don’t get it.

OK have a look at this:

A picture of some Grouper2 output

In the screenshot above we can see an “Assigned Application” policy that is still being pushed to computers, but the MSI file to install is missing, and the directory it’s being installed from is writable by the current user.

If you created a hacked up MSI (e.g. with msfvenom) and then modified it to match the UIDs at the bottom of the picture, it would get executed on machines targeted by the GPO. Sweet!

A picture of some Grouper2 output

In this one you can see that someone’s done something absolutely insane to the ACLS on the registry.

You get the picture.

Resource

Official Github page


Open source SSH/Telnet client

There are many open source and free SSH/Telnet clients, one of them is PuTTY.

PuTTY is very easy to use since it has GUI.

It can be downloaded from their official website

It has Microsoft Windows version, both in msi and exe format. It can be installed on the system or executed directly without installation.

It has Unix/Linux version as well, which can be downloaded from their official website too (source archive)

For Linux operating systems, we can also install directly from package managers as well.

Install on Linux

# Debian/Ubuntu/Kali Linux etc.
sudo apt install putty
 
# CentOS/RHEL/Fedora
sudo dnf install putty
or
sudo yum install putty
 
# Arch Linux
sudo pacman -S putty

Install on Linux from source

tar -xvf putty-0.73.tar.gz
cd putty-0.73/
./configure
sudo make && sudo make install

How to: Find Largest file on Windows, Windows 7, Windows 10, Microsoft Windows, Windows Server (Disk Space Usage)

For finding largest file/folder or showing disk space usage on Linux, refer to this one: (Linux Command Line/ Terminal Disk Space Usage tool (Find largest folder/file))

Sometimes, we want to find largest files or folders from our computer, especially when we are running out of space on hard drive. Because spending time to find different small useless files and then delete them can be very time consuming and after all it’s possible that we have only deleted couple MB of files which won’t help much. Remove one or two huge files or folders may help a lot.

Here is a list of software which can be used just for this purpose and for free, even better, some are open source.

WinDirStat

WinDirStat
WinDirStat
  • Easy to use
  • Free, Open Source
  • Can be installed
  • Portable version available (via portableapps)

SpaceSniffer

SpaceSniffer
SpaceSniffer
  • Easy to use
  • Free
  • Portable version available

WizTree

WizTree
WizTree
  • Easy to use
  • Free
  • Can be installed
  • Portable version available

Summary

Out of three, WinDirStat is the only open source one, Space Sniffer and WinTree are both freeware only.

WinDirStat does not provide official portable version, but portable version can be downloaded from portableapps. Both SpaceSniffer and WizTree provide official portable version.

All of them are very easy to use, the user interface of WinDirStat and WizTree are very similar, you click on the tile or block to reveal the file name, while SpaceSniffer displays the file and folder name directly on the tile/block.

Bottom line, choose whichever you like to use or give all of them a try and decide which one to go with, or even keep all of them in your bag, backup plan will not hurt 😉

Download/Resource

  1. WinDirStat
  2. SpaceSniffer
  3. WinTree

How to: Quickly remove printer jobs from Windows, Quickly reset printer jobs

Method 1

1 Save following text to ResetPrinterJob.cmd or ResetPrinterJob.bat

Simple version

rem https://dannyda.com
net stop spooler
del /q /s c:\windows\system32\spool\printers*.*
net start spooler

Verbose version

@echo off
echo dannyda.com
echo(
NET SESSION >nul 2>&1
IF %ERRORLEVEL% EQU 0 (
    ECHO Administrator PRIVILEGES Detected! 
) ELSE (
    ECHO This script has to be run with Administrator PRIVILEGES!
    ECHO(
    ECHO The script will now terminate.
    @pause
    exit
)
echo(
net stop spooler
del /q /s c:\windows\system32\spool\printers.
net start spoolerA
if %ERRORLEVEL% == 0 goto :successful
echo "Errors encountered during execution.  Exited with status: %errorlevel%"
goto :failed
:successful
echo The printer is ready for use again!
@pause
exit
:failed
echo "Script completed with error"
@pause

2 Run ResetPrinterJob.cmd or ResetPrinterJob.bat in Admin mode.

3 Now the printer is ready to be used again.

Method 2

1 Open “Task Manager” by using Ctrl + Alt + Delete key combination or right click on task bar then click on “Task Manager”

2 Click on “Services” tab

3 Find “Spooler”

4 Right click on it then click on “Stop”

5 Open file explorer navigate to “C:\Windows\system32\spool\PRINTERS”

6 Delete all files within the folder (Do not delete the “C:\Windows\system32\spool\PRINTERS” folder)

7 Bring back the Task Manager, start the Spooler service

8 Now the printer is ready to be used again.