Skip to main content

A SECURE DATA PERSISTENCE STRATEGY USING ENTITY FRAMEWORK CORE WITH DYNAMIC ENCRYPTION IN ENTERPRISE

Page 1


International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

A SECURE DATA PERSISTENCE STRATEGY USING ENTITY FRAMEWORK CORE

WITH DYNAMIC ENCRYPTION IN ENTERPRISE .NET SYSTEMS

1Master of Technology, Computer Science and Engineering, Lucknow Institute of Technology, Lucknow, India

2Assistant Professor, Department of Computer Science and Engineering, Lucknow Institute of Technology, Lucknow, India

Abstract - In modern enterprise .NET applications, data persistence frameworks such as Entity Framework Core (EF Core) are widely adopted for efficient database interaction andrapiddevelopment.However,EFCoreprimarilyfocuseson simplifyingObject–RelationalMapping(ORM)operationsand lacks built-in mechanisms for securing sensitive data at the application level. This limitation exposes critical enterprise information to potential security threats, including unauthorized access, data breaches, and insider attacks. To address this challenge, this research proposes a secure data persistence strategy that integrates dynamic encryption techniques within the EF Core data access pipeline. The proposed approach introduces an encryption module that automatically encrypts sensitive data fields before database storage and decrypts them during retrieval, ensuring data confidentiality without altering application logic. The framework leverages EF Core features such as value converters and interceptors to seamlessly embed encryption intopersistenceoperations.Aprototypeenterpriseapplication is developed using ASP.NET Core and EF Core to validate the feasibility of the proposed model. Experimental evaluation demonstrates that the proposed strategy significantly enhances data security while maintaining acceptable performanceoverhead.Comparativeanalysiswithtraditional and static encryption approaches highlights improved flexibility and stronger protection. The findings suggest that integrating dynamic encryption within ORM frameworks provides an effective solution for secure data persistence in enterprise environments.

Key Words: Entity Framework Core, Dynamic Encryption, Secure Data Persistence, ORM Security, Enterprise .NET Systems, Data Protection

1. INTRODUCTION

1.1 Background

1.1.1 Evolution of Enterprise Architectures (Monolithic → Microservices)

Enterprisesoftwaresystemshaveundergonea significant transformation over the past few decades, evolving from tightlycoupledmonolithicarchitecturestohighlymodular and distributed microservices-based systems. Traditional monolithicapplicationsintegratedallfunctionalities such asuserinterface,businesslogic,anddataaccess withina

singlecodebase,makingthemeasiertodevelopinitiallybut difficult to scale and maintain over time. With the rise of cloud computing and distributed systems, organizations have shifted toward microservices architectures, where applications are decomposed into independent, loosely coupledservicesthatcommunicateviaAPIs.Thisevolution has improved scalability, flexibility, and deployment efficiency, enabling enterprises to respond rapidly to changingbusinessrequirements(Newman,2015).

1.1.2 Importance of Data-Driven Systems and Persistence

Modern enterprise applications are fundamentally datadriven, relying on persistent storage systems to manage large volumes of critical information such as customer records, financial transactions, and operational data. Data persistenceensuresthatinformationremainsdurableand accessibleacrossapplicationlifecycles,supportingbusiness continuityanddecision-makingprocesses.Asorganizations increasingly depend on real-time analytics and intelligent systems, the role of efficient and secure data persistence mechanisms has become crucial. Persistent storage frameworks, particularly those integrated with ORM technologies, enable seamless interaction between applicationsanddatabaseswhilemaintainingdataintegrity andavailability(Silberschatz,KorthandSudarshan,2019).

1.2 Problem Statement

1.2.1 Lack of Field-Level Encryption in EF Core

Despite its widespread adoption in enterprise .NET applications, Entity Framework Core (EF Core) does not provide built-in support for field-level encryption of sensitive data. While it simplifies database interactions through abstraction and automation, its default configurations prioritize developer productivity over security. As a result, sensitive fields such as personal identifiers,credentials,andfinancialdataareoftenstoredin plaintext unless additional security mechanisms are implementedmanually(Lerman,2020).

1.2.2 Exposure of Sensitive Enterprise Data

TheabsenceofintegratedencryptionmechanismsinORM frameworksincreasestheriskofdataexposureinenterprise

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

systems. Databases often become prime targets for cyberattacks,includingSQLinjection,unauthorizedaccess, andinsiderthreats.Ifsensitiveinformationisstoredwithout encryption,attackers whogainaccesstothe databasecan easily exploit such data, leading to financial losses, reputational damage, and regulatory violations (Whitman andMattord,2018).

1.2.3 Limitations of Traditional/Static Encryption

