Logo

    Five Questions to Ask Yourself Before Creating a Web Project

    enAugust 02, 2024
    What types of sensitive data should developers avoid storing?
    What are some secure storage solutions mentioned for secrets?
    Why is it important to check library licenses?
    What can happen if sensitive data is stored in source code?
    Which tools can help developers detect secrets in code?

    Podcast Summary

    • Sensitive information in codeAvoid storing sensitive information like API keys, access tokens, passwords, and encryption keys in your code. Use environment variables or secure secret storage solutions instead to prevent potential breaches and associated financial losses or serious issues.

      As a developer working on web applications, it's crucial to avoid storing sensitive information in your code to prevent potential breaches and associated financial losses or serious issues. Confidential data such as API keys, access tokens, passwords, and encryption keys should not be stored in source code. Instead, use environment variables or secure secret storage solutions like Hashicorp Vault, AWS Secrets Manager, or GitHub Secrets. This choice depends on the project type, team experience, and technology stack. Failure to heed this advice can lead to serious consequences, as shown by the over 1.7 million potential secrets detected in public GitHub repositories in 2022 alone. Private projects may also harbor unnoticed leaks.

    • Code SecurityAutomate code scanning for secrets and use tools to ensure third-party libraries' licenses are compatible with your project to avoid legal issues and maintain competitive advantage.

      Developers need to be mindful of potential security vulnerabilities in their projects, particularly the presence of secrets in their code and the licenses of third-party libraries they use. Firstly, securing your code is crucial, and manual checks are time-consuming. Automation is the key to efficiently scanning your codebase for secrets such as API keys and passwords. Tools like Truffle Hog, Git Leagues, GitGuardian, GitHub Advanced Security, SonarCube, and Checkmarx can help detect and alert you to these issues. It's essential to understand that these are just a few examples, and there are many more options available. Secondly, using third-party libraries without proper consideration of their licenses can lead to legal issues and significant problems for your company. For instance, if a developer inadvertently includes a library distributed under the Affero General Public License (AGPL) in a commercial web product, it could require the entire codebase, including unique developments, to be made available for free use and modification. This could severely undermine the company's competitive advantage and business model. Therefore, it's crucial to allocate time to address these issues and choose the appropriate tools for your needs. In the case of third-party libraries, it's essential to understand their licenses and ensure they are compatible with your project's intended use. Ignorance is not an excuse, and the consequences of not addressing these issues can be severe.

    • Software licensingCheck licenses of libraries and software used, use built-in tools, update checks, automate, restrict access to development versions, and respect intellectual property.

      Using software code without explicit permission, even if it's publicly accessible, can lead to legal issues due to licensing and copyright laws. This is particularly relevant in countries that have signed international copyright agreements. To protect yourself and your company, it's essential to check the licenses of the libraries and software you use. Modern package managers like PHP Composer, Python pip, and Golang have built-in tools to help you with this. Remember to run these checks when updating dependencies and automate them if possible, as the license of a connected library can change in new versions. Additionally, ensure that your development versions are not publicly accessible to avoid potential misuse. In web development, it's common to have multiple versions of a project, and it's crucial to keep these restricted to authorized personnel. Ignoring these guidelines could lead to legal battles and reputational damage. Respecting others' intellectual property and development efforts is a human perspective that should be prioritized.

    • Test version securityDevelopers should purchase separate domains, restrict access, protect from search engine indexing, hide IP addresses, and close unused ports for test versions to prevent unauthorized access and potential data breaches.

      Ensuring the security of test versions during development is crucial to prevent potential harm to the product and potential security breaches. Test versions, which can sometimes be indexed more effectively by search engines than primary versions, may contain bugs or sensitive information, making them vulnerable to hacking and data leaks. To mitigate these risks, developers should purchase separate domains for test versions, restrict access to them, and protect them from search engine indexing. Additionally, hiding the real IP address of the project and closing unused ports are essential security measures often overlooked during development. By implementing these measures, developers can significantly reduce the risk of unauthorized access and potential data breaches.

    • Server IP address securityExposing a server's IP address can lead to security risks like DDOS attacks. Use a CDN or DDOS protection services to conceal IP address and prevent attacks. Be aware of email headers, DNS history, and third-party API requests revealing IP addresses.

      Exposing the real IP address of your servers can lead to various security issues, including DDOS attacks. Hackers can use this information to launch attacks, causing service disruptions and significant financial loss. To mitigate this risk, it's essential to conceal your server's real IP address. Using a content delivery network (CDN) or DDOS protection services can help hide your IP address and make it harder for attackers to target your system. Free options like CloudFlare offer both CDN capabilities and DDOS protection. Paid services like Imperva provide similar functions through their Curator web application firewall. However, there are additional considerations to keep in mind. Email headers can reveal your real IP address if you use your main server for sending emails. Changing your IP address or using a separate email server can help prevent this. Services like DNS history or Hoi's requests can reveal historical IP addresses associated with a domain. If your real IP was ever linked to your working domain, you should change it. When using DDOS protection for domains serving as API endpoints, be cautious as protection systems might introduce user verification steps that could disrupt the functioning of your client-side applications. Lastly, when your server sends requests to third-party APIs, it can inadvertently reveal its IP address. Using a proxy or VPN service can help conceal your IP address and add an extra layer of security.

    • Backend security measuresUse proxy servers, close unnecessary ports, restrict access to internal services, update dependencies and server software, and automate certificate renewal for enhanced security and to minimize risks of external attacks and data leaks.

      Securing a backend system involves more than just preventing common attacks like SQL injection or Cross-Site Request Forgery (CSRF). Here are some crucial but less frequently discussed security measures: 1. Using proxy servers can help protect against attacks, but hiding your project's real IP address is not a foolproof measure. 2. Closing ports used by your software from the external network is essential wherever possible. Changing standard ports is debatable, and configuring software to interact via Unix sockets instead of network TCP connections is often preferable. 3. For database management systems or other internal services on separate servers, ensure access is restricted to specific IP addresses that you strictly control. 4. Regularly update your project's dependencies and server software to prevent outdated and vulnerable code from being exploited. Automating updates can make this process easier. 5. Automating the renewal of security certificates is also crucial to prevent expired certificates from causing issues. These measures can help increase interaction speed, enhance security, minimize risks of external attacks and data leaks, and ensure that your backend system remains secure and up-to-date. Remember, security is an ongoing process, not a one-time event. Stay vigilant and keep up-to-date with the latest security best practices.

    • OWASP Top 10 risksThe OWASP Foundation is a valuable resource for understanding web application security risks. Their OWASP Top 10 document lists the most common and critical risks, including lesser-known attacks. Developers should stay informed and engage in discussions to ensure secure applications.

      Web application security is a critical aspect of back-end development that should not be overlooked. A valuable resource for gaining a deeper understanding of this topic is the OWASP Foundation, a nonprofit organization that offers a wealth of information on web application security risks. Their OWASP Top 10 document, available on their website, lists the most common and critical risks, including some lesser-known but equally dangerous attacks. It's essential for developers to stay informed and supportive of each other in this field. By sharing observations and experiences, we can all benefit from each other's insights. I encourage everyone to explore the OWASP Foundation's resources and engage in discussions about web application security. Let's work together to ensure that our applications are secure and protected from potential threats.

    Recent Episodes from Programming Tech Brief By HackerNoon

    Java vs. Scala: Comparative Analysis for Backend Development in Fintech

    Java vs. Scala: Comparative Analysis for Backend Development in Fintech

    This story was originally published on HackerNoon at: https://hackernoon.com/java-vs-scala-comparative-analysis-for-backend-development-in-fintech.
    Choosing the right backend technology for fintech development involves a detailed look at Java and Scala.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #java, #javascript, #java-vs-scala, #scala, #backend-development-fintech, #should-i-choose-scala, #java-for-fintech-development, #scala-for-fintech-development, and more.

    This story was written by: @grigory. Learn more about this writer by checking @grigory's about page, and for more stories, please visit hackernoon.com.

    Choosing the right backend technology for fintech development involves a detailed look at Java and Scala.

    A Simplified Guide for the"Dockerazition" of Ruby and Rails With React Front-End App

    A Simplified Guide for the"Dockerazition" of Ruby and Rails With React Front-End App

    This story was originally published on HackerNoon at: https://hackernoon.com/a-simplified-guide-for-thedockerazition-of-ruby-and-rails-with-react-front-end-app.
    This is a brief description of how to set up docker for a rails application with a react front-end
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #software-development, #full-stack-development, #devops, #deployment, #dockerization, #rails-with-react, #hackernoon-top-story, #react-tutorial, and more.

    This story was written by: @forison. Learn more about this writer by checking @forison's about page, and for more stories, please visit hackernoon.com.

    Dockerization involves two key concepts: images and containers. Images serve as blueprints for containers, containing all the necessary information to create a container. A container is a runtime instance of an image, comprising the image itself, an execution environment, and runtime instructions. In this article, we will provide a hands-on guide to dockerizing your Rails and React applications in detail.

    Step-by-Step Guide to Publishing Your First Python Package on PyPI Using Poetry: Lessons Learned

    Step-by-Step Guide to Publishing Your First Python Package on PyPI Using Poetry: Lessons Learned

    This story was originally published on HackerNoon at: https://hackernoon.com/step-by-step-guide-to-publishing-your-first-python-package-on-pypi-using-poetry-lessons-learned.
    Learn to create, prepare, and publish a Python package to PyPI using Poetry. Follow our step-by-step guide to streamline your package development process.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #python, #python-tutorials, #python-tips, #python-development, #python-programming, #python-packages, #package-management, #pypi, and more.

    This story was written by: @viachkon. Learn more about this writer by checking @viachkon's about page, and for more stories, please visit hackernoon.com.

    Poetry automates many tasks for you, including publishing packages. To publish a package, you need to follow several steps: create an account, prepare a project, and publish it to PyPI.

    Building a Level Viewer for The Legend Of Zelda - Twilight Princess

    Building a Level Viewer for The Legend Of Zelda - Twilight Princess

    This story was originally published on HackerNoon at: https://hackernoon.com/building-a-level-viewer-for-the-legend-of-zelda-twilight-princess.
    I programmed a web BMD viewer for Twilight Princess because I am fascinated by analyzing levels and immersing myself in the details of how they were made.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #reverse-engineering, #bmd, #game-development, #the-legend-of-zelda, #level-design, #web-bmd-viewer, #level-viewer-for-zelda-game, #hackernoon-top-story, and more.

    This story was written by: @hackerclz1yf3a00000356r1e6xb368. Learn more about this writer by checking @hackerclz1yf3a00000356r1e6xb368's about page, and for more stories, please visit hackernoon.com.

    I started programming a web BMD viewer for Twilight Princess (Nintendo GameCube) because I love this game and as a game producer, I am fascinated by analyzing levels and immersing myself in the details of how they were made.

    How to Simplify State Management With React.js Context API - A Tutorial

    How to Simplify State Management With React.js Context API - A Tutorial

    This story was originally published on HackerNoon at: https://hackernoon.com/how-to-simplify-state-management-with-reactjs-context-api-a-tutorial.
    Master state management in React using Context API. This guide provides practical examples and tips for avoiding prop drilling and enhancing app performance.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #reactjs, #context-api, #react-tutorial, #javascript-tutorial, #frontend, #state-management, #hackernoon-top-story, #prop-drilling, and more.

    This story was written by: @codebucks. Learn more about this writer by checking @codebucks's about page, and for more stories, please visit hackernoon.com.

    This blog offers a comprehensive guide on managing state in React using the Context API. It explains how to avoid prop drilling, enhance performance, and implement the Context API effectively. With practical examples and optimization tips, it's perfect for developers looking to streamline state management in their React applications.

    Augmented Linked Lists: An Essential Guide

    Augmented Linked Lists: An Essential Guide

    This story was originally published on HackerNoon at: https://hackernoon.com/augmented-linked-lists-an-essential-guide.
    While a linked list is primarily a write-only and sequence-scanning data structure, it can be optimized in different ways.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #data-structures, #linked-lists, #memory-management, #linked-lists-explained, #how-does-a-linked-list-work, #hackernoon-top-story, #eviction-keys, #linked-list-guide, and more.

    This story was written by: @amoshi. Learn more about this writer by checking @amoshi's about page, and for more stories, please visit hackernoon.com.

    While a linked list is primarily a write-only and sequence-scanning data structure, it can be optimized in different ways. Augmentation is an approach that remains effective in some cases and provides extra capabilities in others.

    How to Write Tests for Free

    How to Write Tests for Free

    This story was originally published on HackerNoon at: https://hackernoon.com/how-to-write-tests-for-free.
    This article describes deeper analysis on whether to write tests or not, brings pros and cons, and shows a technique that could save you a lot of time
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #testing, #should-i-write-tests, #how-to-write-tests, #increase-coverage, #test-driven-development, #why-tests-matter, #what-is-tdd, #are-tests-necessary, and more.

    This story was written by: @sergiykukunin. Learn more about this writer by checking @sergiykukunin's about page, and for more stories, please visit hackernoon.com.

    This article describes deeper analysis on whether to write tests or not, brings pros and cons, and shows a technique that could save you a lot of time and efforts on writing tests.

    Five Questions to Ask Yourself Before Creating a Web Project

    Five Questions to Ask Yourself Before Creating a Web Project

    This story was originally published on HackerNoon at: https://hackernoon.com/five-questions-to-ask-yourself-before-creating-a-web-project.
    Web projects can fail for many reasons. In this article I will share my experience that will help you solve some of them.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #web-development, #security, #programming, #secrets-stored-in-code, #library-licenses, #access-restriction, #closing-unused-ports, #hackernoon-top-story, and more.

    This story was written by: @shcherbanich. Learn more about this writer by checking @shcherbanich's about page, and for more stories, please visit hackernoon.com.

    Web projects can fail for many reasons. In this article I will share my experience that will help you solve some of them.

    Declarative Shadow DOM: The Magic Pill for Server-Side Rendering and Web Components

    Declarative Shadow DOM: The Magic Pill for Server-Side Rendering and Web Components

    This story was originally published on HackerNoon at: https://hackernoon.com/declarative-shadow-dom-the-magic-pill-for-server-side-rendering-and-web-components.
    Discover how to use Shadow DOM for server-side rendering to improve web performance and SEO.
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #server-side-rendering, #shadow-dom, #web-components, #declarative-shadow-dom, #static-html, #web-component-styling, #web-performance-optimization, #imperative-api-shadow-dom, and more.

    This story was written by: @pradeepin2. Learn more about this writer by checking @pradeepin2's about page, and for more stories, please visit hackernoon.com.

    Shadow DOM is a web standard enabling encapsulation of DOM subtrees in web components. It allows developers to create isolated scopes for CSS and JavaScript within a document, preventing conflicts with other parts of the page. Shadow DOM's key feature is its "shadow root," serving as a boundary between the component's internal structure and the rest of the document.

    How to Scrape Data Off Wikipedia: Three Ways (No Code and Code)

    How to Scrape Data Off Wikipedia: Three Ways (No Code and Code)

    This story was originally published on HackerNoon at: https://hackernoon.com/how-to-scrape-data-off-wikipedia-three-ways-no-code-and-code.
    Get your hands on excellent manually annotated datasets with Google Sheets or Python
    Check more stories related to programming at: https://hackernoon.com/c/programming. You can also check exclusive content about #python, #google-sheets, #data-analysis, #pandas, #data-scraping, #web-scraping, #wikipedia-data, #scraping-wikipedia-data, and more.

    This story was written by: @horosin. Learn more about this writer by checking @horosin's about page, and for more stories, please visit hackernoon.com.

    For a side project, I turned to Wikipedia tables as a data source. Despite their inconsistencies, they proved quite useful. I explored three methods for extracting this data: - Google Sheets: Easily scrape tables using the =importHTML function. - Pandas and Python: Use pd.read_html to load tables into dataframes. - Beautiful Soup and Python: Handle more complex scraping, such as extracting data from both tables and their preceding headings. These methods simplify data extraction, though some cleanup is needed due to inconsistencies in the tables. Overall, leveraging Wikipedia as a free and accessible resource made data collection surprisingly easy. With a little effort to clean and organize the data, it's possible to gain valuable insights for any project.