In reviewing a source code of an ASP.Net web application, you have discovered the following routine...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
In reviewing a source code of an ASP.Net web application, you have discovered the following routine for a login page: protected void Authenticate (object theSender, AuthenticateEventArgs theEvent) { SqlConnection conn = new SqlConnection(@"Data Source-. \sqlexpress; Initial Catalog MyDb;Integrated Security=True"); string query="SELECT * FROM UsersTable WHERE Email = "" + Login.UserName + "" AND Password =HASHBYTES ('SHA2_512', " + Login.Password + "'+ salt)"; adapter = new SqlDataAdapter(query, conn); dataTable new DataTable(); adapter.Fill(dataTable); if (dataTable.Rows.Count >= 1) { } Response.Redirect("index.aspx"); Identify the vulnerability and remediate the code using appropriate countermeasures. Demonstrate how the vulnerability is formed from the user input. In reviewing a source code of an ASP.Net web application, you have discovered the following routine for a login page: protected void Authenticate (object theSender, AuthenticateEventArgs theEvent) { SqlConnection conn = new SqlConnection(@"Data Source-. \sqlexpress; Initial Catalog MyDb;Integrated Security=True"); string query="SELECT * FROM UsersTable WHERE Email = "" + Login.UserName + "" AND Password =HASHBYTES ('SHA2_512', " + Login.Password + "'+ salt)"; adapter = new SqlDataAdapter(query, conn); dataTable new DataTable(); adapter.Fill(dataTable); if (dataTable.Rows.Count >= 1) { } Response.Redirect("index.aspx"); Identify the vulnerability and remediate the code using appropriate countermeasures. Demonstrate how the vulnerability is formed from the user input.
Expert Answer:
Answer rating: 100% (QA)
The code provided contains a significant security vulnerability known as SQL injection The vulnerabi... View the full answer
Related Book For
Principles of Auditing and Other Assurance Services
ISBN: 978-0078025617
19th edition
Authors: Ray Whittington, Kurt Pany
Posted Date:
Students also viewed these programming questions
-
Case Study: Quick Fix Dental Practice Technology requirements Application must be built using Visual Studio 2019 or Visual Studio 2017, professional or enterprise. The community edition is not...
-
Let A, B be sets. Define: (a) the Cartesian product (A B) (b) the set of relations R between A and B (c) the identity relation A on the set A [3 marks] Suppose S, T are relations between A and B, and...
-
The accounting records of Shinault Inc. show the following data for 2017 (its first year of operations). 1. Life insurance expense on officers was $9,000. 2. Equipment was acquired in early January...
-
What percent of the money supply depicted in Figure 13.1 is cash? Figure 13.1 - Total money supply ($3,100 billion) $1,345 Curroncy in circulation $1,752 Transactions account balancos $3 -Traveler's...
-
Find the absolute value of 2 - 3i.
-
Consider the following cash flow profile and assume MARR is 10 percent/year. a. What does Descartes' rule of signs tell us about the IRR(s) of this project? b. What does Norstrom's criterion tell us...
-
Rassy and the team were concerned with the results of your analysis. They spent the afternoon brainstorming alternative ways for shortening the project duration. They rejected outsourcing activities...
-
A wheel initially at rest begins rotating because of a constant angular acceleration. During a certain interval AT = 13s, the wheel goes through 84 rev and reaches an angular speed of 11 rev/s. (a)...
-
1. Name at least three ways that Shu could automate her asset management. Suggest at least one option for retirement savings, general savings, and general convenience. 2. What major factors should...
-
Gordon lists 12 "roadblocks to communication". Below you will find statements a leader or an employee might make. Select the statements that illustrate roadblocks. 1. You are so intelligent and have...
-
Discuss with suitable illustration how heaps can be used in memory management.
-
Given P(x) = x - 3x + 9x - 27, find the zeros, real and non-real of P The zeros are Write P in factored form (as a product of linear factors). Be sure to write the full equation, including P(x) =
-
A portfolio consists of Stocks A and B and has an expected return of 11.6 percent. Stock A has an expected return of 17.8 percent while Stock B is expected to return 8.4 percent. What is the...
-
How do adjustable rate mortgages work? What are the pros and cons of these types of mortgages?
-
Assuming your home heating oil conta plins about 4 0 kWh of energy per gallon, determine the approximate rate of oil consumption in your home furnace when it's producing heat at the rate of 1 1 2 , 0...
-
Journalize the following adjustments. (Credit account titles are automatically indented when the amount is entered. Do not indent manually.) 1. Services performed but unbilled and uncollected at July...
-
Chris Zulliger was a chef at the Plaza Restaurant in the Snowbird Ski Resort in Utah. The restaurant is located at the base of a mountain. As a chef for the Plaza, Zulliger was instructed by his...
-
Identify three expense accounts that are verified during the audit of balance sheet accounts; also, identify the related balance sheet accounts.
-
In the context of an audit of financial statements, explain what is meant by professional skepticism.
-
Assume that you are a partner with the firm of Slater & Lowe LLP. You have been asked by Grayson, Inc., an industrial supply company, to provide assurance about the change in existing customer...
-
Describe the distinctive characteristic of weighted-average computations in assigning costs to units completed and closing work in progress.
-
Refer to requirement 2 of Exercise4.11. Required Prepare summary journal entries for the use of direct materials and conversion costs. Also prepare a journal entry to transfer out the cost of goods...
-
Le Roi du Plastique Sarl has two processes extrusion and thermo-assembly. Consider the June 2022 data for physical units in the thermo-assembly process of Le Roi du Plastique: opening work in...
Study smarter with the SolutionInn App