Traditional encryption approaches, particularly static encryption methods, apply fixed encryption mechanisms that lack adaptability to dynamic system requirements. Thesemethodsoftenrequiremanualintegration,increasing development complexity and limiting scalability. Furthermore,staticencryptionmaynoteffectivelyaddress runtime security needs or varying data sensitivity levels, makingitlesssuitablefor modern enterpriseapplications that demand flexible and efficient security solutions (Stallings,2017).

1.3 Research Objectives

1.3.1

Analyze ORM Security Issues

This research aims to critically examine the security limitations inherent in ORM frameworks, particularly focusing on EF Core. The analysis includes identifying vulnerabilities related to data storage, access control, and lackofbuilt-inencryptionmechanisms,therebyestablishing theneedforenhancedsecurityintegration(Fowler,2018).

1.3.2

Design Dynamic Encryption Model

A key objective of this study is to design a dynamic encryption model that adapts to runtime conditions and selectivelyencryptssensitivedatafields.Thismodelseeksto balance security and performance by applying encryption only where necessary, improving efficiency in enterprise systems(GreenandSmith,2016).

1.3.3

Integrate with EF Core

The research further aims to integrate the proposed encryptionmodelseamlesslywithintheEFCorepersistence pipeline. By leveraging EF Core features such as value converters and interceptors, the study ensures that encryption and decryption processes occur transparently withoutdisruptingapplicationlogic(Microsoft,2023).

1.3.4 Evaluate Performance and Security

Anotherimportantobjectiveistoevaluatetheeffectiveness of the proposed approach in terms of both security enhancement and performance impact. Experimental analysis is conducted to measure encryption overhead, query execution time, and resistance to data breaches, ensuringpracticalapplicabilityinenterpriseenvironments.

1.4 Research Questions

1.4.1 How to Integrate Encryption in EF Core?

Thisresearchinvestigateshowencryptionmechanismscan be embedded within the EF Core data access workflow without requiring extensive modifications to application architecture.Itexplorestechniquessuchasvalueconverters, middleware, and custom encryption services to achieve seamlessintegration.

1.4.2 What is the Performance-Security

Tradeoff?

Another key research question examines the tradeoff betweenenhanceddatasecurityandsystemperformance. While encryption improves confidentiality, it introduces computationaloverhead.Thisstudyevaluateswhetherthe proposed dynamic encryption approach maintains an optimalbalancebetweenthesetwocriticalfactors(Katzand Lindell,2020).

2. LITERATURE REVIEW

2.1 Data Persistence in Enterprise Systems

2.1.1 Traditional vs Modern Persistence

Datapersistencehaslongbeenafoundationalcomponentof enterprise systems, enabling the storage and retrieval of critical business information. Traditional persistence approachesprimarilyrelied onfilesystemsandrelational databasemanagementsystems(RDBMS),wheredevelopers manuallyinteractedwithstructuredquerylanguages(SQL) tomanagedataoperations.Whilethesemethodsprovided strong data consistency and transactional integrity, they often resulted in increased development complexity and limited scalability. In contrast, modern persistence mechanisms leverage abstraction layers, distributed databases, and cloud-native architectures to improve scalability,flexibility,andmaintainability.Technologiessuch as Object–Relational Mapping (ORM) frameworks and microservices-based storage solutions allow seamless interaction with databases while supporting high-volume, real-time data processing. This evolution reflects the growingdemandforefficientandscalabledatamanagement inenterpriseenvironments(ElmasriandNavathe,2016).

2.2 ORM Frameworks and Security

2.2.1 ORM Abstraction Benefits & Risks

Object–Relational Mapping (ORM) frameworks have significantlysimplifieddatabaseinteractionbyabstracting the complexity of SQL-based operations and enabling developers to work with object-oriented paradigms. This abstractionimprovesproductivity,reducesboilerplatecode, and enhances maintainability of enterprise applications. However, the abstraction layer also introduces certain security risks. Developers may rely heavily on ORM-

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

generated queries without fully understanding their underlying behavior, potentially leading to inefficient queriesorvulnerabilitiessuchasimproperdatavalidation. Additionally, ORM frameworks often lack built-in mechanisms for securing sensitive data at the field level, making them susceptible to data exposure if additional security measuresarenotimplemented.Thus, while ORM frameworks offer substantial development benefits, they requirecarefulconfigurationandintegrationwithsecurity practicestoensurerobustdataprotection(Fowler,2018).

2.3 Entity Framework Core

2.3.1 Architecture (DbContext, DbSet, LINQ)

Entity Framework Core (EF Core) is a modern ORM framework designed for the .NET ecosystem, providing a structured approach to data access and persistence. Its architecture is centered around key components such as DbContext,whichactsastheprimaryinterfacebetweenthe application and the database, managing connections and tracking changes to entities. The DbSet component representscollectionsofentitiesmappedtodatabasetables, enabling CRUD (Create, Read, Update, Delete) operations. Additionally, EF Core utilizes Language Integrated Query (LINQ)toallowdeveloperstowritedatabasequeriesusing programming language syntax, thereby improving code readability and type safety. These architectural features collectively streamline database operations and support efficient development of enterprise applications (Lerman, 2020).

