<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Archiving and Interchange DTD v1.0 20120330//EN" "JATS-archivearticle1.dtd">
<article xmlns:xlink="http://www.w3.org/1999/xlink">
  <front>
    <journal-meta>
      <journal-title-group>
        <journal-title>Workshop on Cybersecurity Providing in Information and Telecommunication Systems, October</journal-title>
      </journal-title-group>
    </journal-meta>
    <article-meta>
      <title-group>
        <article-title>Security methods in .NET technology⋆</article-title>
      </title-group>
      <contrib-group>
        <contrib contrib-type="author">
          <string-name>Serhii Buchyk</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Serhii Toliupa</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Oleksandr Buchyk</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <contrib contrib-type="author">
          <string-name>Anastasiia Shabanova</string-name>
          <xref ref-type="aff" rid="aff0">0</xref>
        </contrib>
        <aff id="aff0">
          <label>0</label>
          <institution>Taras Shevchenko National University of Kyiv</institution>
          ,
          <addr-line>60 Volodymyrska str., 01033 Kyiv</addr-line>
          ,
          <country country="UA">Ukraine</country>
        </aff>
      </contrib-group>
      <pub-date>
        <year>2025</year>
      </pub-date>
      <volume>26</volume>
      <issue>2025</issue>
      <fpage>0000</fpage>
      <lpage>0003</lpage>
      <abstract>
        <p>This article is devoted to the analysis of security methods in .NET technology, which are key to ensuring the reliability and security of software. The article discusses in detail such security methods as authentication and authorisation, encryption, access control, protection against Cross-Site Scripting (XSS) attacks and protection against Cross-Site Request Forgery (CSRF) attacks. The article analyses the advantages and disadvantages of each method, emphasising their importance in forming a comprehensive security system for .NET applications. The results of the study confirm that the implementation and use of various security methods is necessary to ensure the highest level of data and resource protection on the .NET platform. This article will be useful for developers and administrators seeking to improve the security of their .NET applications, ensuring their resilience to modern cyber threats.</p>
      </abstract>
      <kwd-group>
        <kwd>eol&gt;</kwd>
        <kwd>NET technology</kwd>
        <kwd>authentication</kwd>
        <kwd>authorisation</kwd>
        <kwd>encryption</kwd>
        <kwd>hashing</kwd>
        <kwd>XSS</kwd>
        <kwd>CSRF 1</kwd>
      </kwd-group>
    </article-meta>
  </front>
  <body>
    <sec id="sec-1">
      <title>1. Introduction</title>
    </sec>
    <sec id="sec-2">
      <title>2. Task formulation</title>
      <p>
        The purpose of the study is to analyse security methods in .NET technology. The object of research
is the process of analysing security methods in .NET technology. The subject of the study is
security methods in .NET technology. Therefore, the task is to study and compare the security
methods in the .NET technology.
3. Solving the task
.NET is a software development platform developed by Microsoft Corporation that allows
developers to create a variety of applications for different devices and operating systems, as well as
mobile devices, personal computers and cloud services [
        <xref ref-type="bibr" rid="ref1 ref2 ref3 ref4 ref5 ref6 ref7">1–7</xref>
        ]. The platform includes programming
languages, runtime environments, and library classes that help developers ensure the functionality
of their applications. One of the key components of the .NET technology is the C# programming
language, which is one of the most popular programming languages in the world. In addition to C#,
the platform supports other programming languages such as F#, Visual Basic, C++/CLI and
PowerShell, as well as non-Microsoft languages (e.g. Cobol, Java, PHP, Python, Scheme). There is
also support for other programming languages (approximately 25 languages) [
        <xref ref-type="bibr" rid="ref8 ref9">8, 9</xref>
        ].
      </p>
      <p>
        The runtime, libraries, and languages are the pillars of the .NET stack. Higher-level components
such as .NET tools and application stacks such as ASP.NET Core are built on top of these pillars.
These pillars have a symbiotic relationship because they were designed and built together by the
same group. In essence, the .NET platform has a different way of packaging and installing. Instead
of being built into the operating system, .NET is compiled from NuGet packages and can be
compiled directly into an application or placed in a folder within the application. This means that
applications can include .NET and co-exist fully on a computer. NuGet is a package management
tool for .NET that has a significant number of packages (hundreds of thousands of packages) that
implement a variety of functionality for many scenarios. Most applications rely on NuGet packages
for some functionality [
        <xref ref-type="bibr" rid="ref9">9</xref>
        ].
      </p>
      <p>
        Security practices in .NET technology play an important role in ensuring the security and
protection of software developed on this platform. The methods considered include different
approaches to authentication, authorisation, encryption and access control, as well as protection
against different types of attacks, such as XSS and CSRF [
        <xref ref-type="bibr" rid="ref10">10</xref>
        ]. A generalised system of security
methods in .NET technology is shown in Figure 1.
      </p>
      <p>
        In .NET, authentication and authorisation are achieved through a combination of middleware
components, attributes and configuration settings. The framework provides a flexible and
extensible infrastructure for implementing these security mechanisms, allowing developers to
choose from a variety of authentication schemes and authorisation policies to meet the
requirements of their applications [
        <xref ref-type="bibr" rid="ref11">11</xref>
        ].
      </p>
      <p>
        Windows Authentication is an authentication method that uses existing user accounts in the
Windows operating system to authenticate to .NET Web applications. This method is convenient
for users because they do not have to enter a separate username and password, as the system uses
the same credentials they use to log in to the operating system. Windows-based authentication is
performed between the Windows server and the client machine, specifically using Active Directory
domain identifiers or Windows accounts for identification1[
        <xref ref-type="bibr" rid="ref2">2</xref>
        ].
      </p>
      <p>
        Forms authentication uses HTML forms to collect usernames and passwords from users. The
