Questions tagged [aes]

Advanced Encryption Standard (AES) is a cryptographic block cipher algorithm.

Filter by
Sorted by
Tagged with
1 vote
0 answers
45 views

An implementation of encryption cascade

I'm looking for feedback on some source code, I have everything documented and have corrected some errors. Looking to see what I did correctly, incorrectly, and what can be improved. ...
bismofunyuns's user avatar
2 votes
1 answer
50 views

Implementation of aes-cbc-hmac combined with xchacha20-poly1305

I’m using two ciphers in this code that are in this order- encrypt plain text with xchacha20-poly1305 then encrypt the resulting ciphertext with aes-cbc-blake2b hmac. I was told elsewhere rather than ...
bismofunyuns's user avatar
0 votes
0 answers
1k views

Encrypt and decrypt text using 256-bit AES-GCM

I'm working on building an encrypt/decrypt feature using AES, and a fixed AES 256-bit key size. I have decided on using AES-GCM, as it seems the most performant and secure. I would like to know ...
Jake Nelson's user avatar
1 vote
0 answers
8k views

Simple AES encrypt/decrypt methods for .NET 6 and .NET Framework

I wrote some AES encryption/decryption methods with the following requirements: Inputs should be easy-to-use strings. Something encrypted in a .NET 6 app using these methods should be able to be ...
Rick Davin's user avatar
  • 6,217
0 votes
2 answers
2k views

AES GCM C++ implementation

I have written a C++ program that uses the Crypto++ library to encrypt files using AES-256Bit (in GCM mode). I am planning to eventually have the program store the keys for the files in a file e.g. ...
zero's user avatar
  • 11
1 vote
1 answer
5k views

AES implementation in C

I've implemented AES encryption in C to get more familiar with the language and to understand how encryption works better. I understand this code is unsuitable for actual cryptographic use and I'd ...
Henry's user avatar
  • 113
4 votes
1 answer
818 views

Rijndael Cipher in C++ (128bit AES)

I am a hobbyist and do not work in the industry, but I do have an interest in programming an cryptography. I decided to have a go at writing a 128bit implementation of AES in C++. This is my first ...
WireInTheGhost's user avatar
3 votes
0 answers
78 views

Arduino portenta H7 compatible message encryption and decryption

I am looking to build a message encryption/decription method that would allow messages to be encrypted in a timely fashion on board an Arduino Portenta H7, using as much of the onboard hardware ...
L Selter's user avatar
  • 131
4 votes
5 answers
5k views

C++ AES Encryption Class

I am working with OpenSSL and writing an AES256 encryption module. My knowledge of cybersecurity is not vast and I would like to know whether there are any obvious holes I'm leaving. The intent is for ...
kich's user avatar
  • 41
6 votes
2 answers
2k views

AES implementation in python

For educational purposes, I have implemented the AES block cipher in python. I decided to follow the interface for block cipher modules as defined in PEP 272. The implementation consists of two python ...
Aemyl's user avatar
  • 690
3 votes
2 answers
956 views

Encryption/Decryption between Python and Node JS

I have created a Python & Node JS encryption/decryption AES 256-CFB. The point of this little project is that I will encrypt a special URL with Python covered with base64 & URL encoding and ...
PythonNewbie's user avatar
3 votes
1 answer
1k views

AES GCM Encryption Code (Secure Enough or not)

I am creating one library for encryption/decryption using AES-256 with GCM Mode(With Random IV/Random Salt) for every request. Code I have written is(reference : AES Encryption/Decryption with key) : <...
Ankit Bansal's user avatar
3 votes
1 answer
1k views

Proper use of .NET Framework's AesManaged class

My co-worker and I have been tasked with encrypting and decrypting text data using AES256. However both of us feel quite uncomfortable with this as this sits squarely outside our normal problem ...
fersken's user avatar
  • 31
2 votes
2 answers
5k views

C# AES Encryption/Decryption or byte[] array with a custom Key/IV

I wanted to create an AES encryption service which will use a custom key/iv. I want 2 methods: dycrypt/encrypt byte[] The code works as expected, any remarks/issues? ...
omriman12's user avatar
  • 121
1 vote
2 answers
918 views

Securely implementing AES/RSA hybrid crypto with PyCryptodome

I wondering if anyone could give me feedback on whether or not this is a secure way to implement AES/RSA hybrid encryption and signatures in python 3 with the PyCryptodome module. All of the encoding ...
Joe Smith's user avatar
  • 170
2 votes
1 answer
3k views

Java Cryptography AES/GCM/NoPadding without IV

I'm implementing a PAKE-protocol as a university project and one step of the protocol involves sending encrypted data from a key created via a hash function (I'm using SHA-256). I want to use AES/GCM ...
recke96's user avatar
  • 23
