What are the best practices for writing a secure application?

David Thielen 3,211 Reputation points
2023-02-09T19:12:51.3333333+00:00

Hi all;

I've read a ton of articles that we need to write applications that are secure. That it's critical to write defensively from the start and implement all best practice secure suggestions.

What I can't find is the list of suggestions. I know about SQL injection attacks. But what else? (And the few articles I've found on this are dated 2010 or thereabouts.)

Very specifically for an ASP.NET Core 6 + Blazor server side application that will run on Azure web services. And will access an Azure SQL Database via Entity Frameworks (so no injection attack worries).

What do I need to do, and not do, to make the app as secure as possible?

thanks - dave

Developer technologies ASP.NET ASP.NET Core
Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,933 questions
0 comments No comments
{count} votes

Accepted answer
  1. Anonymous
    2023-02-13T06:12:13.5733333+00:00

    Hi @David Thielen

    ASP.NET Core security topics:

    ASP.NET Core enables developers to configure and manage security. The following list provides links to security topics:

    These security features allow you to build robust and secure ASP.NET Core apps. For Blazor application, you can refer to ASP.NET Core Blazor authentication and authorization.

    To Security in Azure App Service, you can protect your App Service app via the following sections:

    1. HTTPS and Certificates
    2. Insecure protocols (HTTP, TLS 1.0, FTP)
    3. Static IP restrictions
    4. Client authentication and authorization
    5. Service-to-service authentication
    6. Connectivity to remote resources
    7. Application secrets
    8. Network isolation

    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    Best regards,

    Dillion


1 additional answer

Sort by: Most helpful
  1. AgaveJoe 30,126 Reputation points
    2023-02-09T20:26:06.4833333+00:00

    Security is a vast subject. If you are referring to typically security vulnerabilities found in web applications then see the OWASP foundation. The OWASP Foundation tracks vulnerabilities, provides mitigation suggestions, and provides vulnerability testing tools.

    OWASP Top Ten

    There are also coding best practices associated with the language or framework you're targeting.

    ASP.NET Core Best Practices

    ASP.NET Core Blazor performance best practices


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.