2.3.2 Limitations in Security

Despite its architectural strengths, EF Core has notable limitations in terms of data security. The framework does not inherently provide field-level encryption for sensitive data,leavingcriticalinformationvulnerableifnotexplicitly protected.Whileitsupportssecureconnectionprotocolsand basicauthenticationmechanisms,itreliesondevelopersto implement advanced security features such as encryption and access control. This limitation becomes particularly significantinenterpriseenvironmentswherelargevolumes of sensitive data are processed and stored. Consequently, additionalmechanismsmustbeintegratedintotheEFCore pipelinetoensurecomprehensivedataprotection(Hoffman, 2019).

2.4 Database Security Techniques

2.4.1

Encryption at Rest, in Transit, Field-Level

Database security techniques are essential for protecting sensitiveinformationfromunauthorizedaccessandcyber threats. Encryption at rest ensures that data stored in databasesorstoragesystemsremainsencrypted,preventing unauthorized users from interpreting it even if they gain accesstothestoragemedium.Encryptionintransitsecures

data as it moves between applications, servers, and databases, protecting it from interception during communication. Field-level encryption provides an additionallayerofprotectionbyencryptingspecificsensitive attributes, such as personal identifiers or financial data, withindatabaserecords.Together,thesetechniquesforma multi-layered security approach that enhances data confidentialityandintegrityinenterprisesystems(Stallings, 2017).

2.5 Encryption Techniques

2.5.1

Symmetric (AES), Asymmetric (RSA)

Encryption techniques are fundamental to securing enterprisedata.Symmetricencryptionalgorithms,suchas theAdvancedEncryptionStandard(AES),useasinglesecret key for both encryption and decryption, offering high performanceandefficiencyforlarge-scaledataprocessing. Incontrast,asymmetricencryptionalgorithms,suchasRSA, useapairofkeys apublickeyforencryptionandaprivate key for decryption providing enhanced security for key exchangeandcommunication.Whilesymmetricencryption isfasterandsuitableforbulkdataencryption,asymmetric encryptionistypicallyusedforsecurekeydistributionand authenticationprocesses.Combiningbothapproachesisa commonpracticeinenterprisesystemstoachieveoptimal securityandperformance(KatzandLindell,2020).

2.5.2 Static vs Dynamic Encryption

Traditional static encryption methods apply a fixed encryption mechanism to data, regardless of context or usagepatterns.Whilethisapproachensuresabaselinelevel ofsecurity,itlacksflexibilityandmayintroduceunnecessary computationaloverhead.Dynamicencryption,ontheother hand, adapts encryption processes based on runtime conditions, data sensitivity, or access requirements. This selective encryption approach enhances efficiency by protecting only critical data while maintaining system performance.Dynamicencryptionisparticularlysuitablefor modern enterprise applications that require both strong securityandhighscalability(GreenandSmith,2016).

2.6 Research Gap

2.6.1

No Integrated Dynamic Encryption within EF Core Pipeline

Existing research and enterprise practices reveal a significant gap in integrating dynamic encryption mechanisms directly within ORM frameworks such as EF Core. While various studies have explored database-level encryptionandapplication-levelsecuritytechniques,thereis limited work on embedding encryption seamlessly within theORMdatapersistencepipeline.Thislackofintegration results in fragmented security implementations and increaseddevelopmentcomplexity.

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

2.6.2 Lack of Performance-Aware Secure Persistence Frameworks

Another critical gap lies in the absence of performanceaware secure persistence frameworks that balance data security with system efficiency. Many existing solutions focusprimarilyon enhancingsecurity withoutadequately considering the performance overhead introduced by encryption processes. Consequently, there is a need for a comprehensive framework that not only secures data but also evaluates and optimizes the tradeoff between encryption overhead and application performance. Addressingthesegapsformstheprimarymotivationforthe proposedresearch.

3. PROPOSED METHODOLOGY

3.1 Research Design

3.1.1 Design Science Research (DSR) Approach

This research adopts the Design Science Research (DSR) methodology,whichiswidelyusedininformationsystems andsoftwareengineeringtodevelopandevaluateinnovative technological solutions. The DSR approach focuses on creating a functional artefact in this case, a secure data persistenceframework thataddressesaspecificproblem identifiedinenterprisesystems.Themethodologyfollowsa structured process consisting of problem identification, objective definition, artefact design, development, demonstration,andevaluation.Inthecontextofthisstudy, the problem of inadequate data security in EF Core persistenceisaddressedbydesigningadynamicencryptionintegrated framework. The artefact is implemented as a prototype enterprise application and evaluated through experimental analysis to validate its effectiveness in improving data security while maintaining acceptable performancelevels.