2 votes
1 answer
6k views

AES-256-CBC encrypt and decrypt files in Python

I wrote a simple algorithm to encrypt and decrypt files in Python using aes-256-cbc. ...
Stageflix's user avatar
2 votes
2 answers
1k views

Encrypt data before sending it to server in a way that makes it unreadable to anyone except the user who sent it

I don't have any experience in cryptography and I've written some crypto code that seem to be working, but I'm not sure if it safe and if the tools and methods I used are right. Objective Make it ...
Igor Bubelov's user avatar
2 votes
1 answer
602 views

Validate implementation of ECIES

I've created a basic implementation of ECIES (Elliptic Curve Integrated Encryption Scheme) based on http://www.secg.org/sec1-v2.pdf section 5.1. ...
Cocowalla's user avatar
  • 123
2 votes
0 answers
85 views

Custom mini cipher

I'm a 14year old and still learning. I know everyone says "don't roll your own crypto", however I decided I must make my own cipher in javascript as soon as I have enough knowledge. I started simple ...
Franartur Čech's user avatar
2 votes
1 answer
2k views

Java RSA / AES-GCM encryption utility

I wrote a utility class that has simple methods for: En/decrypting data with 256-bit AES-GCM using a password Generating RSA keypair Saving RSA keypair and storing private key encrypted En/decrypting ...
A. Tork's user avatar
  • 23
7 votes
1 answer
698 views

CypherVault - Command Line Password Manager

I have created a Python 3 password manager for API keys and social media passwords on local storage. The script is 500 lines and PEP8/PYLINT compliant, each definition contains a docstring and the ...
litepresence's user avatar
2 votes
2 answers
76 views

Decrypt multiple 10Mb files with defined password

One operation of my Android project is to decrypt one file (chosen in a set of ~30 files for pagination1) of ~10 Mb each and I do this with the following: ...
Cliff Burton's user avatar
1 vote
1 answer
696 views

Password hashing (PBKDF2) and RSA encrypt + AES 256 in Java

Here's what I could comprehend in C code: Generates a key using PBKDF2 Generates an IV which is MD5 of PBKDF2 key in step #1 Does AES-256 encryption on customer-id - which is one of the output RSA ...
stack123's user avatar
7 votes
1 answer
96 views

File(s) encrypter implementation in python

I'm looking for any feedback in order to improve code styling, performance etc. Also I want to make sure that the way I've implemented AES here is actually secure ...
El-Chief's user avatar
  • 203
3 votes
1 answer
122 views

CliwPw - Yet Another Python3 Password Manager

I wrote a (very) simply Python3 password manager to familiarize myself with Sqlite3, and for fun. I am aware that there are already a variety of password managers out there, but I wanted something ...
Chev_603's user avatar
  • 161
4 votes
1 answer
665 views

Python Secure Implementation Of AES-256-CTR Using Cryptography.Hazmat

I've implemented a wrapper for AES 256 CTR mode using the cryptography.hazmat module, I am wondering if there are any vulnerabilities in my implementation, specifically about the counter and its ...
SamG101's user avatar
  • 151
4 votes
2 answers
509 views

C# Cryptography Interface

C# lacks a common off-the-shelf encryption and decryption interface for dependency injection. Nearly every codebase I've ever opened has a couple of extension methods for hashing strings and so on. ...
Christian Findlay's user avatar
1 vote
0 answers
1k views

AES encryption/decryption in rust: performance and best practices

I wrote a small rust library available on github that can encrypt/decrypt a 16 bytes block using either 128, 192 or 256 bit passwords. This implementation is tested with the test data provided in the ...
Ivano Donadi's user avatar
0 votes
1 answer
110 views

employing AES algorithm in Java

I have employed an AES algorithm in order to encrypt files within a GUI. I was wondering if my algorithm is secure. Could I change anything to improve it? Is my IV secure and is it producing different ...
adot710's user avatar
  • 131
12 votes
3 answers
10k views

Python password manager

I am writing a python password manager, and I know there's a lot of scrutiny that goes into storing passwords (don't worry, mine aren't plaintext). I was hoping that this community could help me ...
David Culbreth's user avatar
2 votes
1 answer
529 views

Encrypts using AES GCM for data with limited visibility and long rest

This is the third iteration of my venture on creating an encryption/decryption solution. I asked a question here, which led to this question here, which led to this answer here, which led me to ...
user1447679's user avatar
1 vote
1 answer
797 views

Encrypts using AES with random initialization vector meant for data with limited visibility and then long rest

