Posts

Showing posts from January, 2024

Maigret: searches for information leaks via usernames [Github]

Image
Maigret compiles a profile for an individual based solely on their username, searching across a vast array of websites to aggregate all accessible data from web pages. No need for API keys. Maigret serves as an effective and user-friendly derivative of Sherlock. It currently supports over 3,000 websites (complete list available), and by default initiates searches on 500 of the most popular sites in decreasing order of their popularity. The tool also accommodates checks for Tor and I2P websites, as well as domain names through DNS resolution. GitHub URL: https://github.com/soxoj/maigret Project URL: https://pypi.org/project/maigret Main features Profile pages parsing, extraction of personal info, links to other profiles, etc. Recursive search by new usernames and other ids found Search by tags (site categories, countries) Censorship and captcha detection Requests retries See full description of Maigret features in the documentation . Demo with ...

Resolve error when installing software using apt-get [Linux]

Image
When I was using the apt-get command to install software in a Linux system, I encountered the following error message: E: Sub-process /usr/bin/dpkg returned an error code (1) I found a helpful solution in Google search results, as follows:  cd /var/lib/dpkg/ # Navigate to the dpkg directory sudo mv info/ info_bak # Rename the info folder first sudo mkdir info # Create a new info folder sudo apt-get update # Update sudo apt-get -f install # Repair sudo mv info/* info_bak/ # After executing the previous step, some files will be generated in the new info folder. Now move all these files to the info_bak folder sudo rm -rf info # Delete the newly created info folder sudo mv info_bak info # Rename the previous info folder back

HTTPS(SSL) Blocks WordPress Admin Access

Image
When a WordPress blog configures an SSL certificate to enable HTTPS, there is a certain probability that the following issues may arise: Website CSS styling is disorganized Incorrect display of image URLs Unable to access the website admin dashboard You can modify the wp-config.php file to solve these issues. Here's how: 1. Go to the root directory of your WordPress site and open the wp-config.php file in an editor. 2. Find the following code snippet in the file: ** @package WordPress */ 3. Insert the following lines of code immediately after the above snippet: $_SERVER['HTTPS'] = 'on'; define('FORCE_SSL_LOGIN', true); define('FORCE_SSL_ADMIN', true); 4. After completing the above steps, visit the admin dashboard of your website. In the General Settings page, change both the "WordPress Address (URL)" and "Site Address (URL)" from http to https, and save the changes. 5. Generally, for a brand-new WordP...

Python Script for Bulk Google Images Download(GitHub) to Disk

Summary Google Images Download Project: This command-line Python utility searches Google Images for specific keywords or phrases and has the option to download the resulting images to your local machine. It's a self-contained, ready-to-use program that doesn't require any external dependencies for downloads of up to 100 images per keyword. For downloads exceeding 100 images, you'll need to install Selenium and chromedriver . See the troubleshooting section for details. Compatibility The program works seamlessly with both Python 2.x and 3.x versions, although 3.x is recommended. It's a plug-and-play solution that requires no modifications to the original file. All you need to do is provide the necessary parameters via the command line. Installation You can use one of the below methods to download and use this repository. Install using pip $ pip install google_images_download Manually install using CLI $ git clone https://github.com/hardikvasa/google-images-downloa...

Repeated "Trust" Alerts on iPhone-MacBook Connection - disable USBD service

Image
When I connected my iPhone 13 Pro to my Macbook Pro using a cable, a "Trust" prompt kept repeatedly popping up on the iPhone's screen, preventing a successful connection with the Macbook. I tried changing cables, rebooting the iPhone, and restarting the Macbook, all to no avail ( Click here to view Apple's official suggestions for resolving this issue). Eventually, I found an effective solution through Google: disable USBD service. To disable and enable the USBD service , you can follow these steps. To disable USBD service 1. Open Terminal and enter the following command: sudo killall -STOP -c usbd 2. Press Enter and then input your password. Note that the password will not be visible while you're typing it.(The password to use is the one you set during boot-up.) To enable USBD service 1. Open the Terminal app again if it's not already open. 2. Type the following command: sudo killall -CONT usbd 3. Press Enter. By performing these steps, you shoul...

Installing Python3.10.x Version on Mac and Set the Environment