3.2 System Overview

3.2.1 Secure Persistence Framework Integrating EF Core, Encryption Module, and Key Management

The proposed system introduces a secure persistence frameworkthatintegratesthreeprimarycomponents:Entity FrameworkCore(EFCore),anencryptionmodule,andakey managementsystem.EFCoreservesasthedataaccesslayer, enabling object-oriented interaction with relational databases. The encryption module is responsible for automaticallyencryptingsensitivedatabeforestorageand decrypting it upon retrieval, ensuring data confidentiality throughout the data lifecycle. The key management componenthandlesthegeneration,storage,androtationof cryptographickeys,ensuringsecureandreliableencryption operations.Bycombiningthesecomponents,theframework provides a seamless and automated approach to securing

sensitive enterprise data without requiring significant modificationstoapplicationlogicordatabasestructures.

3.3 Architecture Design

3.3.1

Multi-Layer Architecture

The proposed framework is designed using a multi-layer architecturetoensuremodularity,scalability,andseparation ofconcerns.Thisarchitecturalapproachdividesthesystem into distinct layers, each responsible for specific functionalitieswithinthedatapersistenceprocess.

Application Layer

The application layer represents the topmost layer of the system and is responsible for handling user interactions, businesslogic,andrequestprocessing.Itcommunicateswith thedataaccesslayertoperformdatabaseoperationswhile remaining independent of underlying encryption mechanisms. This separation ensures that security enhancementsdonotdisruptapplicationfunctionality.

Data Access Layer (EF Core)

ThedataaccesslayerisimplementedusingEFCore,which acts as the intermediary between the application and the database.Itmanagesentitytracking,querygeneration,and transaction handling. EF Core abstracts database interactions, allowing developers to work with strongly typed objects instead of raw SQL queries. Within the proposed framework, this layer also interacts with the encryptionmoduletoensuresecuredatapersistence.

Encryption Layer

Theencryptionlayerisadedicatedcomponentresponsible for applying cryptographic operations to sensitive data. It performsencryption before data isstoredin the database anddecryption when data isretrieved.Thislayer ensures that sensitive information is never stored in plaintext, thereby enhancing data confidentiality and protecting againstunauthorizedaccess.

Database Layer

Thedatabaselayerrepresentsthepersistentstoragesystem, typically implemented using relational database managementsystemssuchasSQLServerorPostgreSQL.In the proposed architecture, the database stores only encrypted data, ensuring that even if unauthorized access occurs, the stored information remains protected and unreadablewithoutproperdecryptionkeys.

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

3.4 Dynamic Encryption Model

3.4.1

Runtime Encryption/Decryption

The dynamic encryption model operates at runtime, automaticallyapplyingencryptionanddecryptionprocesses duringdataoperations.Whendataisinsertedorupdated, theencryptionmoduleencryptssensitivefieldsbeforethey are persisted in the database. Similarly, when data is retrieved, the module decrypts the encrypted fields to provide readable information to the application. This runtimeapproachensuresseamlessintegrationofsecurity mechanisms without requiring manual intervention from developers.

3.4.2

Selective Field-Level Encryption

Unliketraditionalapproachesthatencryptentiredatasets, the proposed model implements selective field-level encryption, targeting only sensitive attributes such as personal identifiers, credentials, and financial data. This selectiveapproachreducescomputationaloverheadwhile maintainingstrongsecurityforcriticaldata.Italsoprovides flexibility by allowing developers to define which fields requireencryptionbasedonapplicationrequirementsand securitypolicies.

3.5 Integration with EF Core

3.5.1

Value Converters

Value converters in EF Core are used to transform entity property values during database operations. In this framework, value converters are utilized to automatically encryptdatabeforeitisstoredinthedatabaseanddecryptit whenretrieved.Thisapproachallowsencryptionlogictobe embedded directly within the entity model, ensuring transparencyandminimalimpactonapplicationcode.

3.5.2

Interceptors

Interceptorsprovideamechanismtointerceptandmodify database operations within the EF Core pipeline. They enabletheimplementationofcross-cuttingconcernssuchas logging,validation,andsecurity.Intheproposedframework, interceptors are used to enforce encryption policies dynamically by intercepting database commands and applyingencryptionordecryptionprocessesasrequired.

3.5.3 Middleware Security Layer

The middleware security layer acts as an additional abstraction within the application pipeline, ensuring consistent enforcement of security policies across all data operations. It integrates with the application’s request–response cycle and works alongside EF Core to manage encryptionprocesses.Thislayerenhancestheflexibilityand scalabilityoftheframework bycentralizingsecuritylogic,

reducing redundancy, and ensuring uniform protection of sensitivedataacrossthesystem.

4. SYSTEM IMPLEMENTATION