I've done some research, reviewed countless SO questions that appeared similar, leading me to endless rabbit holes. My solution is working, but I don't like it. I want to create a random IV for AES ...
user1447679's user avatar
3 votes
1 answer
2k views

AES GCM Python implementation

I've recently started looking into encryption in python and I came across with pycryptodome library. I made this simple program that encrypt/decrypt a file using AES-GCM. Could someone take a look if ...
Bernardo1r's user avatar
2 votes
1 answer
470 views

AES CTR mode encryption with HMAC

I am trying to implement AES CTR encryption mode with HMAC authentication for messages. It's encrypting and decrypting fine as long as the key length is 64 bytes, since AES key and HMAC key are ...
GraphicalDot's user avatar
1 vote
1 answer
97 views

Rijndael S-box for a string of bits

My question is more of a "can someone give me tips" rather than "can you do it for me" I have been writing a C code implementation that takes a 32-char String in the form of binary (supposed to act ...
Ameer Shalabi's user avatar
1 vote
1 answer
84 views

Encrypt data to be send from service to service

I'm working with another company in a new application for my company. My job right now is to send on demand to the other company the data that they need, ciphering some of it. I should point out that ...
ikerbera's user avatar
2 votes
2 answers
632 views

Basic AES/CBC implementation in Java

A little bit about myself: I am 18 years old, a student living in Germany and currently working on an android app. I would like if someone has the time to review my code. I am especially interested ...
Leumon's user avatar
  • 23
0 votes
1 answer
47 views

Shell POSIX OpenSSL file decryption script follow-up #3 (final)

From original very simplistic code: Shell POSIX OpenSSL file decryption script I learned a lot both from the first follow-up review, and the second one as well, many thanks! I just need one final ...
Vlastimil Burián's user avatar
0 votes
1 answer
64 views

Shell POSIX OpenSSL file decryption script follow-up #2

This question is the second follow-up of: Shell POSIX OpenSSL file decryption script The first follow-up was: Shell POSIX OpenSSL file decryption script follow-up #1 Both of which have proven very ...
Vlastimil Burián's user avatar
1 vote
2 answers
189 views

Long-term archiving + encrypting shell script

Yesterday, I very quickly, in an hour, wrote the very first version of my long-term archiving + encrypting shell script. I am aware it may have too many flaws, but none of them really prevent it from ...
Vlastimil Burián's user avatar
3 votes
1 answer
4k views

Java AES file encryption/decryption

I've written a simple Java class to encrypt and decrypt files using AES. The code works and I'm able to encrypt and decrypt files. However, I understand this is an easy way of implementing AES and ...
Viva's user avatar
  • 93
3 votes
2 answers
129 views

JSafebox - Encrypted vault - 2nd drill

I am developing JSafebox, a portable safebox project written in Java. A first review have been completed here. The goal is to provide a secured environment where the user can browse encrypted files ...
ortis's user avatar
  • 165
8 votes
2 answers
270 views

Encrypted safebox

I am developing JSafebox, a portable safebox project written in Java. The goal is to provide a secured environment where the user can browse encrypted files without leaking data on the drive. The ...
ortis's user avatar
  • 165
8 votes
3 answers
6k views

File encryption with password

I would like to have my C# cryptography code reviewed. I programmed an application that encrypts files with a password (provided by the user). It basically functions as a password manager, on the ...
Mick's user avatar
  • 91
6 votes
2 answers
5k views

AES File Encryption / Decryption

I've been looking for a while for the right code to encrypt/decrypt files with AES in vb.net. I created the code below. Is this the right way doing AES encryption/decryption nowadays? ...
Jp19's user avatar
  • 71
7 votes
1 answer
2k views

Encryption and decryption on streams using AES CBC + HMAC SHA

The goal of the code below is to: Support authenticated encryption using AES in the CBC mode and using HMAC SHA. Support encryption and decryption of data of size larger than memory (potentially). ...
ebvtrnog's user avatar
  • 171
4 votes
1 answer
438 views

Plain Java Encryption with Integrity and Authenticity

I spent quite some time and wrote a single class for the purpose of encrypting/decrypting plaintext bytes with a passphrase. The goal is to not have any further dependencies apart from ...
trichner's user avatar
  • 141
2 votes
1 answer
6k views

AES Encryption/Decryption with key

Is this the best way to encrypt/decrypt data? And Is it good to store Generated InitVector and CipherText in database as Base64 String which is converted from byte[]? ...
Hary's user avatar
  • 133
6 votes
3 answers
3k views

Java AES CBC encryption/decryption

I've looked at multiple examples of Java AES CBC mode encryption but I couldn't find a proper solution that's safe to use. I ended up writing my own utility class. My questions is: Is this code safe ...
user avatar