I gave this talk during first Infosec meetup in Kraków/Poland on 13th March 2014. After viewing this presentation you'll know how and why you should use SELinux (or others LSMs).
Atmosphere 2014: Scaling and securing node.js apps - Maciej LasykPROIDEA
After few years of node.js in operation we know it's very fast. We all heard stories about backend services running with the help of node.js and V8 core. But what we have learned about the security of such applications? What are the major threats here? I'll explain how to create node.js apps in a secure and reliable way. Also - I'll show how those could be scaled easily with (or without) help of Linux containers (Docker based) or jail - systems like Selinux Sandbox or libvirt sandbox.
Maciej Lasyk - I've been working in IT Operations for the last 14 years. I've seen how infrastructures raised and failed, how great minds worked on scalability and kept the high pace of their platforms. I've been scaling and securing webapps since many years; within Ganymede company, now with Lumesse and Fedora Project. I'm Open Source contributor, enthusiast and evangelist. I also support security projects like OWASP. You can catch me on Twitter @docent_net and also see my work in github @docent-net and my personal blog.
This document discusses security linters Bandit and Gosec. It provides information on what each linter is, the types of security issues it can detect in Python and Go code respectively, how to configure and use each linter, examples of integrating the linters into development tools and workflows, and how to contribute to the open source projects. It also describes a yet-to-be-named GitHub App the presenter is working on that will automatically scan pull requests with Bandit and Gosec.
Lessons Learned in Automating Compliance for ContainersAll Things Open
This document discusses open source software compliance for containers. It explains that container images are made up of layered filesystems, so the dependencies and licenses of each layer need to be determined. However, determining this information can be challenging as Dockerfiles and container build processes do not always provide full transparency. The document introduces the Tern tool, which aims to automate open source software compliance for containers by analyzing package managers, files, and layers to provide package versions, licenses, and software sources used.
10 Excellent Ways to Secure Your Spring Boot Application - Devoxx Belgium 2019Matt Raible
Spring Boot is an excellent way to build Java applications with the Spring Framework. If you’re developing apps that handle sensitive data, you should make sure they’re secure.
This session will cover HTTPS, dependency checking, CSRF, using a CSP to prevent XSS, OIDC, password hashing, and much more!
You’ll learn how to add these features to a real application, using the Java language you know and love.
* YouTube video: https://www.youtube.com/watch?v=PpqNMhe4Bd0
* Blog post: https://developer.okta.com/blog/2018/07/30/10-ways-to-secure-spring-boot
* Cheat sheet: https://snyk.io/blog/spring-boot-security-best-practices/
DevOpsDaysRiga 2018: Andrew Martin - Continuous Kubernetes Security DevOpsDays Riga
Now that we have passed “peak orchestrator” and as Kubernetes eats the world, we are left wondering: how secure is Kubernetes? Can we really run Google-style multi tenanted infrastructure safely? And how can we be sure what we configured yesterday will be in place tomorrow? In this talk we discuss: - the Kubernetes security landscape - risks, security models, and configuration best-practices - how to configure users and applications with least-privilege - how to isolate and segregate workloads and networks - hard and soft multi-tenancy - Continuous Security approaches to Kubernetes.
This document discusses secrets management in containers and recommends solutions like Kubernetes Secrets, Docker Swarm Secrets, DC/OS Secrets, Keywhiz, and Hashicorp Vault. It highlights Hashicorp Vault's purpose-built focus on secrets, key rolling capabilities, comprehensive access control, expiration policies, and extensibility. The document then provides a case study of Aqua Security's integration with Hashicorp Vault, which allows for central secret management without persisting secrets to disk, secured communications, control over user/group secret access, usage tracking, and runtime secret rotation/revocation without container restarts.
Serialization vulnerabilities are very dangerous and can enable remote code execution and other attacks. They are difficult to fix due to issues with blacklisting, whitelisting, and the lack of a "silver bullet" solution. Serialization problems are common in Java libraries and formats like JSON/XML. Developers must think carefully before applying fixes and avoid playing "gadget whack-a-mole" since the vulnerabilities are language and format agnostic.
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...Matt Raible
In this session, you'll learn about recommended patterns for securing your backend APIs, the infrastructure they run on, and your SPAs and mobile apps.
The world is no longer a place where you just need to secure your apps’ UI. You need to pay attention to your dependency pipeline and open source frameworks, too. Once you have the app built, with secure-by-design code, what about the cloud it runs on? Are the servers secure? What about the accounts you use to access them?
If you lock all that sh*t down, how do you codify your solution so you can transport it cloud-to-cloud, or back to on-premises? This session will explore these concepts and many more!
Chris Rutter: Avoiding The Security BrickMichael Man
Security teams provide concise summaries of dependency scans to development teams. The summaries include the vulnerability found, whether the team is affected, and how to remediate. This avoids lengthy CVE research and allows teams to focus on actual vulnerabilities. Any common libraries and frameworks are pre-scanned by security to share findings.
Cloud native applications are popular these days – applications that run in the cloud reliably und scale almost arbitrarily. They follow three key principles: They are built and composed as microservices, they are packaged and distributed in containers and the containers are executed dynamically in the cloud. In this hands-on session we will show how to build, package and deploy cloud native Java EE applications on top of DC/OS - fully automated with Gradle using cloud native infrastructure like Consul, Fabio, Hystrix and Prometheus. And for the fun of it we will be using an off-the-shelf DJ pad, programmed with nothing else than the Java Sound API, to demonstrate the core concepts and to visualize and remote control DC/OS.
This document discusses using Kubernetes and Vault together to manage secrets. It summarizes that Kubernetes is an open-source system for automating deployment, operations, and scaling of containerized applications, while Vault provides a single source for secrets, access via API and CLI, leasing and renewal of secrets, auditing, access control lists, and secure secret storage. It notes that while Kubernetes has native secrets functionality, Vault is useful for separately managing secrets from applications for improved security and process. An example is provided of using Vault to fetch and renew SSL certificates for a MongoDB deployment in Kubernetes.
Cloud Compliance with Open Policy AgentQAware GmbH
Cloud Native Virtual Summit featuring Kubernetes, April 2020,
talk by Alex Krause (@alex0ptr, Software Engineer at QAware)
== Please download slides if blurred! ==
Abstract: Microservices distribute the complexity of applications into smaller processes and infrastructure. In conclusion policies for encyrption, cost labelling or access control become decentralized too. The already complex components of a cloud-native application, such as container orchestration, IaaS components and CI/CD pipelines, complicate the technically uniform definition of these guidelines further.
OPA (Open Policy Agent) is a CNCF tool to define and check policies. What makes opa special is the easy integration into cloud-native environments in combination with rego, a universal logical programming language which allows defining policies across technology boundaries. This technical presentation is an introduction into OPA and demonstrates typical use-cases.
Devoops: DoJ Annual Cybersecurity Training Symposium Edition 2015Chris Gates
This document summarizes a talk given on DevOps infrastructure security. It discusses how various DevOps tools like GitHub, Jenkins, AWS config files, Chef, and in-memory databases like Redis and Memcache can expose sensitive information if not properly secured. Specific issues covered include exposed Git repositories, weak default credentials, plaintext storage of secrets, and lack of authentication. The document provides recommendations on securing these tools such as enabling authentication, upgrading versions, and segmenting tools from public access.
Control Plane: Security Rationale for Istio (DevSecOps - London Gathering, Ja...Michael Man
Security Rationale For Istio
An introduction to Istio security, looking at how Istio helps to keeps your security team happy by satisfying Kubernetes security requirements for multi-tenancy, and your developers happy by reducing implementation effort. Istio is still an evolving technology, and outstanding issues and impending improvements will be discussed.
In a rare mash-up, DevOps is increasingly blending the work of both application and network security professionals. In a quest to move faster, organizations can end up creating security vulnerabilities using the tools and products meant to protect them. Both Chris Gates (carnal0wnage) and Ken Johnson (cktricky) will share their collaborative research into the technology driving DevOps as well as share their stories of what happens when these tools are used insecurely as well as when the tools are just insecure.
Technologies discussed will encompass AWS Technology, Chef, Puppet, Hudson/Jenkins, Vagrant, Kickstart and much, much more. Everything from common misconfigurations to remote code execution will be presented. This is research to bring awareness to those responsible for securing a DevOps environment.
Presented at All Things Open
Presented by Mark Voelker with VMware
10/23/18 - 3:00 PM - Networking/Infrastructure track
For more by Mark Voelker: https://www.slideshare.net/markvoelker
ASFWS 2012 - Node.js Security – Old vulnerabilities in new dresses par Sven V...Cyber Security Alliance
The document discusses security issues related to Node.js applications. It begins by providing an overview of Node.js and how it allows JavaScript to be executed server-side. It then discusses how well-known vulnerabilities like cross-site scripting (XSS), code injection, and remote code execution can occur in Node.js applications if developers are not careful. Specific examples are provided around evaluation of untrusted JSON, uncontrolled use of the eval() function, and crashing servers by causing unhandled exceptions. The document concludes by noting that many common features are not supported out of the box in Node.js and must be added through external modules.
What is Google Cloud Good For at DevFestInspire 2021Robert John
My presentation at DevFestLagos on "What is Google Cloud Good For". It's an overview of the Google Cloud Platform for those unfamiliar with it. You can watch the session here: https://www.youtube.com/watch?v=wi-p8fqFLrU
This document discusses security test automation. It provides examples of unit tests, static code analysis, and dynamic code analysis to test for vulnerabilities like XSS, input validation, TLS configuration, and known library vulnerabilities. Testing HTTP interactions, TLS settings, and library dependencies can be done programmatically through tools like RestAssured, SSL Labs, and OWASP Dependency Check. Automating security tests is important for projects to help ensure requirements are met continuously.
FabLab Bassa Romagna e ImoLUG nell'ambito del gruppo di lavoro su Linux, organizzano una serata dedicata alla Sicurezza Informatica; è un tema attuale, importante, ma molto sottovalutato.
Nella serata illustreremo come è possibile costruire un proprio Hacking Lab per imparare e testare localmente i principali software di IT Security. Sfrutteremo pertanto l'ambiente di virtualizzazione ProxMox per virtualizzare il sistema operativo vulnerabile Metaspoitable, sistema sviluppato dalla nota Radid7. Grazie a BackBox Linux analizzeremo la distribuzione vulnerabile alla ricerca di dettagli e di exploit da sfruttare.
This document discusses secrets management in containers and recommends solutions like Kubernetes Secrets, Docker Swarm Secrets, DC/OS Secrets, Keywhiz, and Hashicorp Vault. It highlights Hashicorp Vault's purpose-built focus on secrets, key rolling capabilities, comprehensive access control, expiration policies, and extensibility. The document then provides a case study of Aqua Security's integration with Hashicorp Vault, which allows for central secret management without persisting secrets to disk, secured communications, control over user/group secret access, usage tracking, and runtime secret rotation/revocation without container restarts.
Serialization vulnerabilities are very dangerous and can enable remote code execution and other attacks. They are difficult to fix due to issues with blacklisting, whitelisting, and the lack of a "silver bullet" solution. Serialization problems are common in Java libraries and formats like JSON/XML. Developers must think carefully before applying fixes and avoid playing "gadget whack-a-mole" since the vulnerabilities are language and format agnostic.
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...Matt Raible
In this session, you'll learn about recommended patterns for securing your backend APIs, the infrastructure they run on, and your SPAs and mobile apps.
The world is no longer a place where you just need to secure your apps’ UI. You need to pay attention to your dependency pipeline and open source frameworks, too. Once you have the app built, with secure-by-design code, what about the cloud it runs on? Are the servers secure? What about the accounts you use to access them?
If you lock all that sh*t down, how do you codify your solution so you can transport it cloud-to-cloud, or back to on-premises? This session will explore these concepts and many more!
Chris Rutter: Avoiding The Security BrickMichael Man
Security teams provide concise summaries of dependency scans to development teams. The summaries include the vulnerability found, whether the team is affected, and how to remediate. This avoids lengthy CVE research and allows teams to focus on actual vulnerabilities. Any common libraries and frameworks are pre-scanned by security to share findings.
Cloud native applications are popular these days – applications that run in the cloud reliably und scale almost arbitrarily. They follow three key principles: They are built and composed as microservices, they are packaged and distributed in containers and the containers are executed dynamically in the cloud. In this hands-on session we will show how to build, package and deploy cloud native Java EE applications on top of DC/OS - fully automated with Gradle using cloud native infrastructure like Consul, Fabio, Hystrix and Prometheus. And for the fun of it we will be using an off-the-shelf DJ pad, programmed with nothing else than the Java Sound API, to demonstrate the core concepts and to visualize and remote control DC/OS.
This document discusses using Kubernetes and Vault together to manage secrets. It summarizes that Kubernetes is an open-source system for automating deployment, operations, and scaling of containerized applications, while Vault provides a single source for secrets, access via API and CLI, leasing and renewal of secrets, auditing, access control lists, and secure secret storage. It notes that while Kubernetes has native secrets functionality, Vault is useful for separately managing secrets from applications for improved security and process. An example is provided of using Vault to fetch and renew SSL certificates for a MongoDB deployment in Kubernetes.
Cloud Compliance with Open Policy AgentQAware GmbH
Cloud Native Virtual Summit featuring Kubernetes, April 2020,
talk by Alex Krause (@alex0ptr, Software Engineer at QAware)
== Please download slides if blurred! ==
Abstract: Microservices distribute the complexity of applications into smaller processes and infrastructure. In conclusion policies for encyrption, cost labelling or access control become decentralized too. The already complex components of a cloud-native application, such as container orchestration, IaaS components and CI/CD pipelines, complicate the technically uniform definition of these guidelines further.
OPA (Open Policy Agent) is a CNCF tool to define and check policies. What makes opa special is the easy integration into cloud-native environments in combination with rego, a universal logical programming language which allows defining policies across technology boundaries. This technical presentation is an introduction into OPA and demonstrates typical use-cases.
Devoops: DoJ Annual Cybersecurity Training Symposium Edition 2015Chris Gates
This document summarizes a talk given on DevOps infrastructure security. It discusses how various DevOps tools like GitHub, Jenkins, AWS config files, Chef, and in-memory databases like Redis and Memcache can expose sensitive information if not properly secured. Specific issues covered include exposed Git repositories, weak default credentials, plaintext storage of secrets, and lack of authentication. The document provides recommendations on securing these tools such as enabling authentication, upgrading versions, and segmenting tools from public access.
Control Plane: Security Rationale for Istio (DevSecOps - London Gathering, Ja...Michael Man
Security Rationale For Istio
An introduction to Istio security, looking at how Istio helps to keeps your security team happy by satisfying Kubernetes security requirements for multi-tenancy, and your developers happy by reducing implementation effort. Istio is still an evolving technology, and outstanding issues and impending improvements will be discussed.
In a rare mash-up, DevOps is increasingly blending the work of both application and network security professionals. In a quest to move faster, organizations can end up creating security vulnerabilities using the tools and products meant to protect them. Both Chris Gates (carnal0wnage) and Ken Johnson (cktricky) will share their collaborative research into the technology driving DevOps as well as share their stories of what happens when these tools are used insecurely as well as when the tools are just insecure.
Technologies discussed will encompass AWS Technology, Chef, Puppet, Hudson/Jenkins, Vagrant, Kickstart and much, much more. Everything from common misconfigurations to remote code execution will be presented. This is research to bring awareness to those responsible for securing a DevOps environment.
Presented at All Things Open
Presented by Mark Voelker with VMware
10/23/18 - 3:00 PM - Networking/Infrastructure track
For more by Mark Voelker: https://www.slideshare.net/markvoelker
ASFWS 2012 - Node.js Security – Old vulnerabilities in new dresses par Sven V...Cyber Security Alliance
The document discusses security issues related to Node.js applications. It begins by providing an overview of Node.js and how it allows JavaScript to be executed server-side. It then discusses how well-known vulnerabilities like cross-site scripting (XSS), code injection, and remote code execution can occur in Node.js applications if developers are not careful. Specific examples are provided around evaluation of untrusted JSON, uncontrolled use of the eval() function, and crashing servers by causing unhandled exceptions. The document concludes by noting that many common features are not supported out of the box in Node.js and must be added through external modules.
What is Google Cloud Good For at DevFestInspire 2021Robert John
My presentation at DevFestLagos on "What is Google Cloud Good For". It's an overview of the Google Cloud Platform for those unfamiliar with it. You can watch the session here: https://www.youtube.com/watch?v=wi-p8fqFLrU
This document discusses security test automation. It provides examples of unit tests, static code analysis, and dynamic code analysis to test for vulnerabilities like XSS, input validation, TLS configuration, and known library vulnerabilities. Testing HTTP interactions, TLS settings, and library dependencies can be done programmatically through tools like RestAssured, SSL Labs, and OWASP Dependency Check. Automating security tests is important for projects to help ensure requirements are met continuously.
FabLab Bassa Romagna e ImoLUG nell'ambito del gruppo di lavoro su Linux, organizzano una serata dedicata alla Sicurezza Informatica; è un tema attuale, importante, ma molto sottovalutato.
Nella serata illustreremo come è possibile costruire un proprio Hacking Lab per imparare e testare localmente i principali software di IT Security. Sfrutteremo pertanto l'ambiente di virtualizzazione ProxMox per virtualizzare il sistema operativo vulnerabile Metaspoitable, sistema sviluppato dalla nota Radid7. Grazie a BackBox Linux analizzeremo la distribuzione vulnerabile alla ricerca di dettagli e di exploit da sfruttare.
Policy as code what helm developers need to know about securityLibbySchulze
1) The document discusses a 3 step process for securing Helm charts: define security requirements, use policy as code to encode the requirements, and implement guardrails like scans to ensure the requirements are met.
2) It provides examples of writing Rego policy that checks for secrets in environment variables, privilege escalation settings, and running as root.
3) Tools like Terrascan can scan Helm charts and infrastructure as code for policy violations and be integrated into CI/CD pipelines to prevent insecure configurations from being deployed.
Positive Technologies - S4 - Scada under x-raysqqlan
This document summarizes a presentation given by Sergey Gordeychik, Gleb Gritsai, and Denis Baranov on analyzing the security of WinCC SCADA software. It introduces the presenters and their backgrounds in industrial control system security research. They discuss common vulnerabilities found in WinCC like SQL injection, XSS, and password disclosure. The researchers provide an overview of the WinCC architecture and its various components. They analyze vulnerabilities in the WinCC project files and communication protocols. The presentation aims to bring more attention to automating security assessments of industrial control systems.
Kharkivpy#3: Javascript and Python backendMax Klymyshyn
The document discusses managing assets like JavaScript, CSS, and templates for web projects. It recommends adding asset management tools to define conventions and bundle assets. This improves the maintainability of code and makes it easier to manage dependencies and test updates. It also covers techniques like bundling browser-specific assets, using Sass/SCSS for stylesheets, and deploying assets to a CDN like Amazon CloudFront.
"Black Clouds and Silver Linings in Node.js Security" Liran TalJulia Cherniak
Remember eslint-scope and event-stream incidents? As an energetic member of the Node.js Foundation's Security Working Group, Liran will provide a 360 perspective of some black clouds of security horror stories in the JavaScript & Node.js ecosystem and educate on mitigating and building secure applications. We will deep-dive into practical Node.js vulnerabilities and how to protect against them, and cover some of OWASP Top 10. Liran will also introduce initiatives the Node.js Security WG have been undertaking to secure the ecosystem and recent security updates in npm.
The document discusses techniques used by SiliconAccess to manage chip design data and resources across multiple sites. It describes adopting principles from total quality management and the capability maturity model. The key techniques involved adaptive resource management of storage, computing and tools, as well as establishing a process for qualified data exchange between teams. These practices helped SiliconAccess successfully design complex chips on schedule despite challenges of multi-site teams and rapidly growing data volumes.
1. The document demonstrates how to use various AWS services like Kinesis, Redshift, Elasticsearch to analyze streaming game log data.
2. It shows setting up an EC2 instance to generate logs, creating a Kinesis stream to ingest the logs, and building Redshift tables to run queries on the logs.
3. The document also explores loading the logs from Kinesis into Elasticsearch for search and linking Kinesis and Redshift with Kinesis Analytics for real-time SQL queries on streams.
Derek Willian Stavis (Pagar.me)
Todo mundo diz que Webpack é só um module bundler. Mas o que é um módulo? O que é um bundler? Porque precisamos disso? Vamos caminhar pela história do desenvolvimento web para entender estes conceitos, e no final vamos dissecar a configuração e o output do Webpack para entendermos como ele funciona e como ele pode facilitar o seu processo de desenvolvimento.
Vale do Carbono Conference
Webpack is just a module bundler, they said. What they didn't say is why we need it, and what was the motivation that made us achieve what Webpack have been doing for us. In this talk we will navigate through the years of front-end development, ranging from 2003 to nowadays to understand this, and in the end, we will walk thought a complete Webpack project to understand how it works.
These are slides from a class I presented alumni and incoming students at the Austin Center for Design. The goal was to provide an over view of software application development (architecture, languages, frameworks), how to augment your development with other people of shops, and some basic techniques for scaling up.
The document discusses security best practices for Node.js applications. It covers using packages like Helmet to set secure HTTP headers, encrypting sessions with packages like cookie-session, preventing XSS attacks with csurf, sanitizing user input with express-validator, and encrypting passwords with bcrypt. It also discusses building secure HTTPS servers, analyzing dependencies for vulnerabilities with tools like NSP and Snyk, and using the Node Goat project to intentionally introduce vulnerabilities for testing security.
Practical Approaches to Cloud Native SecurityKarthik Gaekwad
Karthik Gaekwad presented on practical approaches to cloud native security. He discussed reducing the attack surface by securing hosts, container images, and the Kubernetes cluster. He highlighted security features in Kubernetes like secrets, authentication, authorization, audit logging, network policies, and pod security policies. Gaekwad also recommended using open source tooling to help with security and provided examples like Open Policy Agent.
Introduction to Grunt.js on Taiwan JavaScript ConferenceBo-Yi Wu
This document provides an overview of popular front-end development tools, including Node Version Manager (nvm) for managing Node.js versions, Bower for package management, CoffeeScript for compiling JavaScript, Compass for compiling CSS, RequireJS for module management, and Livereload for live reloading during development. It recommends using Grunt as a task runner to integrate these tools, describing how to configure Grunt plugins for Bower, CoffeeScript, and Compass.
DevOOPS: Attacks and Defenses for DevOps ToolchainsChris Gates
DevOps toolchains are transforming modern IT, but hackers can undermine their benefits through poorly implemented or vulnerable DevOps tools. Chris Gates and Ken Johnson will share their collaborative attack research into the technology driving DevOps. They will share an attacker's perspective on exploiting DevOps organizations and the countermeasures these organizations should employ.
RSAC 2017
Ken Johnson & Chris Gates
Slides for the PromCon presentation "Securing Prometheus. Lessons Learned From OpenShift"
https://promcon.io/2022-munich/talks/securing-prometheus-lessons-lear/
This document summarizes a presentation on XSS filters versus payloads. It discusses how XSS remains a prevalent web vulnerability despite various filters. The presentation covers XSS payload techniques like randomization and camouflaging, as well as how filters use approaches like sanitization, parameter filtering, and regular expressions that can be bypassed. It emphasizes that the arms race between filters and payloads will continue as each evolves over time.
This document provides an overview of MySQL Cluster architecture, maintenance, and support. It discusses the core architecture including data distribution across nodes, features like high availability and scalability, and the cluster structure with management, data, and SQL nodes. It also covers configuration files, database partitioning, basic administration functions like starting and stopping nodes, replication demonstrations, logging, backup and restore processes, and monitoring tools.
The document discusses frustrations experienced using Scala in a large project that ported a Java web application to Scala, including long compilation times, issues with ScalaIDE and sbt, and limitations of frameworks like Anorm; it then provides solutions the author developed to address these challenges, such as libraries to improve validation, ORM usage, and integration with Play frameworks.
Topics covered in this presentation, which was used for user group meetings, conferences & webinars:
1. Galera Cluster for MySQL - overview
2. Release 3 New Features:
* WAN Replication
* 5.6 Global Transaction ID (GTID) Support
* MySQL Replication Support
* and more features
3. The Galera Cluster Project
This document discusses the history and development of Docker. It notes that Docker was originally created at dotCloud as the engine for their Platform as a Service (PaaS), but in 2013 as PaaS times were hard, Docker was open sourced. Docker was based on LXC and created for a single purpose. dotCloud then pivoted to create Docker Inc. and make Docker their main product. The document also discusses Docker 1.11's integration with runC and systemd, as well as the transition to using the Open Container Initiative specification.
Programowanie AWSa z CLI, boto, Ansiblem i libcloudemMaciej Lasyk
The document describes a session that demonstrates how to program AWS using the AWS CLI, Boto, and Ansible. It provides an agenda for the session that includes a short AWS introduction, demonstrations of the AWS console, AWS CLI, AWS shell, Boto library, Ansible configuration management tool, and Libcloud library. Contact information is also provided for learning more about AWS programming and joining the training organization.
This document discusses Linux security and SELinux. It provides an overview of SELinux and how it works to provide mandatory access control on Linux systems. It discusses how SELinux labels processes and files to confine programs and prevent unauthorized access. It also discusses using SELinux with Docker containers to provide security isolation between containers.
Under the Dome (of failure driven pipeline)Maciej Lasyk
The document discusses various topics related to DevOps including:
1. Different types of shells (login, non-login, interactive, non-interactive, su, sudo su, sudo -i, sudo /bin/bash, sudo -s) and how they affect environment variables and profile files.
2. Stories of organizational "anti-types" that go against DevOps principles like not seeing the need for operations teams.
3. How automation, consistency, and reducing errors leads to stable environments and less unplanned work, allowing teams to focus on delivery.
This document discusses integrating security into DevOps practices through continuous delivery. It proposes including security automation and monitoring at each stage of the software development pipeline from development through production. Specific techniques mentioned include performing continuous security scanning, integrating security testing with other testing stages, automating security tasks using tools like Ansible, and sharing security data and lessons learned across teams to improve processes over time. The overall message is that security should be built into delivery rather than treated separately to avoid slowing software releases while still maintaining quality.
Orchestrating docker containers at scale (#DockerKRK edition)Maciej Lasyk
Slightly different version (original is here http://www.slideshare.net/d0cent/orchestrating-docker-containersatscale). This version was presented during first #Docker meetup in Kraków / Poland.
Orchestrating docker containers at scale (PJUG edition)Maciej Lasyk
Slightly changed version (original is here http://www.slideshare.net/d0cent/orchestrating-docker-containersatscale). This version was presented during Polish Java User Group meetup JavaCamp#13 in Kraków / Poland.
Orchestrating Docker containers at scaleMaciej Lasyk
Many of us already poked around Docker. Let's recap what we know and then think what do we know about scaling apps & whole environments which are Docker - based? Should we PaaS, IaaS or go with bare? Which tools to use on a given scale?
This document contains a list of various tools related to terminals, privacy, communication, productivity, and mobile topics. It discusses terminal emulators like guake and iterm2, VPN services like OpenVPN, messaging clients like IRC and XMPP, note taking apps like Evernote and Geeknote, and more. It concludes by inviting questions about any of the topics mentioned.
High Availability (HA) Explained - second editionMaciej Lasyk
I gave this talk at one of the biggest Linux conferences in Poland: 11 Liux Session that took place in Wrocław on 5/6-04-2014. It was a lightning talk covering subject of High Availability solutions, architecture, planning and deploying.
How could one create very sophisticated, open - source based monitoring solution that is very scalable and easy to deploy?
I gave this talk during on of the biggest Linux conferences in Poland: 11 Linux Session which took place in Wrocław on 5/6-04-2013
Is Red Hat / Fedora / Centos ready for lightweight Docker containers? Is Docker secure enough? How about SELinux? How could we deploy Jboss or Django within Docker / RHEL?
I gave this talk at DevOPS meetup in Krakow at 2014-02-26.
I gave this talk at Krakow/Poland DevOPS meetup. It was a lightning talk covering subject of High Availability solutions, architecture, planning and deploying.
How to run system administrator recruitment process? By creating platform based on open source parts in just 2 nights! I gave this talk in Poland / Kraków OWASP chapter meeting on 17th Octomber 2013 at our local Google for Entrepreneurs site. It's focused on security and also shows how to create recruitment process in CTF / challenge way.
This story covers mostly security details of this whole platform. There's great chance, that I will give another talk about this system but this time focusing on technical details. Stay tuned ;)
How to run system administrator recruitment process? By creating platform based on open source parts in just 2 nights! I gave this talk in Poland / Kraków OWASP chapter meeting on 17th October 2013 at our local Google for Entrepreneurs site. It's focused on security and also shows how to create recruitment process in CTF / challenge way.
This story covers mostly security details of this whole platform. There's great chance, that I will give another talk about this system but this time focusing on technical details. Stay tuned ;)
Generative Artificial Intelligence (GenAI) in BusinessDr. Tathagat Varma
My talk for the Indian School of Business (ISB) Emerging Leaders Program Cohort 9. In this talk, I discussed key issues around adoption of GenAI in business - benefits, opportunities and limitations. I also discussed how my research on Theory of Cognitive Chasms helps address some of these issues
Andrew Marnell: Transforming Business Strategy Through Data-Driven InsightsAndrew Marnell
With expertise in data architecture, performance tracking, and revenue forecasting, Andrew Marnell plays a vital role in aligning business strategies with data insights. Andrew Marnell’s ability to lead cross-functional teams ensures businesses achieve sustainable growth and operational excellence.
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Impelsys Inc.
Impelsys provided a robust testing solution, leveraging a risk-based and requirement-mapped approach to validate ICU Connect and CritiXpert. A well-defined test suite was developed to assess data communication, clinical data collection, transformation, and visualization across integrated devices.
TrsLabs - Fintech Product & Business ConsultingTrs Labs
Hybrid Growth Mandate Model with TrsLabs
Strategic Investments, Inorganic Growth, Business Model Pivoting are critical activities that business don't do/change everyday. In cases like this, it may benefit your business to choose a temporary external consultant.
An unbiased plan driven by clearcut deliverables, market dynamics and without the influence of your internal office equations empower business leaders to make right choices.
Getting things done within a budget within a timeframe is key to Growing Business - No matter whether you are a start-up or a big company
Talk to us & Unlock the competitive advantage
AI Changes Everything – Talk at Cardiff Metropolitan University, 29th April 2...Alan Dix
Talk at the final event of Data Fusion Dynamics: A Collaborative UK-Saudi Initiative in Cybersecurity and Artificial Intelligence funded by the British Council UK-Saudi Challenge Fund 2024, Cardiff Metropolitan University, 29th April 2025
https://alandix.com/academic/talks/CMet2025-AI-Changes-Everything/
Is AI just another technology, or does it fundamentally change the way we live and think?
Every technology has a direct impact with micro-ethical consequences, some good, some bad. However more profound are the ways in which some technologies reshape the very fabric of society with macro-ethical impacts. The invention of the stirrup revolutionised mounted combat, but as a side effect gave rise to the feudal system, which still shapes politics today. The internal combustion engine offers personal freedom and creates pollution, but has also transformed the nature of urban planning and international trade. When we look at AI the micro-ethical issues, such as bias, are most obvious, but the macro-ethical challenges may be greater.
At a micro-ethical level AI has the potential to deepen social, ethnic and gender bias, issues I have warned about since the early 1990s! It is also being used increasingly on the battlefield. However, it also offers amazing opportunities in health and educations, as the recent Nobel prizes for the developers of AlphaFold illustrate. More radically, the need to encode ethics acts as a mirror to surface essential ethical problems and conflicts.
At the macro-ethical level, by the early 2000s digital technology had already begun to undermine sovereignty (e.g. gambling), market economics (through network effects and emergent monopolies), and the very meaning of money. Modern AI is the child of big data, big computation and ultimately big business, intensifying the inherent tendency of digital technology to concentrate power. AI is already unravelling the fundamentals of the social, political and economic world around us, but this is a world that needs radical reimagining to overcome the global environmental and human challenges that confront us. Our challenge is whether to let the threads fall as they may, or to use them to weave a better future.
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfSoftware Company
Explore the benefits and features of advanced logistics management software for businesses in Riyadh. This guide delves into the latest technologies, from real-time tracking and route optimization to warehouse management and inventory control, helping businesses streamline their logistics operations and reduce costs. Learn how implementing the right software solution can enhance efficiency, improve customer satisfaction, and provide a competitive edge in the growing logistics sector of Riyadh.
This is the keynote of the Into the Box conference, highlighting the release of the BoxLang JVM language, its key enhancements, and its vision for the future.
Dev Dives: Automate and orchestrate your processes with UiPath MaestroUiPathCommunity
This session is designed to equip developers with the skills needed to build mission-critical, end-to-end processes that seamlessly orchestrate agents, people, and robots.
📕 Here's what you can expect:
- Modeling: Build end-to-end processes using BPMN.
- Implementing: Integrate agentic tasks, RPA, APIs, and advanced decisioning into processes.
- Operating: Control process instances with rewind, replay, pause, and stop functions.
- Monitoring: Use dashboards and embedded analytics for real-time insights into process instances.
This webinar is a must-attend for developers looking to enhance their agentic automation skills and orchestrate robust, mission-critical processes.
👨🏫 Speaker:
Andrei Vintila, Principal Product Manager @UiPath
This session streamed live on April 29, 2025, 16:00 CET.
Check out all our upcoming Dev Dives sessions at https://community.uipath.com/dev-dives-automation-developer-2025/.
Linux Support for SMARC: How Toradex Empowers Embedded DevelopersToradex
Toradex brings robust Linux support to SMARC (Smart Mobility Architecture), ensuring high performance and long-term reliability for embedded applications. Here’s how:
• Optimized Torizon OS & Yocto Support – Toradex provides Torizon OS, a Debian-based easy-to-use platform, and Yocto BSPs for customized Linux images on SMARC modules.
• Seamless Integration with i.MX 8M Plus and i.MX 95 – Toradex SMARC solutions leverage NXP’s i.MX 8 M Plus and i.MX 95 SoCs, delivering power efficiency and AI-ready performance.
• Secure and Reliable – With Secure Boot, over-the-air (OTA) updates, and LTS kernel support, Toradex ensures industrial-grade security and longevity.
• Containerized Workflows for AI & IoT – Support for Docker, ROS, and real-time Linux enables scalable AI, ML, and IoT applications.
• Strong Ecosystem & Developer Support – Toradex offers comprehensive documentation, developer tools, and dedicated support, accelerating time-to-market.
With Toradex’s Linux support for SMARC, developers get a scalable, secure, and high-performance solution for industrial, medical, and AI-driven applications.
Do you have a specific project or application in mind where you're considering SMARC? We can help with Free Compatibility Check and help you with quick time-to-market
For more information: https://www.toradex.com/computer-on-modules/smarc-arm-family
How Can I use the AI Hype in my Business Context?Daniel Lehner
𝙄𝙨 𝘼𝙄 𝙟𝙪𝙨𝙩 𝙝𝙮𝙥𝙚? 𝙊𝙧 𝙞𝙨 𝙞𝙩 𝙩𝙝𝙚 𝙜𝙖𝙢𝙚 𝙘𝙝𝙖𝙣𝙜𝙚𝙧 𝙮𝙤𝙪𝙧 𝙗𝙪𝙨𝙞𝙣𝙚𝙨𝙨 𝙣𝙚𝙚𝙙𝙨?
Everyone’s talking about AI but is anyone really using it to create real value?
Most companies want to leverage AI. Few know 𝗵𝗼𝘄.
✅ What exactly should you ask to find real AI opportunities?
✅ Which AI techniques actually fit your business?
✅ Is your data even ready for AI?
If you’re not sure, you’re not alone. This is a condensed version of the slides I presented at a Linkedin webinar for Tecnovy on 28.04.2025.
#StandardsGoals for 2025: Standards & certification roundup - Tech Forum 2025BookNet Canada
Book industry standards are evolving rapidly. In the first part of this session, we’ll share an overview of key developments from 2024 and the early months of 2025. Then, BookNet’s resident standards expert, Tom Richardson, and CEO, Lauren Stewart, have a forward-looking conversation about what’s next.
Link to recording, transcript, and accompanying resource: https://bnctechforum.ca/sessions/standardsgoals-for-2025-standards-certification-roundup/
Presented by BookNet Canada on May 6, 2025 with support from the Department of Canadian Heritage.
Role of Data Annotation Services in AI-Powered ManufacturingAndrew Leo
From predictive maintenance to robotic automation, AI is driving the future of manufacturing. But without high-quality annotated data, even the smartest models fall short.
Discover how data annotation services are powering accuracy, safety, and efficiency in AI-driven manufacturing systems.
Precision in data labeling = Precision on the production floor.
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungenpanagenda
Webinar Recording: https://www.panagenda.com/webinars/hcl-nomad-web-best-practices-und-verwaltung-von-multiuser-umgebungen/
HCL Nomad Web wird als die nächste Generation des HCL Notes-Clients gefeiert und bietet zahlreiche Vorteile, wie die Beseitigung des Bedarfs an Paketierung, Verteilung und Installation. Nomad Web-Client-Updates werden “automatisch” im Hintergrund installiert, was den administrativen Aufwand im Vergleich zu traditionellen HCL Notes-Clients erheblich reduziert. Allerdings stellt die Fehlerbehebung in Nomad Web im Vergleich zum Notes-Client einzigartige Herausforderungen dar.
Begleiten Sie Christoph und Marc, während sie demonstrieren, wie der Fehlerbehebungsprozess in HCL Nomad Web vereinfacht werden kann, um eine reibungslose und effiziente Benutzererfahrung zu gewährleisten.
In diesem Webinar werden wir effektive Strategien zur Diagnose und Lösung häufiger Probleme in HCL Nomad Web untersuchen, einschließlich
- Zugriff auf die Konsole
- Auffinden und Interpretieren von Protokolldateien
- Zugriff auf den Datenordner im Cache des Browsers (unter Verwendung von OPFS)
- Verständnis der Unterschiede zwischen Einzel- und Mehrbenutzerszenarien
- Nutzung der Client Clocking-Funktion
Book industry standards are evolving rapidly. In the first part of this session, we’ll share an overview of key developments from 2024 and the early months of 2025. Then, BookNet’s resident standards expert, Tom Richardson, and CEO, Lauren Stewart, have a forward-looking conversation about what’s next.
Link to recording, presentation slides, and accompanying resource: https://bnctechforum.ca/sessions/standardsgoals-for-2025-standards-certification-roundup/
Presented by BookNet Canada on May 6, 2025 with support from the Department of Canadian Heritage.
Drupalcamp Finland – Measuring Front-end Energy ConsumptionExove
Node.js security
1. Maciej Lasyk, node.js security
Maciej Lasyk
SEConference
Kraków, 2014-05-09
node.js security
2. Sysadmin about node.js security?
- not only sysadmin ;)
- node needs thorough understanding of whole infra
- 14+ years of exp software dev. / sysop
- currently “noding” 4 prv & Fedora
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
3. JS security recap – evals & co
eval() like fncs takes string argument and
evalute those as source code
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
4. JS security recap – evals & co
eval() like fncs takes string argument and
evalute those as source code
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
srsly – who does that?
Maciej Lasyk, node.js security
5. JS security recap – evals & co
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var x = req.body.x;
var y = req.body.y;
var sum = eval(a + "+" + b);
Maciej Lasyk, node.js security
6. JS security recap – evals & co
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var x = req.body.x;
var y = req.body.y;
var sum = eval(a + "+" + b);
what if attacker fills 'x' with:
some.super.class.wipe.the.database('now');
LOL :)
Maciej Lasyk, node.js security
7. JS security recap – evals & co
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
not only evals:
setInterval(code,2)
setTimeout(code,2)
str = new Function(code)
Chrome CSP denies those also :)
Maciej Lasyk, node.js security
8. JS security recap – global namespace pollution
- node.js is single threaded
- all variable values are common
- one could thrtically change bhv of others reqs
- watch out for globals then!
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
9. JS security recap – global namespace pollution
some very awful example:
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var auth = false;
app.get('/auth', function(req, res) {
if(legit) { auth = true; res.send("success");
});
app.get('/payments-db', function(req, res) {
if (auth) res.send("legit to see all payments data");
else res.send("not logged in");
})
app.listen(8080);
Maciej Lasyk, node.js security
10. JS security recap – global namespace pollution
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
So now imagine..
global namespace pollution + evals & co
Maciej Lasyk, node.js security
11. JS security recap – global namespace pollution
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
So now imagine..
global namespace pollution + evals & co
Maciej Lasyk, node.js security
12. JS security recap – global namespace pollution
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
So now imagine..
global namespace pollution + evals & co
Watch out who you are hiring
Maciej Lasyk, node.js security
13. JS security recap – strict mode
- let's throw all errors!
- declare variables!
- global namespaces help
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
14. JS security recap – strict mode
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
"use strict";
function testFunction(){
var testvar = 4;
return testvar;
}
// This causes a syntax error.
testvar = 5;
Maciej Lasyk, node.js security
15. JS security recap – strict mode
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
// This causes a syntax error:
"use strict";
testvar = 5;
// This is ok:
"use strict";
var testvar = 0;
testvar = 5;
Maciej Lasyk, node.js security
16. JS security recap – strict mode
- evals & co are not that insecure now
- no access to caller and args props
- enable globally or for some scope
- what about strict mode in 3rd
party mods?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
17. JS security recap – strict mode
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
"use strict";
function do_smt() {
do_smt.caller; // no way :)
do_smt.arguments; // no way :)
}
Maciej Lasyk, node.js security
23. JS security recap – static code analysis
- If not doing it already – just do
- Commit hooks in (D)VCSes
- JSHint / JSLint
- Create policy for static code analysis
- Update & check this policy regularly
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
24. about node.js: what's up?
- current stable version 0.10.28
- who is using node?
https://github.com/joyent/node/wiki/Projects,-Applications,-and-Companies-Using-Node
- Operating Node.js in production/Bryan Cantrill (Joyent)
- Bill Scott,“Clash of the Titans: Kraken | Node.js @ paypal”
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
25. about node.js: model
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
26. about node.js: concurrency
- node.js is single threaded (let's say)
- multi – core? child processes (cluster.fork)
- Linux containers ftw!
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
27. about node.js: SPA
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
(thx Sekurak.pl for this image)
Maciej Lasyk, node.js security
30. node.js sec: exploits anyone?
- http://seclists.org/bugtraq – 0 hits
- http://osvdb.org – 2 hits
- http://1337day.com, http://www.exploitdb.com – 1 hit
- http://nodesecurity.io/advisories – 4 hits
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Such security big?
not exactly
Maciej Lasyk, node.js security
31. node.js sec: what's wrong?
node.js security is a blank page
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
http://www.slideshare.net/ASF-WS/asfws-2012-nodejs-security-old-vulnerabilities-in-new-dresses-par-sven-vetsch
Maciej Lasyk, node.js security
32. node.js sec: how does sec look like?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
33. node.js sec: how does sec look like?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Such security..Such security..
Very fortress!!1Very fortress!!1
WOW :)WOW :)
Maciej Lasyk, node.js security
34. node.js sec: exceptions / callbacks
callbacks Error object – remember to handle those
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var fs = require("fs");
fs.readFile("/some/file", "utf8", function (err, contents) {
// err will be null if no error occured
// ... otherwise there will be info about error
});
forget about handling and die debugging
Maciej Lasyk, node.js security
35. node.js sec: exceptions / eventemitter
EventEmitter: emitting events 4 async actions
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var http = require("http");
http.get("http://nodejs.org/", function (res) {
res.on("data", function (chunk) {
do_something_with_chunk;
});
res.on("error", function (err) {
// listener handling error
});
});
Attach listeners to errors events or
welcome unhandled exception!
Maciej Lasyk, node.js security
36. node.js sec: uncaught exceptions
- by default node.js will print stack trace and terminate thread
- EventEmitter / process / uncaughtException
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
// it looks like this by default:
process.on("uncaughtException", function (err) {
console.error(err);
console.trace();
process.exit();
});
Maciej Lasyk, node.js security
37. node.js sec: uncaught exceptions
- by default node.js will print stack trace and terminate thread
- EventEmitter / process / uncaughtException
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
// it looks like this by default:
process.on("uncaughtException", function (err) {
console.error(err);
console.trace();
process.exit();
});
So do you really want to comment out the 'process.exit()' line?
Maciej Lasyk, node.js security
38. node.js sec: clusters
scaling within multi-core envs
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var cluster = require('cluster');
var http = require('http');
var numCPUs = require('os').cpus().length;
if (cluster.isMaster) {
for (var i = 0; i < numCPUs; i++) {
cluster.fork();
}
cluster.on('exit', function(worker, code, signal) {
console.log(worker.process.pid + ' died');
});
} else {
http.createServer(function(req, res) {
res.writeHead(200);
res.end("hello worldn");
}).listen(8000);
}
Maciej Lasyk, node.js security
39. node.js sec: domains
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Handling multiple different IO operations as a single group
// don't do that:
var d = require('domain').create();
d.on('error', function(er) {
console.log('error, but oh well', er.message);
});
d.run(function() {
require('http').createServer(function(req, res) {
handleRequest(req, res);
}).listen(PORT);
});
Maciej Lasyk, node.js security
40. node.js sec: domains
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Rather use cluster & forks and exit gently..:
create_cluster;
fork_workers;
if(worker){
var domain = require('domain');
var server = require('http').createServer(function(req, res) {
var d = domain.create();
d.on('error', function(er) {
console.error('error', er.stack);
try {
// set timeout timer
// update master && print err msg
// close server
} catch (er2) { console.error('Error 500!', er2.stack); }
}
Maciej Lasyk, node.js security
41. node.js sec: domains
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Using Express take look at that:
https://github.com/brianc/node-domain-middleware
Assigning each Express request to a separate domain?
Maciej Lasyk, node.js security
42. node.js sec: npm modules
- npm install (-g)
- who creates modules?
- who verifies those?
- how to update?
- semantic versioning in package.json
- "connect":"~1.8.7" -> 1.8.7 - 1.9
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
44. node.js sec: npm modules
The scale of npm modules
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
45. node.js sec: npm modules
Comparison to other langs (mods/day):
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
46. node.js sec: npm modules
Remember:
- use strict?
- static analysis?
- does include some test suite?
- what is the dependency tree?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
47. node.js.express: connect / express
Express – web dev framework
Built on top of connect
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
48. node.js.express: auth.basic_auth
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
var express = require('express'),
app = express();
app.use(express.basicAuth("user", "pwd"));
app.get("/", function (req, res) {
res.send('Hello World');
});
app.listen(8080);
Plain text and simple auth issues
Maciej Lasyk, node.js security
62. node.js.CSI: XSS
- XSS allows to access cookies, session tokens etc
- or even redirect user to malicious sites
- Myth: frameworks / tpls does the anti-XSS job
- always encode untrusted data for correct context
- OWASP ESAPI
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
63. node.js.CSI: DoS
- Error handling
- Use streams / chunking
- Use monitoring
- Use domains / clusters
- Don't be afraid of SlowLoris :)
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
64. node.js.CSI: ReDoS
- Regex could take exponential execution time
- Is regex executed in the event loop thread?
- Regex and user input?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
https://speakerdeck.com/ckarande/top-overlooked-security-threats-to-node-dot-js-web-applications
Maciej Lasyk, node.js security
65. node.js.CSI: HPP
HTTP Parameter Pollution
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
// POST firstName=John&firstName=John
req.body.color
//=> [“John”, “John”]
Maciej Lasyk, node.js security
66. node.js.CSI: HPP
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
Modify app behavior:
Maciej Lasyk, node.js security
67. node.js.CSI: HPP
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25
- TypeErrors, uncaught errs->DoS,
- Check the expected type in the input validation
- Input fuzzing / test suites
- try/catch, domains, clusters
Maciej Lasyk, node.js security
73. node.js.CSI: request_size
Just set limits
use streams instead of buffering
And request size:
app.use(express.limit("5mb"));
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
74. node.js.CSI: environment.monitoring
- is app functional? :)
- is app overloaded?
- app should provide monitoring interface
- how many errors caught?
- are forks alive and OK?
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security
75. node.js.CSI: environment.resources
- node.js will eat ;)
- use control groups || containers
- monitor resources usage
Maciej Lasyk, Ganglia & Nagios 3/25Maciej Lasyk, node.js security 1/25Maciej Lasyk, node.js security