Use the OpenSSL tool to write Bash scripts to encrypt and decrypt password plaintext

Use OpenSSL tools to encrypt and decrypt password plaintext Written By: Xinyao Tian Introduction This document describes a simple way to encrypt and decrypt passwords in a Bash script using the OpenSSL tool. BASE64 encryption and decryption script Use Base64 algorithm to encrypt password The script name is encryptPasswd.sh, and the script content is as […]

Binary plaintext string encryption: reduction and anti-reduction

Background The previous article introduced the principle of xorstr and the code of the minimal verification concept. This article looks at how to restore this technology that has been widely used in various malicious samples and security components. If you haven’t read the previous suggestion, Read it first to understand its implementation before reading this […]

Text editor with tagged line numbers based on QPlainTextEdit

Referenceqt example key code CodeEditor.h file #ifndef CODEEDITOR_H #define CODEEDITOR_H #include <QPlainTextEdit> #include <QPaintEvent> #include <QContextMenuEvent> #include <QMouseEvent> #include <QMouseEvent> #include <QPainter> #include <QTextBlock> #include <QFontMetrics> #include <QTextCursor> #include <QTextBlockFormat> #include <QTextDocument> #include <QTextCodec> #include <QMenu> #include <QScrollBar> QString GetQString(QByteArray byteArray);//Prevent garbled characters enum TagType {<!– –> NUMBER=0, MARKROUND,//circle MARKBLOCK //block }; class TagLineNumberArea; class […]

[Qt controls QLineEdit, QPlainTextEdit, QTextEdit, QTextBrowser] usage and differences

Introduction QLineEdit, QPlainTextEdit, QTextEdit and QTextBrowser are all controls used for text input and display in Qt. There are some differences between them and they are suitable for different scenarios. The following is a brief introduction, differences and usage tips for these four categories: Function Name Function QLineEdit QLineEdit is a simple single-line text input […]

code_edit project example 08: pure code custom code component (QPlainTextEdit implementation)

Create class #ifndef MYCODEEDIT_H #defineMYCODEEDIT_H #include <QPlainTextEdit> // Global declaration, otherwise when MyCodeEdit uses this class, it will prompt error: unknown type name ‘LineNumberWidget’ class LineNumberWidget; class MyCodeEdit : public QPlainTextEdit { Q_OBJECT public: explicit MyCodeEdit(QWidget *parent = nullptr); // void lineNumberWidgetPaintEvent(QPaintEvent *event); //Mouse click event processing, called outside the class void lineNumberWidgetMousePessEvent(QMouseEvent *event); // […]

Suppose the ciphertext obtained by encrypting a plaintext by affine transformation is: `edsgi ckxhu klzve qzvkx wkzuk vcuh` and it is known that the first two characters of the plaintext are `if`, decrypt the ciphertext (known plaintext attack)

Suppose the ciphertext obtained by encrypting a plaintext by affine transformation is: edsgi ckxhu klzve qzvkx wkzuk vcuh It is also known that the first two characters of the plaintext are if, Decrypt the ciphertext (known plaintext attack) Suppose we are studying a known-plaintext attack on an affine cipher. Affine ciphers are simple substitution ciphers […]

Connect to TiDB with a non-plaintext password on the command line

Author: GangShen Original source: https://tidb.net/blog/6794a34b During the process of connecting to TiDB on the command line, in order to protect the password from being obtained in plain text, you can use a non-plain text password to connect. This article records several ways to connect to TiDB in non-plaintext. Method 1: Command line input method [root@iZuf6d7xln13sovvijl68rZ […]

C#: AES encryption and decryption for plaintext encryption

Vernacular comprehension: Translate the characters that can be seen with a clear eye into another language that cannot be read, just like Morse code…just like base64 encryption, both have the same effect. Create a new class (the method of aes encryption and decryption is placed here) public static class AesPassword {<!– –> /// <summary> /// […]

Install the latest version of CMAK and handle the error java.util.NoSuchElementException: key not found: PLAINTEXT

Install the latest version of CMAK and handle the error java.util.NoSuchElementException: key not found: PLAINTEXT 1. Download CMAK 2. Decompress CMAK 3. Modify the configuration file Fourth, install jdk11 5. Start CMAK 6. Set Kafka cluster information on the CMAK interface Seven, complete error report Eight, the reason for the error Nine, the solution 1. […]

Securely access keys on the command line, avoiding plaintext keys in the CLI

Use pass to securely use and save keys in the Linux CLI, avoiding including plaintext keys on the command line or configuration files pass (short for password-store) is a simple command-line password manager for Linux. It stores passwords in a GPG-encrypted file. These encrypted files are well organized and stored in a directory structure. Because […]