data entered is then checked against your application’s user database [
        <xref ref-type="bibr" rid="ref13">13</xref>
        ]. If the authentication
process is successful, the system stores the authentication token in a cookie or in the URL so that
the authenticated user does not have to re-enter the credentials for subsequent requests. When a
user accesses an ASP.NET page through a browser, ASP.NET checks for the presence of a form
authentication token. If the result is positive, the runtime redirects the user to the login page and
begins the process of verifying the user ID and password [
        <xref ref-type="bibr" rid="ref14">14</xref>
        ].
Claims-based authentication is a method that uses tokens to authenticate users. The token contains
a set of claims about the user, such as username, role, etc. This token is issued by the
authentication server after a successful login. This data is sent as a stream of bytes during
transmission over the network, and the claims are digitally signed for verification at the receiving
end. In the claims-based authentication process, a request to verify a user’s identity is sent from a
Dynamics 365 customer experience or custom application to a Security Token Service (STS) server.
The STS server determines whether the user requires authentication and, if so, issues a signed and
encrypted Security Assertion Markup Language (SAML) token containing the user’s authentication
credentials. The token has a limited validity period and may need to be updated periodically,
depending on the length of time it is used by the application [
        <xref ref-type="bibr" rid="ref15">15</xref>
        ].
      </p>
      <p>
        OAuth 2.0 is a standard authentication protocol that allows web applications to access resources
belonging to other users without having to reveal their passwords. This makes OAuth 2.0 a secure
and convenient solution for authorising users in web applications. It is designed to provide
controlled access to protected resources. OAuth 2.0 issues access tokens to third-party applications
after obtaining the user’s consent. These tokens provide limited access to the user’s resources
hosted on the resource server. The protocol defines different roles, such as client, resource owner,
resource server and authorisation server, and different types of provisioning, such as authorisation
code, implicit, client credentials and resource owner credentials, designed for different types of
clients and scenarios. OpenID Connect (OIDC) is an authentication layer extension to the OAuth
2.0 protocol. While OAuth 2.0 focuses on authorisation, OIDC extends its functionality by adding
an authentication component. One of the key aspects of OIDC is the concept of an ID token, which
is not included in the OAuth 2.0 standard. This token contains information about the user’s identity
and is used in conjunction with an OAuth access token. The OIDC standardises the process of user
identity verification and the mechanisms by which clients can request and receive data about
authenticated sessions and end users [
        <xref ref-type="bibr" rid="ref16">16</xref>
        ].
      </p>
      <p>
        Role-based authorisation is a method that uses roles to define user access rights to resources.
Users are assigned roles, and each resource is assigned a set of permissions available to each role.
Role-based security can also be used when an application requires multiple approvals to perform
an action. This might be the case in a procurement system where any employee can create a
purchase request, but only a purchasing agent can turn that request into a purchase order that can
be sent to the supplier [
        <xref ref-type="bibr" rid="ref17">17</xref>
        ].
      </p>
      <p>
        Encryption is an important aspect of web application security, protecting sensitive data from
unauthorised access [
        <xref ref-type="bibr" rid="ref18 ref19 ref20 ref21">18–21</xref>
        ]. NET provides several symmetric and asymmetric encryption
algorithms as well as hashing methods to protect data [
        <xref ref-type="bibr" rid="ref22">22</xref>
        ].
      </p>
      <p>
        Symmetric encryption uses the same secret key to encrypt and decrypt data. It offers speed and
efficiency, making it ideal for encrypting large amounts of data. In the symmetric cryptography
mechanism, managed classes use a special stream called a CryptoStream. This stream encrypts the
data entered into it. When the CryptoStream class is initialised, a managed stream is used that
implements the ICryptoTransform interface, which corresponds to the cryptographic algorithm,
and the CryptoStreamMode, which determines the type of access to the CryptoStream [
        <xref ref-type="bibr" rid="ref10 ref11">10, 11</xref>
        ].
      </p>
      <p>
        Asymmetric encryption uses a pair of keys: a public key, which can be distributed publicly, and
a private key, which is kept secret. The public key is used for encryption and the private key is
used for decryption. To achieve this goal, .NET provides the RSA class. The RSA class is used to
implement the asymmetric RSA algorithm. The security of the RSA cryptographic method is based
on a computational problem, namely the decomposition of large integers into their prime factors
[
        <xref ref-type="bibr" rid="ref23">23</xref>
        ].
      </p>
      <p>
        Hashing converts data into a fixed size (hash) using a one-way function. It is impossible to
recover the original data from the hash, making it useful for data integrity and authentication [
        <xref ref-type="bibr" rid="ref24 ref25">24,
25</xref>
        ]. When using ASP.NET Core Identity, the user provides his or her ID (user name) and password,
along with other required data, when registering with the application. The application then
generates a hash of the password and stores it in the database along with information about the
user [
        <xref ref-type="bibr" rid="ref26">26</xref>
        ].
      </p>
      <p>
        Access control is an important part of any web application’s security system. It ensures that
only authorised users have access to certain functions and data. NET provides several access
control mechanisms that allow developers to flexibly configure the security of their applications
[
        <xref ref-type="bibr" rid="ref27">27</xref>
        ].
      </p>
      <p>
        ASP.NET Membership provides a basic user management and authentication system for Web
applications. It allows you to create user accounts, store user information, authenticate users, and
manage their permissions. ASP.NET Membership includes features such as registering new users,
authenticating registered users with a username and password, recovering passwords, and
managing roles and access permissions. This allows developers to quickly and efficiently
implement an authentication and authorisation system in their Web applications, providing a high
level of security and access control [
        <xref ref-type="bibr" rid="ref28">28</xref>
        ].
      </p>
      <p>
        RBAC (Role-Based Access Control) is a widely used access control model that uses roles and