4.1 Development Environment

4.1.1

ASP.NET Core

The implementation of the proposed secure persistence frameworkiscarriedoutusingASP.NETCoreastheprimary applicationdevelopmentplatform.ASP.NETCoreprovidesa robust and scalable environment for building enterprisegrade web applications and APIs. It supports modular architecture, middleware integration, and cross-platform deployment, making it suitable for implementing secure data-drivensystems.Withinthisresearch,ASP.NETCoreis usedtohandleuserrequests,businesslogic,andinteraction with the data access layer, ensuring seamless integration withsecuritycomponents.

4.1.2 Entity Framework Core (EF Core)

EntityFrameworkCoreisutilizedastheObject–Relational Mapping (ORM) framework for managing database operations. EF Core simplifies data access by mapping application objects to relational database tables and supportingfeaturessuchaschangetracking,migrations,and LINQ-basedqueries.Inthisimplementation,EFCoreplaysa centralroleinintegratingtheencryptionmechanismswithin thepersistencelayer,allowingsecurehandlingofsensitive datawithoutmodifyingthecorebusinesslogic.

4.1.3 SQL Server / PostgreSQL

Thedatabaselayerisimplementedusingrelationaldatabase management systems such as SQL Server or PostgreSQL. Thesedatabasesprovidereliabledatastorage,transaction management, and scalability required for enterprise applications. In the proposed framework, the database storesencrypteddata,ensuringthatsensitiveinformation remainsprotectedevenintheeventofunauthorizedaccess tothedatabasesystem.

4.2 Encryption Module Implementation

4.2.1

AES-Based Encryption

TheencryptionmoduleisimplementedusingtheAdvanced Encryption Standard (AES), a widely adopted symmetric encryption algorithm known for its strong security and computational efficiency. AES is used to encrypt sensitive datafieldsbeforetheyarepersistedinthedatabase.Itshigh performancemakesitsuitableforenterprisesystemsthat handlelargevolumesofdata,ensuringminimalimpacton system performance while maintaining strong data protection.

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

4.2.2 Key Management Strategy

Asecurekeymanagementstrategyisessentialforensuring the effectiveness of the encryption process. In this framework,cryptographickeysaregeneratedusingsecure algorithms and stored in protected environments such as configuration stores or secure vaults. Key rotation mechanisms are implemented to periodically update encryption keys, reducing the risk of key compromise. Proper key lifecycle management ensures that encryption remains secure and compliant with enterprise security standards.

4.3 Secure Data Flow

4.3.1

Data Input → Encryption → Database Storage

The secure data flow begins when a user submits data throughtheapplicationinterface.Thisdataisprocessedby the application layer and passed to the data access layer managed by EF Core. Before the data is stored in the database, the encryption module automatically encrypts sensitivefieldsusingtheconfiguredencryptionalgorithm. The encrypted data is then persisted in the database, ensuringthatnosensitiveinformationisstoredinplaintext.

4.3.2 Data Retrieval → Decryption → Application

Whendataisretrievedfromthedatabase,EFCorefetches the encrypted records and passes them through the encryptionmodule.Themoduledecryptstherelevantfields before returning the data to the application layer. This ensuresthattheapplicationoperatesonreadabledatawhile maintainingsecurestoragepractices.Theentireprocessis transparent to the user and does not require manual handlingofencryptionordecryptionoperations.

4.4 Prototype Design

4.4.1

Entity Model with Encrypted Fields

Theprototypesystemisdesignedusingentitymodelsthat representdatabasetableswithintheapplication.Sensitive attributeswithinthesemodels,suchaspersonalidentifiers andconfidentialrecords,areconfiguredforencryptionusing EFCoremechanisms.Byintegratingencryptionattheentity level, the framework ensures that security is embedded directly into the data model, providing a consistent and scalableapproachtoprotectingsensitiveinformation.

4.4.2 Secure Repository Pattern

The repository pattern is implemented to manage data accessoperationsinastructuredandsecuremanner.This patternabstractsdatabaseinteractionsandcentralizesdata handling logic, allowing the integration of security mechanismssuchasencryptionandaccesscontrol.Byusing asecurerepositorypattern,thesystemensuresthatalldata operationsadheretopredefinedsecuritypolicies,improving

maintainabilityandreducingtheriskofinconsistentsecurity implementations.

5. EXPERIMENTAL SETUP

5.1 Evaluation Metrics

5.1.1

Execution Time

Executiontimeismeasuredtoevaluatetheoverallsystem performance, particularly the time required to complete databaseoperationssuchasinsertion,retrieval,andupdates. This metric helps determine the impact of encryption on applicationresponsivenessandefficiency.

5.1.2

Query Performance

Query performance analysis focuses on the speed and efficiencyofdatabasequeriesexecutedthroughEFCore.It examineshowencryptionaffectsqueryexecutiontimeand databaseinteraction,ensuringthattheproposedframework maintains acceptable performance levels in enterprise environments.

