SlideShare ist ein Scribd-Unternehmen logo
1 von 113
LET’S WRITE SECURE DRUPAL
CODE!
TATAR BALAZS JANOS
DRUPAL CAMP POLAND
WROCLAW, POLAND – 01.06.2019
Who am I?
Tatar Balazs Janos
@tatarbj
Works with Drupal since 2007
CTO @ Petend
Drupal Security Correspondent @ EC
Active mentor @ Mentoring community group
Provisional member @ Drupal Security Team
SecOSdreamer @ Secure Open Source day
Tatar Balazs Janos - @tatarbj
Are there site builders?
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Demo
Tatar Balazs Janos - @tatarbj
Gist
https://gist.github.com/tatarbj/4aa90ba303938aa59969fcf06323f8d1
Tatar Balazs Janos - @tatarbj
Are there developers/maintainers?
Tatar Balazs Janos - @tatarbj
Have you attended on a previous Let’s
write secure Drupal code! session?
Tatar Balazs Janos - @tatarbj
DrupalCamp Antwerp 2017
DrupalCamp Ruhr 2018
DrupalDevDays 2018
Drupal Europe 2018
DrupalCamp Oslo 2018
DrupalCamp London 2019
Drupal Mountain Camp 2019
DrupalCamp Spain 2019
DrupalCamp Belarus 2019
DrupalCamp Kyiv 2019
DrupalCamp Poland 2019
History
Tatar Balazs Janos - @tatarbj
Trends in Security
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Types of vulnerabilities
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Cross Site Scripting
Tatar Balazs Janos - @tatarbj
Client side vulnerability
Unfiltered output
Never trust any user input.
We’ve seen the demo before ;)
Cross Site Scripting
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Html::escape() – plain text
Xss::filter() – html is allowed
Xss::filterAdmin() – text by admins
Tatar Balazs Janos - @tatarbj
Bingo
Tatar Balazs Janos - @tatarbj
Everyone has a bingo card (check your bag!)
If you answer well, mark the number!
Wrong answer = no number!
First who shouts BINGO! wins the price!
Rules and etiquette
Tatar Balazs Janos - @tatarbj
Round 1
Tatar Balazs Janos - @tatarbj
function custom_field_formatter_view(...) {
foreach ($items as $key => $value) {
//...
$element[$key] = array(
'#type' => 'markup',
'#markup' => t('<img src="!src" alt="@alt" />',
array('!src' => $value['src'], ‚$alt’ => $value['alt'])),
);
//...
}
return $element;
}
Tatar Balazs Janos - @tatarbj
function custom_field_formatter_view(...) {
foreach ($items as $key => $value) {
//...
$element[$key] = array(
'#type' => 'markup',
'#markup' => t('<img src="!src" alt="@alt" />',
array('!src' => $value['src'], ‚$alt’ => $value['alt'])),
);
//...
}
return $element;
}
Tatar Balazs Janos - @tatarbj
function custom_field_formatter_view(...) {
foreach ($items as $key => $value) {
//...
$element[$key] = array(
'#type' => 'markup',
'#markup' => t('<img src="@src" alt="@alt" />',
array('@src' => $value['src'], ‚$alt’ => $value['alt'])),
);
//...
}
return $element;
}
Tatar Balazs Janos - @tatarbj
12
Tatar Balazs Janos - @tatarbj
foreach ($items as $delta => $item) {
$id = $item->getValue()['target_id'];
$content = Drupal::entityTypeManager()
->getStorage($entity_type_id)
->load($id);
$body = $content->get('body_field')->getValue()[0]['value'];
}
$elements[$delta] = array(
'#theme' => 'something_custom',
'#body' => $body,
);
return $elements;
Tatar Balazs Janos - @tatarbj
foreach ($items as $delta => $item) {
$id = $item->getValue()['target_id'];
$content = Drupal::entityTypeManager()
->getStorage($entity_type_id)
->load($id);
$body = $content->get('body_field')->getValue()[0]['value'];
}
$elements[$delta] = array(
'#theme' => 'something_custom',
'#body' => $body,
);
return $elements;
Tatar Balazs Janos - @tatarbj
foreach ($items as $delta => $item) {
$id = $item->getValue()['target_id'];
$content = Drupal::entityTypeManager()
->getStorage($entity_type_id)
->load($id);
$body = [
'#type' => 'processed_text',
'#text' => $content->get('body_field')->getValue()[0]['value'],
'#format' => $content->get('body_field')->getValue()[0]['format'], ];
}
$elements[$delta] = array(
'#theme' => 'something_custom',
'#body' => $body,
);
return $elements;
Tatar Balazs Janos - @tatarbj
23
Tatar Balazs Janos - @tatarbj
In Drupal 7 check_url calls check_plain
to sanitize bad protocols properly.
?
Tatar Balazs Janos - @tatarbj
In Drupal 7 check_url calls check_plain
to sanitize bad protocols properly.
?
Tatar Balazs Janos - @tatarbj
In Drupal 7 check_url calls
drupal_dangerous_protocols to
sanitize bad protocols properly.
?
Tatar Balazs Janos - @tatarbj
25
Tatar Balazs Janos - @tatarbj
Drupal 8 allows Full HTML to be used
by authenticated and administrator
users.
?
Tatar Balazs Janos - @tatarbj
Drupal 8 allows Full HTML to be used
by authenticated and administrator
users.
?
Tatar Balazs Janos - @tatarbj
17
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Use behat/automated tests.
<script>alert('XSS')</script>
<img src="a" onerror="alert('title')">
Check your filters and user roles.
Do not give too many options to untrusted users!
Protection against Cross Site Scripting
Tatar Balazs Janos - @tatarbj
Access Bypass
Tatar Balazs Janos - @tatarbj
User can access/do something.
Menu items can be defined to be
accessed/denied.
Many access systems: node, entity, field, views...
Access bypass
Tatar Balazs Janos - @tatarbj
Round 2
Tatar Balazs Janos - @tatarbj
<?php
$query = db_select('node', 'n')
->fields('n', array('title', 'nid'))
->condition('type', 'article');
$result = $query->execute();
?>
Tatar Balazs Janos - @tatarbj
<?php
$query = db_select('node', 'n')
->fields('n', array('title', 'nid'))
->condition('type', 'article');
$result = $query->execute();
?>
Tatar Balazs Janos - @tatarbj
<?php
$query = db_select('node', 'n')
->fields('n', array('title', 'nid')
->condition('type', 'article')
->addTag('node_access');
$result = $query->execute();
?>
Tatar Balazs Janos - @tatarbj
29
Tatar Balazs Janos - @tatarbj
mymodule.not_found:
path: '/not-found'
defaults:
_controller: 'DrupalmymoduleControllerNotFoundController::build404'
_title: 'Page not found'
requirements:
_access: 'TRUE'
Tatar Balazs Janos - @tatarbj
mymodule.not_found:
path: '/not-found'
defaults:
_controller: 'DrupalmymoduleControllerNotFoundController::build404'
_title: 'Page not found'
requirements:
_access: 'TRUE'
Tatar Balazs Janos - @tatarbj
16
Tatar Balazs Janos - @tatarbj
Restricted permissions make Drupal
sites more secure by calling
restrict_permission() method.
?
Tatar Balazs Janos - @tatarbj
Restricted permissions make Drupal
sites more secure by calling
restrict_permission() method.
?
Tatar Balazs Janos - @tatarbj
Restricted permissions make Drupal
sites more secure by raising
attention on the permission page.
?
Tatar Balazs Janos - @tatarbj
6
Tatar Balazs Janos - @tatarbj
A standard Drupal 8 allows users to
mistype their passwords 10 times.
?
Tatar Balazs Janos - @tatarbj
A standard Drupal 8 allows users to
mistype their passwords 10 times.
?
Tatar Balazs Janos - @tatarbj
A standard Drupal 8 allows users to
mistype their passwords 5 times.
?
Tatar Balazs Janos - @tatarbj
9
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Visit node/nid and other urls
Visit anything/%node
Use behat/automated tests.
node_access, entity_access
Menu definitions
user_access for permissions
$query->addTag('node_access')
Protection against Access bypass
Tatar Balazs Janos - @tatarbj
SQL Injection
Tatar Balazs Janos - @tatarbj
Unauthorized access to database resources.
Do not trust any user input.
SA-CORE-2014-005 – Highly critical D7 SA
SQL Injection
Tatar Balazs Janos - @tatarbj
Round 3
Tatar Balazs Janos - @tatarbj
<?php
$result = Drupal::database()
->delete('people')
->condition('name', '%_' . $_GET['param'], 'LIKE');
->execute();
?>
Tatar Balazs Janos - @tatarbj
<?php
$result = Drupal::database()
->delete('people')
->condition('name', '%_' . $_GET['param'], 'LIKE');
->execute();
?>
Tatar Balazs Janos - @tatarbj
<?php
$database = Drupal::database();
$result = $database
->delete('people')
->condition('name', $database->escapeLike($_GET['param']), 'LIKE');
->execute();
?>
Tatar Balazs Janos - @tatarbj
31
Tatar Balazs Janos - @tatarbj
A highly critical Drupal 7 core update
remediated a Remote code execution
vulnerability in 2014.
?
Tatar Balazs Janos - @tatarbj
A highly critical Drupal 7 core update
remediated a Remote code execution
vulnerability in 2014.
?
Tatar Balazs Janos - @tatarbj
A highly critical Drupal 7 core update
remediated an SQL injection
vulnerability in 2014.
?
Tatar Balazs Janos - @tatarbj
15
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Use always drupal Database API!
db_query with :placeholder (deprecated in D8,
in D9 will be removed)
Filter parameters
Check the queries in code.
username' AND 1=1
POST requests by curl
Protection against SQL Injection
Tatar Balazs Janos - @tatarbj
Round 4
Ready for some other code?
Tatar Balazs Janos - @tatarbj
<?php
function _generate_password($length = 8) {
$pass = ’’;
for ($i = 0; $i < $length; $i++) {
// Each iteration, pick a random character from the
// allowable string and append it to the password:
$pass .= $allowable_characters[mt_rand(0, $len)];
}
}
?>
Tatar Balazs Janos - @tatarbj
<?php
function _generate_password($length = 8) {
$pass = ’’;
for ($i = 0; $i < $length; $i++) {
// Each iteration, pick a random character from the
// allowable string and append it to the password:
$pass .= $allowable_characters[mt_rand(0, $len)];
}
}
?>
Tatar Balazs Janos - @tatarbj
<?php
function _generate_password($length = 8) {
$pass = ’’;
for ($i = 0; $i < $length; $i++) {
do {
// Find a secure random number within the range needed.
$index = ord(drupal_random_bytes(1));
} while ($index > $len);
$pass .= $allowable_characters[$index];
}
}
?>
Tatar Balazs Janos - @tatarbj
8
Tatar Balazs Janos - @tatarbj
// custom_module.permissions.yml
administer custom module:
title: 'Bypass access control'
description: 'Allows a user to bypass access control.’
// custom_module.routing.yml
custom_module.settings.form:
path: '/admin/config/custom/settings'
requirements:
_permission: 'administer custom module'
Tatar Balazs Janos - @tatarbj
// custom_module.permissions.yml
administer custom module:
title: 'Bypass access control'
description: 'Allows a user to bypass access control.’
// custom_module.routing.yml
custom_module.settings.form:
path: '/admin/config/custom/settings'
requirements:
_permission: 'administer custom module'
Tatar Balazs Janos - @tatarbj
// custom_module.permissions.yml
administer custom module:
title: 'Bypass access control'
description: 'Allows a user to bypass access control.’
restrict access: TRUE
// custom_module.routing.yml
custom_module.settings.form:
path: '/admin/config/custom/settings'
requirements:
_permission: 'administer custom module'
Tatar Balazs Janos - @tatarbj
20
Tatar Balazs Janos - @tatarbj
// contrib_module.routing.yml
contrib_module.settings.form:
path: '/admin/config/contrib/settings'
requirements:
_permission: 'administer site configuration'
Tatar Balazs Janos - @tatarbj
// contrib_module.routing.yml
contrib_module.settings.form:
path: '/admin/config/contrib/settings'
requirements:
_permission: 'administer site configuration'
Tatar Balazs Janos - @tatarbj
26
Tatar Balazs Janos - @tatarbj
CSRF stands for Cross Site Remote
Fallout vulnerability.
?
Tatar Balazs Janos - @tatarbj
CSRF stands for Cross Site Remote
Fallout vulnerability.
?
Tatar Balazs Janos - @tatarbj
CSRF stands for Cross Site Request
Forgery vulnerability.
?
Tatar Balazs Janos - @tatarbj
32
Tatar Balazs Janos - @tatarbj
SQL Injection is a server side
vulnerability.
?
Tatar Balazs Janos - @tatarbj
SQL Injection is a server side
vulnerability.
?
Tatar Balazs Janos - @tatarbj
13
Tatar Balazs Janos - @tatarbj
Cross Site Scripting vulnerability is in
the TOP3 of OWASP list from 2017.
?
Tatar Balazs Janos - @tatarbj
Cross Site Scripting vulnerability is in
the TOP3 of OWASP list from 2017.
?
Tatar Balazs Janos - @tatarbj
Cross Site Scripting vulnerability is not
in the TOP3 of OWASP list from 2017,
but was in 2013.
?
Tatar Balazs Janos - @tatarbj
5
Tatar Balazs Janos - @tatarbj
In case of no winner,
extra numbers are coming!
!
Tatar Balazs Janos - @tatarbj
18
Tatar Balazs Janos - @tatarbj
27
Tatar Balazs Janos - @tatarbj
30
Tatar Balazs Janos - @tatarbj
1
Tatar Balazs Janos - @tatarbj
11
Tatar Balazs Janos - @tatarbj
33
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Security Improvements
Tatar Balazs Janos - @tatarbj
*https://events.drupal.org/sites/default/files/slides/pwolanin-2017-09-ways-drupal8-d.pdf
Many ways Drupal 8 is more secure!*
Twig templates for HTML generation
Removed PHP format
Site configuration exportable, versionable
User content entry and filtering improvements
User session and session always in ID handling
Automated CSRF token protection
Trusted host patterns enforced for requests
Single statement execution for SQL
Clickjacking protection
Content security policy compatibility with Core Javascript API
Tatar Balazs Janos - @tatarbj
Learn by Advisories
Tatar Balazs Janos - @tatarbj
Security advisories are for
 Only stable modules
 No alpha, beta, dev
 d.org hosted projects
@Maintainers: If you are contacted, be supportive! 
Drupal Security Team
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
Hacked!
Security review (simplytest.me)
Password policy
Encrypt
Composer Security Checker
Permission report
Drop Guard
Security Awareness programs
+ PHPCS Drupal BestPractice Sniff
Security related projects
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos - @tatarbj
SecOSdays
25-26 OCTOBER, 2019 - SOFIA, BULGARIA
Call For Sessions and Sponsors are open!
Tatar Balazs Janos - @tatarbj
Questions?
Tatar Balazs Janos - @tatarbj
Tatar Balazs Janos
@tatarbj
Thank you!

Weitere ähnliche Inhalte

Was ist angesagt?

Let's write secure Drupal code!
Let's write secure Drupal code!Let's write secure Drupal code!
Let's write secure Drupal code!Balázs Tatár
 
Drupal 8: Routing & More
Drupal 8: Routing & MoreDrupal 8: Routing & More
Drupal 8: Routing & Moredrubb
 
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, Germany
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, GermanyLet's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, Germany
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, GermanyBalázs Tatár
 
Redis for your boss 2.0
Redis for your boss 2.0Redis for your boss 2.0
Redis for your boss 2.0Elena Kolevska
 
Django - 次の一歩 gumiStudy#3
Django - 次の一歩 gumiStudy#3Django - 次の一歩 gumiStudy#3
Django - 次の一歩 gumiStudy#3makoto tsuyuki
 
SPL: The Missing Link in Development
SPL: The Missing Link in DevelopmentSPL: The Missing Link in Development
SPL: The Missing Link in Developmentjsmith92
 
Building Lithium Apps
Building Lithium AppsBuilding Lithium Apps
Building Lithium AppsNate Abele
 
Connecting Content Silos: One CMS, Many Sites With The WordPress REST API
 Connecting Content Silos: One CMS, Many Sites With The WordPress REST API Connecting Content Silos: One CMS, Many Sites With The WordPress REST API
Connecting Content Silos: One CMS, Many Sites With The WordPress REST APICaldera Labs
 
Intro to php
Intro to phpIntro to php
Intro to phpSp Singh
 
Php on the Web and Desktop
Php on the Web and DesktopPhp on the Web and Desktop
Php on the Web and DesktopElizabeth Smith
 
The Origin of Lithium
The Origin of LithiumThe Origin of Lithium
The Origin of LithiumNate Abele
 
Resource Routing in ExpressionEngine
Resource Routing in ExpressionEngineResource Routing in ExpressionEngine
Resource Routing in ExpressionEngineMichaelRog
 
Introduction to PHP Lecture 1
Introduction to PHP Lecture 1Introduction to PHP Lecture 1
Introduction to PHP Lecture 1Ajay Khatri
 
Undercover Pods / WP Functions
Undercover Pods / WP FunctionsUndercover Pods / WP Functions
Undercover Pods / WP Functionspodsframework
 
Php tips-and-tricks4128
Php tips-and-tricks4128Php tips-and-tricks4128
Php tips-and-tricks4128PrinceGuru MS
 
Keeping it Small: Getting to know the Slim Micro Framework
Keeping it Small: Getting to know the Slim Micro FrameworkKeeping it Small: Getting to know the Slim Micro Framework
Keeping it Small: Getting to know the Slim Micro FrameworkJeremy Kendall
 

Was ist angesagt? (20)

Let's write secure Drupal code!
Let's write secure Drupal code!Let's write secure Drupal code!
Let's write secure Drupal code!
 
Drupal 8: Routing & More
Drupal 8: Routing & MoreDrupal 8: Routing & More
Drupal 8: Routing & More
 
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, Germany
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, GermanyLet's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, Germany
Let's write secure Drupal code! - 13.09.2018 @ Drupal Europe, Darmstadt, Germany
 
Redis for your boss
Redis for your bossRedis for your boss
Redis for your boss
 
Redis for your boss 2.0
Redis for your boss 2.0Redis for your boss 2.0
Redis for your boss 2.0
 
Django - 次の一歩 gumiStudy#3
Django - 次の一歩 gumiStudy#3Django - 次の一歩 gumiStudy#3
Django - 次の一歩 gumiStudy#3
 
SPL: The Missing Link in Development
SPL: The Missing Link in DevelopmentSPL: The Missing Link in Development
SPL: The Missing Link in Development
 
Building Lithium Apps
Building Lithium AppsBuilding Lithium Apps
Building Lithium Apps
 
Apache Velocity 1.6
Apache Velocity 1.6Apache Velocity 1.6
Apache Velocity 1.6
 
Connecting Content Silos: One CMS, Many Sites With The WordPress REST API
 Connecting Content Silos: One CMS, Many Sites With The WordPress REST API Connecting Content Silos: One CMS, Many Sites With The WordPress REST API
Connecting Content Silos: One CMS, Many Sites With The WordPress REST API
 
Intro to php
Intro to phpIntro to php
Intro to php
 
WCLV13 JavaScript
WCLV13 JavaScriptWCLV13 JavaScript
WCLV13 JavaScript
 
Php My Sql
Php My SqlPhp My Sql
Php My Sql
 
Php on the Web and Desktop
Php on the Web and DesktopPhp on the Web and Desktop
Php on the Web and Desktop
 
The Origin of Lithium
The Origin of LithiumThe Origin of Lithium
The Origin of Lithium
 
Resource Routing in ExpressionEngine
Resource Routing in ExpressionEngineResource Routing in ExpressionEngine
Resource Routing in ExpressionEngine
 
Introduction to PHP Lecture 1
Introduction to PHP Lecture 1Introduction to PHP Lecture 1
Introduction to PHP Lecture 1
 
Undercover Pods / WP Functions
Undercover Pods / WP FunctionsUndercover Pods / WP Functions
Undercover Pods / WP Functions
 
Php tips-and-tricks4128
Php tips-and-tricks4128Php tips-and-tricks4128
Php tips-and-tricks4128
 
Keeping it Small: Getting to know the Slim Micro Framework
Keeping it Small: Getting to know the Slim Micro FrameworkKeeping it Small: Getting to know the Slim Micro Framework
Keeping it Small: Getting to know the Slim Micro Framework
 

Ähnlich wie Let's write secure Drupal code! - Drupal Camp Poland 2019

Let's write secure Drupal code! Drupal MountainCamp 2019
Let's write secure Drupal code! Drupal MountainCamp 2019Let's write secure Drupal code! Drupal MountainCamp 2019
Let's write secure Drupal code! Drupal MountainCamp 2019Balázs Tatár
 
Let's write secure Drupal code! - DrupalCamp Spain 2019
Let's write secure Drupal code! - DrupalCamp Spain 2019Let's write secure Drupal code! - DrupalCamp Spain 2019
Let's write secure Drupal code! - DrupalCamp Spain 2019Balázs Tatár
 
Let's write secure drupal code!
Let's write secure drupal code!Let's write secure drupal code!
Let's write secure drupal code!Balázs Tatár
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applicationselliando dias
 
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011Masahiro Nagano
 
Drupal - dbtng 25th Anniversary Edition
Drupal - dbtng 25th Anniversary EditionDrupal - dbtng 25th Anniversary Edition
Drupal - dbtng 25th Anniversary Editionddiers
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applicationselliando dias
 
Let's write secure Drupal code! - DrupalCamp London 2019
Let's write secure Drupal code! - DrupalCamp London 2019Let's write secure Drupal code! - DrupalCamp London 2019
Let's write secure Drupal code! - DrupalCamp London 2019Balázs Tatár
 
Drupal Development (Part 2)
Drupal Development (Part 2)Drupal Development (Part 2)
Drupal Development (Part 2)Jeff Eaton
 
LET’S WRITE SECURE DRUPAL CODE!
LET’S WRITE SECURE DRUPAL CODE!LET’S WRITE SECURE DRUPAL CODE!
LET’S WRITE SECURE DRUPAL CODE!DrupalCamp Kyiv
 
Let's write secure Drupal code! - DrupalCamp Kyiv 2019
Let's write secure Drupal code! - DrupalCamp Kyiv 2019Let's write secure Drupal code! - DrupalCamp Kyiv 2019
Let's write secure Drupal code! - DrupalCamp Kyiv 2019Balázs Tatár
 
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011camp_drupal_ua
 
The History of PHPersistence
The History of PHPersistenceThe History of PHPersistence
The History of PHPersistenceHugo Hamon
 
Why Hacking WordPress Search Isn't Some Big Scary Thing
Why Hacking WordPress Search Isn't Some Big Scary ThingWhy Hacking WordPress Search Isn't Some Big Scary Thing
Why Hacking WordPress Search Isn't Some Big Scary ThingChris Reynolds
 
How to work with legacy code PHPers Rzeszow #2
How to work with legacy code PHPers Rzeszow #2How to work with legacy code PHPers Rzeszow #2
How to work with legacy code PHPers Rzeszow #2Michał Kruczek
 
Open Source Search: An Analysis
Open Source Search: An AnalysisOpen Source Search: An Analysis
Open Source Search: An AnalysisJustin Finkelstein
 

Ähnlich wie Let's write secure Drupal code! - Drupal Camp Poland 2019 (20)

Let's write secure Drupal code! Drupal MountainCamp 2019
Let's write secure Drupal code! Drupal MountainCamp 2019Let's write secure Drupal code! Drupal MountainCamp 2019
Let's write secure Drupal code! Drupal MountainCamp 2019
 
Let's write secure Drupal code! - DrupalCamp Spain 2019
Let's write secure Drupal code! - DrupalCamp Spain 2019Let's write secure Drupal code! - DrupalCamp Spain 2019
Let's write secure Drupal code! - DrupalCamp Spain 2019
 
Let's write secure drupal code!
Let's write secure drupal code!Let's write secure drupal code!
Let's write secure drupal code!
 
Daily notes
Daily notesDaily notes
Daily notes
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applications
 
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011
Designing Opeation Oriented Web Applications / YAPC::Asia Tokyo 2011
 
Drupal - dbtng 25th Anniversary Edition
Drupal - dbtng 25th Anniversary EditionDrupal - dbtng 25th Anniversary Edition
Drupal - dbtng 25th Anniversary Edition
 
Intro to The PHP SPL
Intro to The PHP SPLIntro to The PHP SPL
Intro to The PHP SPL
 
PHP and Rich Internet Applications
PHP and Rich Internet ApplicationsPHP and Rich Internet Applications
PHP and Rich Internet Applications
 
Let's write secure Drupal code! - DrupalCamp London 2019
Let's write secure Drupal code! - DrupalCamp London 2019Let's write secure Drupal code! - DrupalCamp London 2019
Let's write secure Drupal code! - DrupalCamp London 2019
 
Drupal Development (Part 2)
Drupal Development (Part 2)Drupal Development (Part 2)
Drupal Development (Part 2)
 
LET’S WRITE SECURE DRUPAL CODE!
LET’S WRITE SECURE DRUPAL CODE!LET’S WRITE SECURE DRUPAL CODE!
LET’S WRITE SECURE DRUPAL CODE!
 
Let's write secure Drupal code! - DrupalCamp Kyiv 2019
Let's write secure Drupal code! - DrupalCamp Kyiv 2019Let's write secure Drupal code! - DrupalCamp Kyiv 2019
Let's write secure Drupal code! - DrupalCamp Kyiv 2019
 
Broadleaf Presents Thymeleaf
Broadleaf Presents ThymeleafBroadleaf Presents Thymeleaf
Broadleaf Presents Thymeleaf
 
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011
Nickolay Shmalenuk.Render api eng.DrupalCamp Kyiv 2011
 
The History of PHPersistence
The History of PHPersistenceThe History of PHPersistence
The History of PHPersistence
 
Why Hacking WordPress Search Isn't Some Big Scary Thing
Why Hacking WordPress Search Isn't Some Big Scary ThingWhy Hacking WordPress Search Isn't Some Big Scary Thing
Why Hacking WordPress Search Isn't Some Big Scary Thing
 
How to work with legacy code PHPers Rzeszow #2
How to work with legacy code PHPers Rzeszow #2How to work with legacy code PHPers Rzeszow #2
How to work with legacy code PHPers Rzeszow #2
 
Open Source Search: An Analysis
Open Source Search: An AnalysisOpen Source Search: An Analysis
Open Source Search: An Analysis
 
Mojolicious
MojoliciousMojolicious
Mojolicious
 

Mehr von Balázs Tatár

How To Have Fun in Open Source - CMS Garden Unconference 2019
How To Have Fun in Open Source - CMS Garden Unconference 2019How To Have Fun in Open Source - CMS Garden Unconference 2019
How To Have Fun in Open Source - CMS Garden Unconference 2019Balázs Tatár
 
Software Development Weaknesses - SecOSdays Sofia, 2019
Software Development Weaknesses - SecOSdays Sofia, 2019Software Development Weaknesses - SecOSdays Sofia, 2019
Software Development Weaknesses - SecOSdays Sofia, 2019Balázs Tatár
 
Security Awareness for Open Source Web Applications
Security Awareness for Open Source Web ApplicationsSecurity Awareness for Open Source Web Applications
Security Awareness for Open Source Web ApplicationsBalázs Tatár
 
A bug's life - Decoupled Drupal Security and Vulnerability Management
A bug's life - Decoupled Drupal Security and Vulnerability ManagementA bug's life - Decoupled Drupal Security and Vulnerability Management
A bug's life - Decoupled Drupal Security and Vulnerability ManagementBalázs Tatár
 
A bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementA bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementBalázs Tatár
 
A bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementA bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementBalázs Tatár
 
DrupalCon Seattle 2019 - Mentoring Booth slides
DrupalCon Seattle 2019 - Mentoring Booth slidesDrupalCon Seattle 2019 - Mentoring Booth slides
DrupalCon Seattle 2019 - Mentoring Booth slidesBalázs Tatár
 
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...Balázs Tatár
 
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...Balázs Tatár
 
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018Mentoring slides - Drupal Europe, Darmstadt, Germany 2018
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018Balázs Tatár
 
Quality assurance in practice
Quality assurance in practiceQuality assurance in practice
Quality assurance in practiceBalázs Tatár
 
Quality assurance in practice - coffee meeting, January, DIGIT
Quality assurance in practice - coffee meeting, January, DIGITQuality assurance in practice - coffee meeting, January, DIGIT
Quality assurance in practice - coffee meeting, January, DIGITBalázs Tatár
 
Quality assurance in practice - brussels drupal meetup
Quality assurance in practice - brussels drupal meetupQuality assurance in practice - brussels drupal meetup
Quality assurance in practice - brussels drupal meetupBalázs Tatár
 
Quality assurance in practice
Quality assurance in practiceQuality assurance in practice
Quality assurance in practiceBalázs Tatár
 

Mehr von Balázs Tatár (15)

How To Have Fun in Open Source - CMS Garden Unconference 2019
How To Have Fun in Open Source - CMS Garden Unconference 2019How To Have Fun in Open Source - CMS Garden Unconference 2019
How To Have Fun in Open Source - CMS Garden Unconference 2019
 
Software Development Weaknesses - SecOSdays Sofia, 2019
Software Development Weaknesses - SecOSdays Sofia, 2019Software Development Weaknesses - SecOSdays Sofia, 2019
Software Development Weaknesses - SecOSdays Sofia, 2019
 
Security Awareness for Open Source Web Applications
Security Awareness for Open Source Web ApplicationsSecurity Awareness for Open Source Web Applications
Security Awareness for Open Source Web Applications
 
A bug's life - Decoupled Drupal Security and Vulnerability Management
A bug's life - Decoupled Drupal Security and Vulnerability ManagementA bug's life - Decoupled Drupal Security and Vulnerability Management
A bug's life - Decoupled Drupal Security and Vulnerability Management
 
A bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementA bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability Management
 
A bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability ManagementA bug's life - Drupal Application Security and Vulnerability Management
A bug's life - Drupal Application Security and Vulnerability Management
 
DrupalCon Seattle 2019 - Mentoring Booth slides
DrupalCon Seattle 2019 - Mentoring Booth slidesDrupalCon Seattle 2019 - Mentoring Booth slides
DrupalCon Seattle 2019 - Mentoring Booth slides
 
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...
Everything You Always Wanted to Know About Drupal Security* (*But Were Afraid...
 
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...
Everything You Always Wanted to Know About Drupal Security (*But Were Afraid ...
 
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018Mentoring slides - Drupal Europe, Darmstadt, Germany 2018
Mentoring slides - Drupal Europe, Darmstadt, Germany 2018
 
Quality assurance in practice
Quality assurance in practiceQuality assurance in practice
Quality assurance in practice
 
Quality assurance in practice - coffee meeting, January, DIGIT
Quality assurance in practice - coffee meeting, January, DIGITQuality assurance in practice - coffee meeting, January, DIGIT
Quality assurance in practice - coffee meeting, January, DIGIT
 
Quality assurance in practice - brussels drupal meetup
Quality assurance in practice - brussels drupal meetupQuality assurance in practice - brussels drupal meetup
Quality assurance in practice - brussels drupal meetup
 
Quality assurance in practice
Quality assurance in practiceQuality assurance in practice
Quality assurance in practice
 
Drupal 7 - Form API
Drupal 7 - Form APIDrupal 7 - Form API
Drupal 7 - Form API
 

Kürzlich hochgeladen

Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):comworks
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 

Kürzlich hochgeladen (20)

Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):CloudStudio User manual (basic edition):
CloudStudio User manual (basic edition):
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 

Let's write secure Drupal code! - Drupal Camp Poland 2019

Hinweis der Redaktion

  1. Einstein said: “insanity is when you do the same thing over and over again and expect different results”
  2. Owasp: open web application security project
  3. Reference for the XSS issue that was basically caused by a security misconfiguration.
  4. Hide enabled blocks from selector that are used Context update from this wednesday
  5. Hide enabled blocks from selector that are used Context update from this wednesday
  6. Hide enabled blocks from selector that are used Context update from this wednesday
  7. Not because of having db_query deprecated, but: The $field param is used to derive various table and field names, but in each case the Database API automatically escapes these values. Note that the API does not do this for all arguments!
  8. Not because of having db_query deprecated, but: The $field param is used to derive various table and field names, but in each case the Database API automatically escapes these values. Note that the API does not do this for all arguments!
  9. Not because of having db_query deprecated, but: The $field param is used to derive various table and field names, but in each case the Database API automatically escapes these values. Note that the API does not do this for all arguments!
  10. Mt_rand is not secure enough!
  11. Insecure randomness by Mass Password Reset (SA-CONTRIB-2018-043) by Greg Knaddison