permissions to determine who has access to what resources. Employees only have access to the
information they need to do their jobs effectively. Access can be based on a number of factors, such
as authority, responsibility and professional competence. In addition, access to computer resources
can be limited to specific tasks, such as the ability to view, create or modify a file1[
        <xref ref-type="bibr" rid="ref3">3</xref>
        ].
      </p>
      <p>
        Token-based authentication uses tokens to authenticate users. A token is a cryptographically
signed packet of data that contains information about the user and their privileges. A user receives
a token after successful authentication and uses it to access a web application. In the context of
access control, servers use authentication tokens to verify the identity of a user, API, computer, or
other server. Tokens can be physical (such as a USB key) or digital (a computer message or digital
signature) [
        <xref ref-type="bibr" rid="ref29">29</xref>
        ].
      </p>
      <p>
        WebSocket is a network communication protocol that allows .NET Web applications to
establish two-way connections with a server. The WebSocket protocol in ASP.NET Core provides a
two-way, persistent communication channel over TCP. This connection can be used to send and
receive data in real time, making it ideal for chat rooms, online games, and other dynamic Web
applications. Using WebSockets over HTTP/2 takes advantage of innovative features such as
header compression; multiplexing, which effectively reduces the time and resources required to
send multiple requests to the server [
        <xref ref-type="bibr" rid="ref30">30</xref>
        ].
      </p>
      <p>
        XSS attacks are a dangerous type of web attack that allows attackers to inject malicious
JavaScript code into web pages that users view. This code can be used to steal confidential
information, redirect users to phishing sites, or perform other malicious actions. In an XSS attack,
an attacker uses a web application to send malicious code, usually in the form of a script, on the
client side to another user who is unaware of it. The end user’s browser may execute the malicious
scripts, believing them to be safe, which can result in the malicious scripts gaining access to session
tokens, cookies and other sensitive information stored by the browser and used on the website in
question. These malicious scripts can change the content of HTML pages. The malicious content
that is delivered to the browser usually consists of JavaScript segments, but can also include HTML,
Flash, or any other type of code designed to perform malicious actions. Vulnerabilities that allow
these attacks to occur are common and can occur anywhere a web application uses user input
without encrypting or validating it. NET provides several methods to protect against XSS attacks
that help developers build secure web applications [
        <xref ref-type="bibr" rid="ref31">31</xref>
        ].
      </p>
      <p>
        The first step in countering XSS attacks is to validate all user input before it is displayed on a
web page. This can be done in a number of ways, including input validation and output encryption.
Input validation involves checking user input for malicious code. If malicious code is detected, the
data is rejected and the user is notified of the error. Input validation involves analysing the data for
compliance with certain criteria. For example, if the user is asked to enter an email address, the
check will include checking for the presence of the “@” symbol and the presence of a domain
name. If the input data is incompatible with these criteria, it will be rejected. Output encoding is
the transformation of user input so that it is not interpreted as HTML or JavaScript code. This can
be achieved using a variety of techniques, such as HTML escaping and JavaScript encoding [
        <xref ref-type="bibr" rid="ref32">32</xref>
        ].
      </p>
      <p>
        There are many .NET libraries (e.g. the XSS Prevention Library) that are specifically designed to
protect against XSS attacks. These libraries provide out-of-the-box functions for output scraping,
input validation, and other XSS security-related tasks. Anti-XSS Library is a library that provides a
wide range of functions for output scanning, input validation, HTML and URL sanitisation, and
detection and prevention of XSS attacks. OWASP Encoder is a library developed by the Open Web
Application Security Project (OWASP) that provides functions for encoding output in various
formats, including HTML, JavaScript, CSS, and XML. Microsoft Anti-XSS is a library from
Microsoft that provides functions for escaping output in HTML, JavaScript, and other formats, and
for preventing XSS attacks based on rendered data. These libraries help developers ensure the
security of their applications by automating the process of protecting against potential attacks on
web applications [
        <xref ref-type="bibr" rid="ref31">31</xref>
        ].
      </p>
      <p>
        HttpOnly cookies are a type of cookie that is sent and received via the HTTP protocol. They are
separate from other types of cookies and cannot be read or modified using the browser’s
document.cookie API. This feature increases your level of security by reducing your vulnerability
to attacks aimed at manipulating cookies through malicious scripts. For example, if an attacker
tries to use XSS to access document.cookie values and send them to a malicious server, the attempt
will fail because HTTP-only cookies cannot be accessed through document.cookie. Furthermore,
attempts to modify or delete HTTP-only cookies will also fail because the browser will ignore such
changes [
        <xref ref-type="bibr" rid="ref32">32</xref>
        ].
      </p>
      <p>
        Using a Content Security Policy (CSP) helps prevent malicious JavaScript code from being
loaded from untrusted sources that can be used for XSS attacks. A CSP is an HTTP header that
allows .NET web applications to specify which sources (domains, URLs) can load resources (scripts,
styles, images, and so on) on a page. After defining a content security policy, web application
developers can restrict the types of content that can be loaded and executed on a page. This helps
prevent the execution of malicious scripts injected by attackers. The CSP provides several
directives, such as “default-src”, “script-src”, “style-src”, “img-src”, “frame-src” and “connect-src”,
which allow you to configure these restrictions specifically for different types of content3[
        <xref ref-type="bibr" rid="ref3">3</xref>
        ].