5.1.3 Encryption Overhead

Encryptionoverheadreferstotheadditionalcomputational cost introduced by encryption and decryption processes. This metric is critical for assessing the feasibility of the proposedapproach,asexcessiveoverheadmaynegatively impactsystemscalabilityandperformance.

5.1.4

Security Strength

Security strength is evaluated based on the framework’s abilitytoprotectsensitivedata fromunauthorizedaccess. This includes assessing data confidentiality, resistance to databreaches,andeffectivenessofencryptionmechanisms insafeguardingstoredinformation.

5.2

Dataset and Test Environment

5.2.1

Enterprise-Like Simulated Dataset

Theexperimentalevaluationisconductedusingasimulated dataset that reflects real-world enterprise scenarios. The datasetincludesvarioustypesofsensitiveandnon-sensitive data, such as user information, transaction records, and operational data.Thisrealistic datasetallowsforaccurate assessment of the framework’s performance and security capabilitiesunderpracticalconditions.

5.3 Comparative Models

5.3.1

EF Core (Without Encryption)

The baseline model consists of a standard EF Core implementationwithoutanyencryptionmechanisms.This model is used to measure the default performance and

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

highlight the security limitations of unprotected data persistence.

5.3.2 EF Core with Static Encryption

The second model incorporates static encryption, where dataisencryptedusingafixedapproachwithoutdynamic adaptation. This model provides a comparison point to evaluatethelimitationsoftraditionalencryptionmethodsin termsofflexibilityandperformance.

5.3.3 Proposed Dynamic Encryption Model

Thefinalmodelrepresentstheproposedframework,which integrates dynamic encryption within the EF Core persistence pipeline. This model is evaluated against the baselineandstaticencryptionapproachestodemonstrate improvementsindatasecurity,flexibility,andoverallsystem performance.

6. RESULTS AND ANALYSIS

6.1 Performance Analysis

6.1.1

Query Latency Comparison

The performance of the proposed secure persistence frameworkisevaluatedbyanalyzingquerylatencyacross differentmodels.Querylatencyreferstothetimetakenby the system to execute database operations such as insert, update,andretrieval.ThebaselineEFCoremodelwithout encryption demonstrates the lowest latency due to the absenceofadditionalprocessingoverhead.Incontrast,the static encryption model introduces moderate latency becauseencryptionanddecryptionoperationsareapplied uniformly to all data. The proposed dynamic encryption model shows slightly higher latency than the baseline but performs better than static encryption due to its selective encryptionstrategy,whichtargetsonlysensitivefields.This optimization ensures that unnecessary encryption operations are avoided, thereby maintaining acceptable systemresponsiveness.

6.1.2 Encryption Overhead Impact

Encryption overhead represents the additional computationalcostintroducedbycryptographicoperations duringdatapersistence.Thestaticencryptionmodelincurs higheroverheadasitencryptsalldatafieldsregardlessof sensitivity.Incomparison,theproposeddynamicencryption modelreducesoverheadbyapplyingencryptionselectively at runtime. Experimental observations indicate that while thereisameasurableincreaseinprocessingtimecompared to the baseline, the overhead remains within acceptable limitsforenterpriseapplications.Thisdemonstratesthatthe proposed approach effectively balances security requirementswithperformanceconstraints.

6.2 Security Evaluation

6.2.1 Data Confidentiality Improvement

Theproposeddynamicencryptionframeworksignificantly enhances data confidentiality by ensuring that sensitive informationisencryptedbeforebeingstoredinthedatabase. Unlike the default EF Core model, where data is stored in plaintext, the encrypted storage mechanism prevents unauthorizedusersfrominterpretingsensitiveinformation evenifdatabaseaccessiscompromised.Theselectivefieldlevelencryptionfurtherensuresthatcriticaldataelements receive stronger protection while maintaining system efficiency.

6.2.2 Resistance to Data Breaches

The framework improves resistance to data breaches by integratingencryptiondirectlywithinthepersistencelayer. Intheeventofunauthorizeddatabaseaccess,attackersare unable to retrieve meaningful information due to the encrypted format of stored data. Additionally, the use of secure key management practices enhances protection againstkeycompromise.Comparedtostaticencryption,the dynamicencryptionmodelprovidesimprovedresilienceby adaptingencryptionstrategiesbasedondatasensitivityand operational context,thereby strengthening overall system security.

Table-1: Model Comparison

6.3.2 Interpretation of Comparative Results

