Understanding Cross-Origin Resource Sharing (CORS)

CORS

Cross-Origin Resource Sharing (CORS) is a security mechanism implemented in web browsers to control how resources on a web server can be requested from a different origin (domain, protocol, or port). It is a crucial part of modern web security, helping to prevent malicious cross-site request forgery (CSRF) attacks while allowing legitimate cross-origin requests. What … Read more

Understanding Cross-Site Request Forgery (CSRF)

Cross-Site Request Forgery (CSRF) is a type of web security vulnerability where an attacker tricks a user into performing unwanted actions on a web application where they are authenticated. What is CSRF? CSRF exploits a web application’s trust in the user’s browser and can lead to serious security breaches, such as unauthorized transactions, data modification, … Read more

Merkle Tree in blockchain

What Is a Merkle Tree? A Merle tree is a data structure that stores the hash of the combined children in each parent. It is also known as a hash tree. Merkle root servers as a summary for all data. How is Merkle root calculated?  It starts with the hash of leaf nodes. Then we … Read more

Everything about hashing in Blockchain

The process of converting an arbitrary size of data into a fixed-sized value is called hashing and it is a one-way process, i.e. the input can’t be retrieved from the output(hash). Read more about hashing from here.   It is an integral part of blockchain technology. We have a lot of hashing algorithms that can be used … Read more

Cryptography in Blockchain

Cryptography is the method of securing data from unauthorised access. When we say Cryptography, we are looking for the following. Before going to blockchain in cryptography, let’s first understand cryptography.  Confidentiality   The information cannot be understood by anyone for whom it was unintended. Except for the sender and receiver, no one can read the message. Integrity … Read more

PHP Standards Recommendations (PSR)

As technology usage increases, everyone develops their own way of using it. This leads to difficulties in maintaining consistency and interoperability. Example:Developers follow different naming conventions and coding styles. For instance, method names may be written in various styles like camelCase, snake_case, etc. These inconsistencies make it challenging to work across different frameworks and PHP … Read more

Bit Manipulation: A Powerful Tool for Efficient Programming

Bit manipulation is a fundamental technique in programming that involves operating directly on bits—the basic units of information in computers. It enables high-performance solutions for many computational problems, particularly in competitive programming, cryptography, embedded systems, and optimisation tasks. Understanding bitwise operations can significantly improve code efficiency and reduce execution time. Binary representation Computers only understand … Read more

Essential SQL Queries collection

Query Collections Duplicate value Delete Duplicate Records While Keeping One Efficiently remove duplicates but keep one copy. Way 1 Recommended way cte + window It’s a more modern SQL approach, clearer in intent when dealing with duplicates, and easier to adapt for more complex rules. Read Further Way 2: subquery Nth Largest Value Replace query … Read more

Understanding Logging Levels

Logging Levels

Logging levels help categorize log messages by severity, ensuring developers and system administrators can efficiently filter and analyze logs. This article explores different logging levels, their purposes, and best practices. What Are Logging Levels? Logging levels define the importance and severity of log messages. These levels help in managing log verbosity and ensuring that critical … Read more