CSRF is a dangerous type of web attack that allows attackers to force users to perform unwanted
actions on a website they are authorised to visit. CSRF attacks target functions that change the
state of the server, such as changing personal information or making payments. Since the attacker
does not need to receive a response to the request, but the victim does, the attacks aim to change
the state. An attacker can use CSRF to obtain the victim’s personal information by forcing them to
enter it into a web application through a special request. Using social engineering, such as sending
special links via email or chat, the attacker forces users to perform unwanted actions. If the victim
is a regular user, a successful CSRF attack can trick them into performing state change requests,
such as transferring funds or changing contact information. If the target is an administrator
account, CSRF can lead to the compromise of the entire web application. NET provides several
methods of protection against CSRF attacks to help developers create secure web applications. An
anti-CSRF token is a method where a unique CSRF token is generated for each user and attached to
all forms and requests. The token is verified on the server to ensure that the request is being sent
by an authorised user. Anti-CSRF tokens are randomly generated unique values embedded in
HTML forms or web application URLs. These tokens are associated with a user’s session and are
used to authenticate subsequent requests sent on that user’s behalf. The main purpose of anti-CSRF
tokens is to ensure that all requests coming from the browser are legitimate and have not been
tampered with by attackers. There are several HTTP headers that can be used to protect against
CSRF attacks, such as X-CSRF-Token and X-Forwarded-For. These headers provide additional
information about the request that can be used to verify it. The X-CSRF-Token header is used to
send a CSRF token from the client to the server. The server must verify this token to ensure that
the request is coming from a legitimate user. The X-Forwarded-For header is used to track the
user’s IP address when a request is forwarded through a proxy server. This can be useful in
preventing CSRF attacks, which rely on spoofing the referrer. There is also the Origin header,
which contains the URL of the origin of the request. The server can use this information to verify
that the request is coming from the expected source. Using these headers can increase the security
of web applications and prevent CSRF attacks. Reduces the risk of CSRF attacks using SameSite
cookies [
        <xref ref-type="bibr" rid="ref34">34</xref>
        ]. SameSite is a cookie attribute that tells the browser when to send cookies along with
requests to third-party websites. It helps prevent cookies containing authentication tokens or other
sensitive data from being sent when you follow links from other websites. Possible values for this
attribute are Lax, Strict, or None. For example, if a website like GitHub uses the Strict value, and a
user tries to follow a link to a private GitHub project posted on a company forum or in an email,
the user will not be able to access the project because GitHub will not receive a session cookie [
        <xref ref-type="bibr" rid="ref35">35</xref>
        ].
      </p>
      <sec id="sec-2-1">
        <title>1. Authentication and authorisation</title>
        <sec id="sec-2-1-1">
          <title>Easy to implement and configure; high level of security due to integration with Windows; no need to store passwords on the client side</title>
        </sec>
        <sec id="sec-2-1-2">
          <title>Easy to implement; flexible as login and error pages can be customised; does not require Active Directory</title>
        </sec>
        <sec id="sec-2-1-3">
          <title>Limited configuration and control</title>
          <p>of authentication, not suitable for
independent web systems</p>
          <p>Vulnerable to brute-force and
phishing attacks unless additional
security measures are taken; risk of
password leakage; requires
additional configuration</p>
        </sec>
        <sec id="sec-2-1-4">
          <title>OpenID Connect (OIDC)</title>
        </sec>
        <sec id="sec-2-1-5">
          <title>Role-Based Authorization</title>
        </sec>
        <sec id="sec-2-1-6">
          <title>Symmetric encryption</title>
        </sec>
        <sec id="sec-2-1-7">
          <title>Asymmetric encryption</title>
        </sec>
        <sec id="sec-2-1-8">
          <title>Hashing</title>
          <p>ASP.NET
Membership</p>
        </sec>
        <sec id="sec-2-1-9">
          <title>Role-Based Access Control</title>
        </sec>
        <sec id="sec-2-1-10">
          <title>Token-Based</title>
          <p>Authentication</p>
          <p>Allows you to include additional user
attributes in the authentication token,
which allows for more flexible access
control; the ability to implement a
single sign-on between applications</p>
        </sec>
        <sec id="sec-2-1-11">
          <title>OIDC provides web applications with</title>
          <p>more user information, such as name,
email address, and profile picture;</p>
          <p>OIDC simplifies OAuth 2.0
implementation; OIDC uses JWT to
protect user information</p>
        </sec>
        <sec id="sec-2-1-12">
          <title>Requires additional development to integrate and manage user applications; may be difficult for users to understand tokens</title>
        </sec>
        <sec id="sec-2-1-13">
          <title>Complexity of implementation; dependence on third-party services; vulnerability to certain attacks</title>
        </sec>
        <sec id="sec-2-1-14">
          <title>OIDC requires OAuth 2.0 implementation, not all IdPs support OIDC OAuth 2.0</title>
          <p>Safe and reliable; user-friendly; suitable
for distributed systems</p>
        </sec>
        <sec id="sec-2-1-15">
          <title>Easy to manage access to resources; reduces the burden on administrators; suitable for large systems</title>
        </sec>
        <sec id="sec-2-1-16">
          <title>Requires additional configuration; may be difficult to implement; not suitable for simple websites</title>
        </sec>
      </sec>
      <sec id="sec-2-2">
        <title>2. Encryption</title>
        <sec id="sec-2-2-1">
          <title>Fast and efficient data encryption and decryption process</title>
        </sec>
        <sec id="sec-2-2-2">
          <title>Requires secure transmission and</title>
          <p>storage of a shared key for