The comparative analysis highlights the strengths and limitationsofeachmodel.ThedefaultEFCoremodeloffers high performance but lacks adequate security, making it unsuitableforhandlingsensitiveenterprisedata.Thestatic encryptionmodelimprovessecuritybutintroduceshigher computationaloverheadandlacksflexibilityduetoitsrigid encryption approach. The proposed dynamic encryption modelachievesthebestbalancebyprovidinghighsecurity, improvedflexibility,andacceptableperformance.Itsability toselectivelyencryptsensitivefieldsmakesitmoreefficient andadaptabletoreal-worldenterpriserequirements.

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

6.4 Discussion

6.4.1

Trade-off Between Security and Performance

The results clearly demonstrate the inherent trade-off between data security and system performance. While encryption enhances data protection, it introduces additionalcomputationaloverheadthatcanimpactsystem efficiency. The proposed dynamic encryption model addresses this challenge by optimizing encryption operationsthroughselectiveapplication,therebyreducing unnecessaryprocessing.Thisapproachensuresthatsecurity enhancements do not significantly degrade performance, makingitapracticalsolutionforenterpriseenvironments.

6.4.2 Practical Feasibility in Enterprise Systems

From an implementation perspective, the proposed framework is highly feasible for real-world enterprise applications.ItintegratesseamlesslywithexistingEFCore workflowsanddoesnotrequiremajorarchitecturalchanges. Theuseofbuilt-inEFCorefeaturessuchasvalueconverters and interceptors simplifies adoption, while the modular designensuresscalabilityandmaintainability.Overall,the results indicate that the proposed secure persistence strategycanbeeffectivelydeployedinenterprisesystemsto enhance data security without compromising operational efficiency.

7. CONCLUSION

Thisresearchpresentsasecuredatapersistencestrategyfor enterprise .NET applications by integrating dynamic encryptionwithintheEntityFrameworkCore(EFCore)data accesspipeline.Thestudyaddressesacriticallimitationof modern ORM frameworks, which primarily focus on simplifying database operations but lack built-in mechanismsforprotectingsensitivedataattheapplication level. By introducing a dynamic encryption model, the proposedframeworkensuresthatsensitivedatafieldsare automatically encrypted before storage and decrypted during retrieval, thereby enhancing data confidentiality withoutdisruptingapplicationfunctionality.

TheimplementationoftheframeworkusingASP.NETCore and EF Core demonstrates its practical feasibility in realworld enterprise environments. Experimental evaluation highlightsthattheproposedapproachsignificantlyimproves data security compared to default EF Core and static encryption models. Although encryption introduces additionalcomputationaloverhead,theselectivefield-level encryption strategy effectively minimizes performance degradation, maintaining acceptable system efficiency. Furthermore, the integration of encryption mechanisms using EF Core features such as value converters and interceptorsensuresseamlessadoptionwithoutrequiring majorarchitecturalmodifications.

Overall, the research successfully establishes a balanced approach to secure data persistence by addressing both security and performance considerations. The findings contribute to the advancement of secure software engineeringpracticesandprovideapracticalframeworkfor protectingsensitiveenterprisedatainmodern.NET-based applications.

8. FUTURE SCOPE

Future research can extend the proposed framework by incorporatingadvancedandadaptiveencryptiontechniques, suchasAI-drivenorcontext-awareencryptionmechanisms that dynamically adjust security levels based on data sensitivityandusagepatterns.Integrationwithcloud-based key management services, such as secure key vaults, can further enhance scalability and security in distributed environments.Additionally,exploringtheapplicabilityofthe proposedapproachinNoSQLdatabasesandmicroservices architectures would broaden its usability across diverse enterprisesystems.Performanceoptimizationtechniques, including hardware acceleration and parallel encryption methods, can be investigated to further reduce computationaloverhead.Finally,incorporatingblockchainbased data integrity verification and zero-trust security models could strengthen the overall robustness and trustworthiness of secure data persistence frameworks in futureenterpriseapplications.

REFERENCES

1. Ambler,S.W.,2012.Agiledatabasetechniques:effective strategiesfortheagilesoftware developer. Hoboken: JohnWiley&Sons.

2. Bauer, C. and King, G., 2016. Java persistence with Hibernate. 2nd ed. Shelter Island: Manning Publications.

3. Connolly, T. and Begg, C., 2015. Database systems: a practical approach to design, implementation, and management.6thed.Harlow:Pearson.

4. Elmasri, R. and Navathe, S.B., 2016. Fundamentals of databasesystems.7thed.Boston:Pearson.

5. Evans, E., 2003. Domain-driven design: tackling complexityintheheartofsoftware.Boston:AddisonWesley.

6. Ferguson, N., Schneier, B. and Kohno, T., 2010. Cryptography engineering: design principles and practicalapplications.Indianapolis:WileyPublishing.

7. Fowler, M., 2018. Patterns of enterprise application architecture.Boston:Addison-Wesley.

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

8. Green,M.andSmith,M.,2016.Thecryptopalscrypto challenges. Available at: https://cryptopals.com (Accessed:2026).