Image
MacOS already comes with Python2.7 and Python3.8 pre-installed. For specific reasons, I needed to install Python3.10.x separately. After installing the new Python version, some modifications to the default environment settings are required. This article serves as a memo detailing how to modify the environment settings after installing Python3.10 on a Mac. Steps for Installing Python3.10.x and Modifying Environment Settings: 1. Install Python3.10.x 2. Configure environment variables for Python3.10.x Install Python3.10.x 1. Download Python Go to the Python official website's download page , find the corresponding version, and proceed with the download. For the purpose of this article, I will be downloading Python3.10.6 as an example. 2. Scroll down to the bottom of the page and look for "Looking for a specific release?" Tips: Use Ctrl+F to search for the Python version number you wish to download. 3. Navigate to the Python3.10.6 download page. 4. Doub...

Batch rename files using the parent directory name

Image
After coming across suitable images, I save them immediately. However, over time, the directories and files of images sourced from the internet became extremely cluttered. I started reclassifying and organizing them, moving images with similar attributes to appropriate directories. Ultimately, while the images were neatly categorized, their arbitrary filenames were irksome. Facing this issue, I consulted Google and eventually stumbled upon an excellent solution: Batch rename files using the parent directory name. Open the Terminal app, then enter the following bash script code and press Enter to run: for dir in */; do count=1 for file in "${dir}"*; do if [[ -f "$file" ]]; then base=$(basename "$file") ext="${base##*.}" newname="${dir%/}_${count}.${ext}" mv "$file" "${dir}${newname}" ((count++)) fi done done This script will i...

Resolving the Issue of WordPress Plugin/Theme Installation Requiring FTP Information

Image
In WordPress, when you encounter a prompt to input FTP information during plugin installation or updates, it usually occurs because WordPress cannot directly access the file system and requires FTP protocol for these operations. There are two steps to resolve this issue. 1. Configuring via wp-config.php Log in to your WordPress host's file manager or use an FTP client. Locate the root directory of WordPress, typically found within the public_html folder on your web server. Inside this folder, you will find a file named wp-config.php, which is WordPress's configuration file. Open the wp-config.php file using a text editor. Add the following lines to the end of the file: define('FS_METHOD', 'direct'); ##Save and close the file. 2. Configuring WordPress Folder Permissions Log in to your web host's control panel or access the server via SSH. Locate the root directory of your WordPress website. Modify the permissi...

Batch command to create blank text files

This might be a rather unique requirement: I need to generate a vast number of empty text files. In the Windows operating system, I typically use the right-click menu to create a new text document and then rely on the copy-paste shortcuts for replication. While creating 10 files is straightforward, what about 100, 1,000, or even more? Actually, we can employ the Batch command to expedite the creation of numerous empty text files. This Batch command will create blank text files in the current directory . rem This batch command will create blank text files in the current directory. @echo off for /L %%x in (1,1,10) do @echo %%x>%%x.txt This command will create 10 blank text files, named 1.txt , 2.txt , ..., 10.txt . The for loop will iterate from 1 to 10, and for each iteration, it will create a new text file with the current iteration number as the filename. The echo. command will create a blank line in the text file. Here is an explanation of the Batch command: rem is a c...

Batch command to extract the filenames in the current directory

In daily life and work, we inevitably handle a multitude of files. Before managing these files, a primary concern is: How can I obtain their filenames in bulk? While there are many methods to achieve this, one straightforward approach is using Batch Command to retrieve filenames from the current directory. rem This batch command will extract the filenames in the current directory to a text file. dir /b > filenames.txt exit This command will create a text file named filenames.txt that contains a list of all the filenames in the current directory. The dir /b command will list all the files in the current directory, and the > filenames.txt will redirect the output of the dir command to the filenames.txt file. Here is an explanation of the command: rem is a comment that will be ignored by the command interpreter. dir /b is the command that will list all the files in the current directory. The /b option will list only the filenames, without any additional informati...

Batch command to Generate Text Files Based on Lines from a Source File

Due to some specific requirements, I often work with large amounts of data in Excel spreadsheets. Ultimately, I might need to transform each well-organized row of data into a separate text document. This is where Batch commands come in handy. The Batch command shared in this article can generate new text files line by line based on the content of a specified text file, creating one text file per line. The naming convention starts with 1.txt and proceeds sequentially. Open a text editor, such as Notepad. Copy and paste the following code into the editor: @echo off setlocal enabledelayedexpansion set count=1 for /f "delims=" %%a in (input.txt) do ( echo %%a > !count!.txt set /a count+=1 ) endlocal Save the code as a .bat file, for instance, generateFiles.bat . Ensure your source file, input.txt , is in the same directory as the .bat file. Double-click on generateFiles.bat to run it. Save the code as a .bat file, for instance, generateF...

Tutorial for Mac Spotlight