encryption and decryption
Higher security because a pair of keys Data exchange speed is reduced
is used, one of which remains private compared to symmetric encryption</p>
        </sec>
        <sec id="sec-2-2-3">
          <title>Irreversible process that guarantees safe data recovery</title>
        </sec>
      </sec>
      <sec id="sec-2-3">
        <title>3. Access control</title>
        <p>Flexibility (allows you to set up
different access levels for different
users); scalability; integration with
other .NET components</p>
        <sec id="sec-2-3-1">
          <title>Vulnerable to brute-force attacks as there is no way to decrypt the hashed result</title>
        </sec>
        <sec id="sec-2-3-2">
          <title>Can be difficult to implement on large projects, and a database needs to be managed</title>
        </sec>
        <sec id="sec-2-3-3">
          <title>Easy to add, remove, and change roles</title>
          <p>and permissions; suitable for large
systems with many users and
resources; to create complex access
rules based on various factors</p>
        </sec>
        <sec id="sec-2-3-4">
          <title>Requires additional configuration</title>
          <p>and setup; complex access rules can
be difficult to understand and
manage; may be overkill for small
systems</p>
          <p>Can be used with different
authentication providers and protocols;
suitable for large systems; tokens are
digitally signed, which guarantees their
reliability; authentication and
authorisation are handled separately,
making the system more flexible
Requires additional configuration
and setup; users may need to
understand how tokens work; not
all websites and authentication
providers support token-based
authentication</p>
          <p>Secure
WebSocket
protocol</p>
        </sec>
        <sec id="sec-2-3-5">
          <title>Output encoding</title>
        </sec>
        <sec id="sec-2-3-6">
          <title>Using XSS protection libraries</title>
        </sec>
        <sec id="sec-2-3-7">
          <title>HttpOnly</title>
          <p>cookies</p>
          <p>WebSocket provides low latency; uses
fewer resources than traditional HTTP
requests, making it more efficient for
streaming data efficient for streaming
data</p>
        </sec>
        <sec id="sec-2-3-8">
          <title>Complexity of implementation:</title>
          <p>WebSocket requires more
development knowledge;
WebSocket is not compatible with
many browsers and servers
WebSocket is not compatible with
many browsers and servers</p>
        </sec>
      </sec>
      <sec id="sec-2-4">
        <title>4. Protection against XSS attacks</title>
        <p>14 Input Validation
Effective against XSS attacks; easy to
implement; can be used to protect
different types of data</p>
        <sec id="sec-2-4-1">
          <title>Can be difficult to identify all potentially dangerous symbols and designs</title>
        </sec>
        <sec id="sec-2-4-2">
          <title>Effective against XSS attacks; easy to implement; can be used to protect different types of data</title>
        </sec>
        <sec id="sec-2-4-3">
          <title>Reduces the risk of XSS vulnerabilities; saves developers time and effort</title>
        </sec>
        <sec id="sec-2-4-4">
          <title>Can make the output unreadable; can lead to formatting issues</title>
        </sec>
        <sec id="sec-2-4-5">
          <title>Can make the code more complex; a suitable library must be selected and integrated</title>
        </sec>
        <sec id="sec-2-4-6">
          <title>Some older browsers do not</title>
          <p>Using the HttpOnly attribute for support HttpOnly cookies; does not
cookies in the browser, which prevents protect against other types of XSS
JavaScript from accessing these attacks; may make it difficult to
cookies; easy to implement access cookies using JavaScript on
the client side</p>
        </sec>
        <sec id="sec-2-4-7">
          <title>A powerful method of protecting</title>
          <p>Content- against XSS attacks; can protect against
Security-Policy other types of attacks; provides flexible
(CSP) control over what resources are
allowed to be uploaded to a web page</p>
        </sec>
        <sec id="sec-2-4-8">
          <title>Difficult to implement: needs to be carefully configured to avoid breaking the page; not all browsers support CSP</title>
          <p>
            Analysis of the different authentication methods has shown that each has its own benefits and
limitations. For example, Windows Authentication allows users to be identified using their
Windows account, while Forms Authentication provides more flexibility but requires additional
security attention. Therefore, it has been found that using a combination of different security
methods is the key to ensuring a high level of security for .NET web applications. For example, to
protect against XSS attacks, it is recommended that you use input validation, output encoding,
HttpOnly cookies, and other measures described in this section. In addition, it is important to
continually update and improve security practices based on the latest trends in the field.
To improve security in .NET, it is recommended that you use a comprehensive approach that
combines various security methods, such as authentication, authorisation, encryption, access
control, and intrusion prevention. It is also important to regularly update the software and
components used in the application to fix identified vulnerabilities 3[
            <xref ref-type="bibr" rid="ref37 ref6">6, 37</xref>
            ]. Monitoring and
auditing systems should be used to detect and analyse abnormal user activity and potential security
threats. It is also necessary to set criteria for password complexity and use two-factor
authentication for additional security [
            <xref ref-type="bibr" rid="ref10">10</xref>
            ].
          </p>
          <p>Thus, the integration of these protective measures enables the formation of a unified security
concept. A comprehensive model for implementing security methods that ensures the creation of a
secure web application using .NET technology can therefore be represented as a generalised
security function S, which depends on a set of implemented security mechanisms.</p>
          <p>S = f ( M 1 , M 2 , ... , M n)
where M i is the ith security method (for example, M 1 is Windows Authentication, M 2 is Forms
Authentication, …, M 18 is Content-Security-Policy).</p>
          <p>Each security method M i is characterised by an individual efficiency E ( M i), which is
determined in the range from 0 to 1, where the value 1 corresponds to the maximum possible level
of protection.</p>
          <p>The effectiveness indicator E ( M i) should be considered as a functional dependence on a set of
parameters, among which the key ones are the complexity of implementation and the coverage of
vulnerabilities. The complexity of implementation reflects the time, labour and resource costs
required to implement the relevant security mechanism, while vulnerability coverage characterises
the proportion of potential threats neutralised by this method.</p>
          <p>The generalised security level of system S is defined as the weighted sum of the effectiveness of