9. Hoffman, C., 2019. Entity Framework Core in action. ShelterIsland:ManningPublications.

10. Katz, J. and Lindell, Y., 2020. Introduction to modern cryptography.3rded.BocaRaton:CRCPress.

11. Lerman,J.,2020.EntityFrameworkCoreinaction.2nd ed.ShelterIsland:ManningPublications.

12. Lock,A.,2021.ASP.NETCoreinaction.2nded.Shelter Island:ManningPublications.

13. Microsoft, 2023. Entity Framework Core documentation. Available at: https://learn.microsoft.com/en-us/ef/core/(Accessed: 2026).

14. Menezes, A.J., van Oorschot, P.C. and Vanstone, S.A., 2018.Handbookofappliedcryptography.BocaRaton: CRCPress.

15. Newman, S., 2015. Building microservices: designing fine-grainedsystems.Sebastopol:O’ReillyMedia.

16. Paar, C. and Pelzl, J., 2010. Understanding cryptography: a textbook for students and practitioners.Berlin:Springer.

17. Price,M.,2018.C#7and.NETCore2.0moderncrossplatformdevelopment.Birmingham:PacktPublishing.

18. Sandhu, R. and Samarati, P., 1994. ‘Access control: principle and practice’, IEEE Communications Magazine,32(9),pp.40–48.

19. Silberschatz, A., Korth, H.F. and Sudarshan, S., 2019. Databasesystemconcepts.7thed.NewYork:McGrawHill.

20. Stallings,W.,2017.Cryptographyandnetworksecurity: principlesandpractice.7thed.Boston:Pearson.

21. Whitman, M.E. and Mattord, H.J., 2018. Principles of informationsecurity.6thed.Boston:CengageLearning.

22. Kıyak, C.B., Bilge, H.Ş. and Yılmaz, F., 2025. ‘A hybrid securityframeworkwithenergy-awareencryptionfor protecting embedded systems against code theft’, Electronics,14(22),p.4395.

23. Olaymi,S.E.Z.,2025.‘Performanceandsecurityanalysis of fully homomorphic encryption in cloud-based healthcare blockchain’, Journal of Information Technology,pp.1–18.

24. Valera-Rodriguez,F.-J.,Manzanares-Lopez,P.andCano, M.-D., 2024. ‘Empirical study of fully homomorphic encryption using Microsoft SEAL’, Applied Sciences, 14(10),p.4047.

25. Zhang, Y., Liu, J. and Chen, X., 2024. ‘Integrating fully homomorphic encryption to enhance the security of blockchainapplications’,FutureGenerationComputer Systems,161,pp.467–477.

26. Alzahrani,A.andAlghamdi,A.,2024.‘Securecipher:an instantaneous synchronization stream encryption system for insider threat data leakage protection’, ExpertSystemswithApplications,124470.

27. Ramachandran, M., 2023. ‘S3EF-HBCAs: Secure and sustainable software engineering framework for healthcare blockchain applications’, Blockchain in HealthcareToday,6.

28. Zhou, L., Wang, H. and Li, Y., 2022. ‘Encrypted data processingwithhomomorphicre-encryptionincloud computing’,InformationSciences,585,pp.415–430.

29. Zhu,M.andSingh,R.,2024.‘DynamicAESencryption and blockchain-based key management for secure clouddatastorage’,IEEEAccess.

30. Amorim, I. and Costa, I., 2023. ‘Homomorphic encryption:ananalysisofitsapplicationsinsearchable encryption’,arXivpreprintarXiv:2306.14407.

31. Garrison, W.C., Shull, A., Myers, S. and Lee, A.J., 2016. ‘On the practicality of cryptographically enforcing dynamic access control policies in the cloud’, arXiv preprintarXiv:1602.09069.

32. Mascia, C., Sala, M. and Villa, I., 2021. ‘A survey on functional encryption’, arXiv preprint arXiv:2106.06306.

33. Wang,Z.,Fok,K.-W.andThing,V.L.L.,2022.‘Machine learning for encrypted malicious traffic detection: approaches, datasets and comparative study’, arXiv preprintarXiv:2203.09332.

34. Popa, R.A., Redfield, C.M., Zeldovich, N. and Balakrishnan, H., 2011. ‘CryptDB: protecting confidentiality with encrypted query processing’, Proceedings of the ACM Symposium on Operating SystemsPrinciples,pp.85–100.

35. Microsoft, 2022. ‘Data protection and encryption in ASP.NETCore’,MicrosoftDocumentation.Availableat: https://learn.microsoft.com(Accessed:2026).

36. Oracle, 2021. ‘Transparent Data Encryption (TDE) concepts and best practices’, Oracle Documentation. Availableat:https://docs.oracle.com(Accessed:2026).

Turn static files into dynamic content formats.

Create a flipbook