Mac Spotlight is a powerful search tool built into macOS that allows you to quickly find a wide range of items on your computer and perform various actions. Spotlight Basic Usage Using Spotlight is straightforward; simply press Command + Space or click on the magnifying glass icon in the top-right corner of your screen to open the Spotlight search bar. Enter what you're looking for in the search bar. Spotlight will display all content matching your search results. For example, to find a file named "myfile.txt," simply type myfile.txt . Spotlight will show all files matching "myfile.txt." Spotlight also supports wildcard searches, for instance, typing *.txt to find all .txt files. Search using regular expressions, like entering [0-9]+.txt to find all .txt files containing numbers. Spotlight also provides suggestions based on your search history and other factors. Spotlight Advanced Usage Spotlight supports many advanced search options for more precise...

Microsoft Launches Major Windows App: iPhone, Mac Users Experience Windows Directly

Image
On the hardware front, is Microsoft gradually dismantling the walls with software? Is there a convenient way to run Windows programs on Mac? At this year's Microsoft Ignite 2023 conference, Microsoft provided an answer by launching a new Windows App, which allows remote access to Windows operating system applications or other devices on various devices. Yes, this includes devices with iOS, iPadOS, macOS, Windows. This means that even non-Windows devices can quickly use Windows in the cloud, clearly showcasing Microsoft's greater ambition. What exactly is Windows App? According to the official description, Windows App is a gateway to Azure Virtual Desktop, Windows 365, Microsoft Dev Box, Remote Desktop Services, and Remote PC, securely connecting you to Windows devices and applications. In simple terms, you can open the Windows App application directly on Windows, macOS, iOS/iPadOS, Web browsers, and then access Azure Virtual Desktop, Windows 365, Microsoft Dev Box, Remote D...

Excel - Sort columns based on character length(LEN Function)

Image
Requirement Sort columns in an Excel spreadsheet based on the character length of the column data. How? Implementation(LEN function) First, use the " LEN " function in Excel to calculate the character count in each cell of the column, and then sort based on character count. Steps Open the Excel spreadsheet. Use the LEN function to count characters: In the second column (e.g., column B), enter the following formula in the first cell (B1): =LEN(A1) Sort based on character count. Microsoft Len function page

Adding Specific Applications to Windows 11 Startup Apps

Customizing startup items in Windows 11 is a great way to streamline your computer's boot-up process and ensure that your most-used applications launch automatically when the system starts. Below are the straightforward steps for adding specific applications to Windows 11's startup items: Click the " Start " button, then search or scroll to find the application you want to add to the startup items. Right-click on the application, select " More ," and then choose "Open file location." This action will open the location where the shortcut for that application is stored. If you don't see the "Open file location" option, it means that the application cannot be added to the startup items. After opening the file location, press WIN+R , enter shell:startup , and then click "OK." This action will open the "Startup" folder. Copy the shortcut of the application from the folder opened in Step 2 to the ...

Block Spam Traffic & Spam Web Crawlers

Image
In the era of the AI explosion, websites and servers face increasing interference from spam traffic, malicious web crawlers, and the need to block spam crawlers. These factors can pose serious threats to server resources, primarily in the following aspects: Consumption of Server Resources : Spam traffic and malicious web crawlers can consume server CPU, memory, bandwidth, and other resources, leading to a decrease in server performance and even crashes. Disruption of Normal Server Operation : Spam traffic and malicious web crawlers send a large number of invalid requests to the server, causing it to be unable to respond to legitimate user requests properly, disrupting the normal operation of websites and services. Security Risks : Spam traffic and malicious web crawlers may carry malicious code or viruses, posing security threats to the server. Why Block Spam Traffic and Shield Malicious Crawlers To protect server resources, ensure the normal operation of websites and s...

My ChatGPT Sharing

Image
My ChatGPT sharing has been quite interesting and educational, offering me a new perspective on AI-driven conversations. It's a helpful tool for exploring various topics, providing useful information and aiding in simple discussions. This journey with ChatGPT has been a modest yet valuable addition to my daily learning experiences. ideavat - Imagine Prompt Inspire Midjourney to generate unique and intriguing images by filling in the detailed and imaginative descriptions for provided image prompts. This also works for Stable Diffusion. ideavat - Imagine Prompt ideavat - Writing Assistant Improve readability by optimizing the text for grammar, clarity, and conciseness. ideavat - Writing Assistant ideavat - Power of Style Reimagine the uploaded image in a new style ideavat - Power of Style ideavat - Tranlation to English Translate any language into English ideavat - Tranlation to English