all implemented methods, with the weighting coefficient wᵢ reflecting the relative importance of
each method in ensuring a comprehensive protection strategy.</p>
          <p>ni
S = ∑ wi× E ( M i).</p>
          <p>i= 1</p>
          <p>The application of this approach provides the opportunity to quantitatively assess the level of
security of an information system, which, in turn, contributes to increasing the objectivity of the
analysis of its security. In addition, this model makes it possible to identify weaknesses through a
comparative analysis of methods with low E ( M i) values, as well as to plan investments in the
implementation of individual security mechanisms in a reasonable manner, demonstrating their
impact on the overall S indicator.</p>
        </sec>
      </sec>
    </sec>
    <sec id="sec-3">
      <title>4. Conclusions</title>
      <p>The security methods considered in .NET technology are key components in ensuring the
reliability and security of software. The study analysed and described in detail various security
approaches, such as authentication and authorisation using various mechanisms, including
Windows Authentication, Forms Authentication, Claims-based Authentication, OAuth 2.0, OpenID
Connect and Role-Based Authorisation. Encryption aspects were also explored, including
symmetric and asymmetric encryption and hashing. ASP.NET membership access control,
rolebased access control, token-based authentication, and the secure WebSocket protocol were also
covered.</p>
      <p>Each of these methods has its own advantages and disadvantages, but by combining them we
can create a comprehensive security system that ensures the highest level of security for .NET
software. For example, different authentication and authorisation methods allow us to flexibly
adapt the security system to the specific needs of the project, and protection measures against XSS
attacks (Input Validation, Output Encoding, XSS protection libraries, HttpOnly cookies, Content
Security Policy) and CSRF attacks (Anti-CSRF token, HTTP headers, SameSite cookies) help us to
prevent various software vulnerabilities.</p>
      <p>Thus, the conclusions of the study confirm that the implementation and use of various security
methods in .NET technology is a key element for creating reliable and secure software. Careful
analysis and selection of optimal security methods will help ensure the highest level of data and
resource protection on the .NET platform, which is critical to the success of any project.
(1)
(2)
Declaration on Generative AI
While preparing this work, the authors used the AI programs Grammarly Pro to correct text
grammar and Strike Plagiarism to search for possible plagiarism. After using this tool, the authors
reviewed and edited the content as needed and took full responsibility for the publication’s content.</p>
    </sec>
  </body>
  <back>
    <ref-list>
      <ref id="ref1">
        <mixed-citation>
          [1]
          <string-name>
            <given-names>O.</given-names>
             
            <surname>Mykhaylova</surname>
          </string-name>
          ,
          <string-name>
            <given-names>M.</given-names>
             
            <surname>Korol</surname>
          </string-name>
          ,
          <string-name>
            <surname>R.</surname>
          </string-name>
           Kyrychok,
          <article-title>Research and Analysis of Issues and Challenges in Ensuring Cyber Security in Cloud Computing</article-title>
          , in: Cybersecurity Providing in Inf. and
          <string-name>
            <surname>Telecomm. Systems</surname>
            <given-names>II</given-names>
          </string-name>
          , vol.
          <volume>3826</volume>
          (
          <year>2024</year>
          )
          <fpage>30</fpage>
          -
          <lpage>39</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref2">
        <mixed-citation>
          [2]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Martseniuk</surname>
          </string-name>
          , et al.,
          <source>Automated Conformity Verification Concept for Cloud Security, in: Cybersecurity Providing in Inf. and Telecomm. Systems, CPITS</source>
          , vol.
          <volume>3654</volume>
          (
          <year>2024</year>
          )
          <fpage>25</fpage>
          -
          <lpage>37</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref3">
        <mixed-citation>
          [3]
          <string-name>
            <given-names>Y.</given-names>
             
            <surname>Martseniuk</surname>
          </string-name>
          , et al.,
          <source>Universal Centralized Secret Data Management for Automated Public Cloud Provisioning</source>
          , in: Cybersecurity Providing in Inf. and
          <string-name>
            <surname>Telecomm. Systems</surname>
            <given-names>II</given-names>
          </string-name>
          , vol.
          <volume>3826</volume>
          (
          <year>2024</year>
          )
          <fpage>72</fpage>
          -
          <lpage>81</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref4">
        <mixed-citation>
          [4]
          <string-name>
            <given-names>A.</given-names>
            <surname>Ilyenko</surname>
          </string-name>
          , et al.,
          <article-title>Practical Aspects of Using Fully Homomorphic Encryption Systems to Protect Cloud Computing</article-title>
          , in: Cybersecurity Providing in Inf. and
          <string-name>
            <surname>Telecomm. Systems</surname>
            <given-names>II</given-names>
          </string-name>
          , vol.
          <volume>3550</volume>
          (
          <year>2023</year>
          )
          <fpage>226</fpage>
          -
          <lpage>233</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref5">
        <mixed-citation>
          [5]
          <string-name>
            <given-names>V.</given-names>
            <surname>Shapoval</surname>
          </string-name>
          , et al.,
          <article-title>Automation of Data Management Processes in Cloud Storage</article-title>
          ,
          <source>in: Cybersecurity Providing in Inf. and Telecomm. Systems, CPITS</source>
          , vol.
          <volume>3654</volume>
          (
          <year>2024</year>
          )
          <fpage>410</fpage>
          -
          <lpage>418</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref6">
        <mixed-citation>
          [6]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Martseniuk</surname>
          </string-name>
          , et al,
          <article-title>Research of the Centralized Configuration Repository Efficiency for Secure Cloud Service Infrastructure Management</article-title>
          ,
          <source>in: Cybersecurity Providing in Inf. and Telecomm. Systems</source>
          , vol.
          <volume>3991</volume>
          (
          <year>2025</year>
          )
          <fpage>260</fpage>
          -
          <lpage>274</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref7">
        <mixed-citation>
          [7]
          <string-name>
            <given-names>O.</given-names>
            <surname>Vakhula</surname>
          </string-name>
          ,
          <string-name>
            <given-names>I.</given-names>
            <surname>Opirskyy</surname>
          </string-name>
          ,
          <string-name>
            <surname>O. Mykhaylova,</surname>
          </string-name>
          <article-title>Research on Security Challenges in Cloud Environments and Solutions based on the “Security-as-Code” Approach</article-title>
          , in: Cybersecurity Providing in
          <source>Inf. and Telecomm. Systems</source>
          , vol.
          <volume>3550</volume>
          (
          <year>2023</year>
          )
          <fpage>55</fpage>
          -
          <lpage>69</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref8">
        <mixed-citation>
          <article-title>[8] altexsoft</article-title>
          .com. https://www.altexsoft.
          <article-title>com/blog/the-good-and-the-bad-of-net-frameworkprogramming/</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref9">
        <mixed-citation>
          [9]
          <string-name>
            <given-names>С</given-names>
            <surname>#</surname>
          </string-name>
          .
          <article-title>Kontseptsiia ta syntaksys</article-title>
          .
          <source>Navch. Posibnyk. Lviv, Vydavnychyi tsentr LNU imeni Ivana Franka</source>
          ,
          <year>2006</year>
          . https://ami.lnu.edu.ua/wp-content/uploads/2017/05/C_sharp.pdf
        </mixed-citation>
      </ref>
      <ref id="ref10">
        <mixed-citation>
          [10] support.microsoft.com. https://support.microsoft.com/en-us/topic/asp-net
          <article-title>-security-</article-title>
          <string-name>
            <surname>overview7c8562d3-</surname>
          </string-name>
          7bea
          <string-name>
            <surname>-</surname>
          </string-name>
          306c
          <string-name>
            <surname>-</surname>
          </string-name>
          4c78-98dd6c6993b3
        </mixed-citation>
      </ref>
      <ref id="ref11">
        <mixed-citation>
          [11] medium.com. https://medium.com/@kerimkkara/authentication-and
          <article-title>-authorization-in-asp-netcore-a-comprehensive-guide-dfb8fb806ac7</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref12">
        <mixed-citation>[12] learn.microsoft.com. https://learn.microsoft.com/en-us/windows-server/security/windowsauthentication/windows-authentication-overview</mixed-citation>
      </ref>
      <ref id="ref13">
        <mixed-citation>
          [13]
          <string-name>
            <given-names>P.</given-names>
             
            <surname>Petriv</surname>
          </string-name>
          ,
          <string-name>
            <surname>I.</surname>
          </string-name>
           Opirskyy,
          <string-name>
            <given-names>N.</given-names>
             
            <surname>Mazur</surname>
          </string-name>
          , Modern Technologies of Decentralized Databases, Authentication, and Authorization Methods, in: Cybersecurity Providing in Inf. and
          <string-name>
            <surname>Telecomm. Systems</surname>
            <given-names>II</given-names>
          </string-name>
          , vol.
          <volume>3826</volume>
          (
          <year>2024</year>
          )
          <fpage>60</fpage>
          -
          <lpage>71</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref14">
        <mixed-citation>
          [14]
          <article-title>c-sharpcorner</article-title>
          .com. https://www.c-sharpcorner.com/UploadFile/fa9d0d/forms-authenticationin-Asp-Net
        </mixed-citation>
      </ref>
      <ref id="ref15">
        <mixed-citation>
          [15] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/core/security/authorization/ claims?view
          <source>=aspnetcore-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref16">
        <mixed-citation>[16] learn.microsoft.com. https://learn.microsoft.com/uk-ua/power-pages/security/authentication/ oauth2-settings</mixed-citation>
      </ref>
      <ref id="ref17">
        <mixed-citation>
          [17] learn.microsoft.com. https://learn.microsoft.com/uk-ua/aspnet/core/security/authorization/ roles?view
          <source>=aspnetcore-3</source>
          .
          <fpage>1</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref18">
        <mixed-citation>
          [18]
          <string-name>
            <given-names>V.</given-names>
            <surname>Sokolov</surname>
          </string-name>
          ,
          <string-name>
            <given-names>P.</given-names>
            <surname>Skladannyi</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Hulak</surname>
          </string-name>
          ,
          <article-title>Stability Verification of Self-Organized Wireless Networks with Block Encryption</article-title>
          ,
          <source>in: 5th Int. Workshop on Computer Modeling and Intelligent Systems</source>
          , vol.
          <volume>3137</volume>
          (
          <year>2022</year>
          )
          <fpage>227</fpage>
          -
          <lpage>237</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref19">
        <mixed-citation>
          [19]
          <string-name>
            <given-names>M.</given-names>
             
            <surname>Iavich</surname>
          </string-name>
          , et al.,
          <article-title>Classical and Post-Quantum Encryption for GDPR</article-title>
          , in: Classic, Quantum, and
          <string-name>
            <surname>Post-Quantum</surname>
            <given-names>Cryptography</given-names>
          </string-name>
          , vol.
          <volume>3829</volume>
          (
          <year>2024</year>
          )
          <fpage>70</fpage>
          -
          <lpage>78</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref20">
        <mixed-citation>
          [20]
          <string-name>
            <given-names>R.</given-names>
            <surname>Chernenko</surname>
          </string-name>
          , et al.,
          <article-title>Encryption Method for Systems with Limited Computing Resources</article-title>
          ,
          <source>in: Cybersecurity Providing in Information and Telecomm. Systems</source>
          , vol.
          <volume>3288</volume>
          (
          <year>2022</year>
          )
          <fpage>142</fpage>
          -
          <lpage>148</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref21">
        <mixed-citation>
          [21]
          <string-name>
            <given-names>A.</given-names>
            <surname>Ilyenko</surname>
          </string-name>
          , et al.,
          <article-title>Practical Aspects of Using Fully Homomorphic Encryption Systems to Protect Cloud Computing, in: Cybersecurity Providing in Information and Telecomm</article-title>
          .
          <string-name>
            <surname>Systems</surname>
            <given-names>II</given-names>
          </string-name>
          , vol.
          <volume>3550</volume>
          (
          <year>2023</year>
          )
          <fpage>226</fpage>
          -
          <lpage>233</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref22">
        <mixed-citation>[22] learn.microsoft.com. https://learn.microsoft.com/en-us/dotnet/standard/security/cryptographic -services</mixed-citation>
      </ref>
      <ref id="ref23">
        <mixed-citation>[23] learn.microsoft.com. https://learn.microsoft.com/en-us/dotnet/standard/security/encryptingdata</mixed-citation>
      </ref>
      <ref id="ref24">
        <mixed-citation>
          [24]
          <string-name>
            <given-names>D.</given-names>
            <surname>Shevchuk</surname>
          </string-name>
          , et al.,
          <source>Designing Secured Services for Authentication</source>
          , Authorization, and
          <article-title>Accounting of Users, in: Cybersecurity Providing in Information and Telecommunication Systems II</article-title>
          , vol.
          <volume>3550</volume>
          (
          <year>2023</year>
          )
          <fpage>217</fpage>
          -
          <lpage>225</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref25">
        <mixed-citation>
          [25]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Shcheblanin</surname>
          </string-name>
          , et al.,
          <source>Research of Authentication Methods in Mobile Applications, in: Cybersecurity Providing in Information and Telecomm. Systems</source>
          , vol.
          <volume>3421</volume>
          (
          <year>2023</year>
          )
          <fpage>266</fpage>
          -
          <lpage>271</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref26">
        <mixed-citation>
          [26] learn.microsoft.com. https://learn.microsoft.com/en-us/dotnet/api/system.security.cryptogra phy.
          <source>hashalgorithm?view=net-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref27">
        <mixed-citation>
          [27] learn.microsoft.com. https://learn.microsoft.com/en-us/dotnet/api/system.security.
          <source>accesscontr ol?view=net-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref28">
        <mixed-citation>[28] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/web-forms/overview/moving-to -aspnet-20/membership</mixed-citation>
      </ref>
      <ref id="ref29">
        <mixed-citation>
          [29] medium.com. https://medium.com/@microclip.lakeesha/net-core-6
          <article-title>-token-based-authenticati on-and-middleware-43a5fc86089a</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref30">
        <mixed-citation>
          [30] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/core/fundamentals/websockets? view
          <source>=aspnetcore-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref31">
        <mixed-citation>
          [31] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/core/security/cross-sitescripting
          <source>?view=aspnetcore-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref32">
        <mixed-citation>
          [32] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/web-pages/
          <article-title>overview/ui-layoutsand-themes/validating-user-input-in-aspnet-web-pages-sites</article-title>
        </mixed-citation>
      </ref>
      <ref id="ref33">
        <mixed-citation>
          [33] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/core/blazor/security/contentsecurity-policyview
          <source>=aspnetcore-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref34">
        <mixed-citation>
          [34]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Kostiuk</surname>
          </string-name>
          , et al.,
          <article-title>Models and Algorithms for Analyzing Information Risks during the Security Audit of Personal Data Information System</article-title>
          ,
          <source>in: 3rd Int. Conf. on Cyber Hygiene and Conflict Management in Global Information Networks</source>
          , vol.
          <volume>3925</volume>
          (
          <year>2025</year>
          )
          <fpage>155</fpage>
          -
          <lpage>171</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref35">
        <mixed-citation>
          [35] learn.microsoft.com. https://learn.microsoft.com/en-us/aspnet/core/security/anti-requestforgery
          <source>?view=aspnetcore-8</source>
          .
          <fpage>0</fpage>
        </mixed-citation>
      </ref>
      <ref id="ref36">
        <mixed-citation>
          [36]
          <string-name>
            <given-names>Y.</given-names>
            <surname>Kostiuk</surname>
          </string-name>
          , et al.,
          <article-title>Architecture of the Software System of Confidential Access to Information Resources of Computer Networks</article-title>
          ,
          <source>in: Cyber Security and Data Protection</source>
          , vol.
          <volume>4042</volume>
          (
          <year>2025</year>
          )
          <fpage>37</fpage>
          -
          <lpage>53</lpage>
          .
        </mixed-citation>
      </ref>
      <ref id="ref37">
        <mixed-citation>
          [37]
          <string-name>
            <given-names>I.</given-names>
            <surname>Tyshyk</surname>
          </string-name>
          ,
          <string-name>
            <given-names>H.</given-names>
            <surname>Hulak</surname>
          </string-name>
          ,
          <article-title>Testing an Organization's Information System for Unauthorized Access</article-title>
          ,
          <source>in: Cybersecurity Providing in Inf. and Telecomm. Systems</source>
          , vol.
          <volume>3826</volume>
          (
          <year>2024</year>
          )
          <fpage>17</fpage>
          -
          <lpage>29</lpage>
          .
        </mixed-citation>
      </ref>
    </ref-list>
  </back>
</article>