SlideShare a Scribd company logo
Tzach Livyatan - Head of Product, ScyllaDB
How to Bullet-Proof
Your Scylla Deployment
2
Speakers
Tzach Livyatan is ScyllaDB Product Manager, and has had a
15 year career in development, system engineering and
product management.
In the past he worked in the Telecom domain, focusing on
carrier grade systems, signalling, policy and charging
applications for Oracle and others.
3
+ The Real-Time Big Data Database
+ Drop-in replacement for Apache Cassandra
+ 10X the performance & low tail latency
+ Open source and Enterprise editions
+ New: Scylla Cloud, DBaaS
+ Founded by the creators of KVM hypervisor
+ HQs: Palo Alto, CA; Herzelia, Israel
About ScyllaDB
A System is Never “Bullet-Proof”
Securing the system is an endless,
ongoing process
Security Risks Bingo
Sniffing on
Application-DB
Connection
Key Leak
Unauthorized Server
Access
Insider Data Breach
Port Scanning DDoS CQL Injection OS Vulnerabilities
Unauthorized DB
Access
Man-in-the-middle Brute Force Attack Data Leak
Physical Theft
Non Authenticated
Access
Sniffing on
node-node
Connection
Ransomware
Agenda
6
+ Authentication
+ Authorization
+ RBAC
+ Encryption In Transit
+ Encryption at Rest
+ Auditing
+ Minimal Exposure
+ Best Practices
+ Limit access to the cluster to identified clients
+ Disabled by default (Enabled in Scylla Cloud)
+ Enable and Disable Authentication Without Downtime
a. Move to a TransitionalAuthenticator
b. Enable Auth on each client
c. Move to PasswordAuthenticator
+ Best Practice : use a unique User per application, for easier
Auditing and Service Level
Authentication
Authorization is the process by where users are granted permissions which entitle them
to access or change data on specific keyspaces, tables or an entire datacenter.
Authorization is enabled using the authorizer setting in scylla.yaml. Scylla has two
authorizers available:
+ AllowAllAuthorizer (default setting) - which performs no checking and so
effectively grants all permissions to all roles.
+ CassandraAuthorizer - which implements permission management functionality
and stores its data in Scylla system tables.
Authorization
Role-Based Access Control
+ Method of reducing lists of authorized users to a few roles assigned to multiple users
+ Create the roles and their associated permissions
+ Roles can be granted to other roles
+ Users are Roles
+ Cassandra compatible CQL syntax (users, permissions, roles) here
+ More info here
Users Are Roles (with login)
Roles
Users
Users Are Roles (with login)
Customer
Trainer
Staff
Admin
TimDennisMaryLisa
schedule.cust
GRANT
SELECT
customer.info
schedule.train
SELECT
schedule
customer
SELECT
MODIFY
SUPERUSER
GRANT
GRANT
CREATE ROLE customer;
GRANT SELECT ON schedule.cust TO customer;
CREATE ROLE trainer;
GRANT customer TO trainer;
GRANT SELECT ON customer.info TO trainer;
GRANT SELECT ON schedule.train TO trainer;
Role Based Access Control - Example
CREATE ROLE lisa WITH PASSWORD = 'password' AND LOGIN = true;
CREATE ROLE mary WITH PASSWORD = 'password' AND LOGIN = true;
GRANT trainer TO mary;
GRANT customer TO lisa;
Role Based Access Control - Example
Granting Roles and Permissions
+ Permission: what the role is permitted to do
+ Resource: the scope over which the permission is granted for
GRANT (permission | "ALL PERMISSIONS") ON resource TO role
where:
• Where permission is CREATE, DESCRIBE, etc.
• A resource is one of
• “<ks>.<tab>”
• “KEYSPACE <ks>”
• “ALL KEYSPACES”
• “ROLE <role>”
• “ALL ROLES”
• Note that An unqualified table name assumes the current keyspace
How to Bulletproof Your Scylla Deployment
+ Encryption In Transit
+ Client to Node
+ Node to Node
+ Encryption At Rest
+ Tables
+ System
+ Providers
Encryption
17
+ SSL Encryption of Data In Flight is available in all versions of Scylla
+ Client - Node Encryption - The available options are:
+ Enabled or Not Enabled
+ When Enabled, all incoming CQL connections require TLS/SSL
connectivity.
+ Setting include:
+ certificate - A PEM format certificate, either self-signed, or provided by
a CA authority.
+ keyfile - The corresponding PEM format key for the certificate
More Info: Encryption: Data in Transit Client to Node
Encryption In Transit - Client to Node
18
+ SSL Encryption of Data In Flight is available in all versions of Scylla
+ Internode_encryption - The available options are:
+ none (default) / all / dc/ rack
+ Settings include:
+ certificate - A PEM format certificate, either self-signed, or provided by a
certificate authority (CA).
+ keyfile - The corresponding PEM format key for the certificate
+ truststore - Optional path to a PEM format certificate store of trusted CA:s.
If not provided, Scylla will attempt to use the system trust store to
authenticate certificates.
More Info: Encryption: Data in Transit Node to Node
Encryption In Transit - Node to Node
Encryption At Rest
+ Encryption of user data as stored on disk
+ SSTables
+ Commitlog
+ Hints
+ Batchlog
+ Invisible to client
+ Transparent Data Encryption
+ Scylla Enterprise 2019.1
19
System level granularity
keyspace.table granularity
Encryption at Rest
+ Uses disk block encryption
+ File level wrapping
+ Divides file into 4k blocks and encrypts/decrypts on r/w
■ Uses hash of key + block position to derive init vector
for block cipher (ESSIV - cryptfs)
+ Hooked via extension points in sstables/commitlog/hints
+ Wraps files depending on config/schema
20
CREATE TABLE data.atrest (pk text primary key, c0 int) WITH
scylla_encryption_options = {
'cipher_algorithm' : 'AES/ECB/PKCS5Padding',
'secret_key_strength' : 128,
'key_provider': 'LocalFileSystemKeyProviderFactory',
'secret_key_file':
'/etc/scylla/encryption_keys/data_encryption_keys'
}
;
+ cipher_algoritm - The key type (algorithm)
+ secret_key_strength - The length of the key in bits
+ key_provider - Name of the provider for the key
21
Encryption at Rest
Encryption at rest
cipher_algorithm secret_key_strength
AES/CBC/PKCS5Padding (default) 128 (default), 192, or 256
AES/ECB/PKCS5Padding 128, 192, or 256
Blowfish/CBC/PKCS5Padding 32-448
DES/CBC/PKCS5Padding 56
DESede/CBC/PKCS5Padding 112 or 168
RC2/CBC/PKCS5Padding 40-128
cipher_algorithims are available for use with Scylla using OpenSSL.
Enable/disable encryption of existing table
ALTER TABLE data.atrest (pk text primary key, c0 int) WITH
scylla_encryption_options = {
'cipher_algorithm' : 'AES/ECB/PKCS5Padding',
'secret_key_strength' : 192,
'key_provider': 'LocalFileSystemKeyProviderFactory',
'Secret_key_file':
'/etc/scylla/encryption_keys/data_encryption_keys'
}
;
ALTER TABLE ks.test WITH
scylla_encryption_options = { 'key_provider' : 'none’ };
23
Enable/disable (cont)
+ Data is not encrypted or decrypted until SSTables are (re-)written
+ Must force rewrite to ensure all data is changed
+ If you remove an encryption key before all data is decrypted/rewritten
the data will be lost
> nodetool upgradesstables -a <keyspace> <table>
24
System Encryption
+ Encrypts “implicitly” stored user data
+ Commitlog, hints, batch
+ Configured on node level (scylla.yaml)
system_info_encryption:
enabled: <bool>
key_provider: (optional) <key provider type>
+ Uses same key providers and options as table encryption
25
26
Key Providers
KMIP
+ Centralized key
management
+ Replacement/ rotation
functionality in server
Local
+ Does not require an
external server
+ Persisted on the node
+ Manual distribution to
all nodes
Scylla Tables
Distributes keys for
SSTables only (no
system keys)
Local key
file
System
Key file
Key
Key
KMIP
host
Keys
Scylla table
Local
provider
Replicated
provider
KMIP provider
Keys
Encryption extension
..either
Encryption extension
encrypts
System table
(hints,
batchlog)
Commit log User table
+ Who did / looked at / changed what and when
+ Logging activities a user performs on Scylla cluster
+ Enable on scylla.yaml (2018.1.x and later)
+ Three audit storage alternatives:
+ None (default) - Audit is disabled
+ Table - Enables audit, messages stored in a Scylla table: audit.audit_log
+ Syslog - Enables audit, messages are sent to syslog and to an external server
28
Auditing
+ scylla.yaml params
+ Audit categories
Auditing every DML or QUERY
can have significant impact on
perf, and consume storage.
Use wisely!
29
What Can You Audit?
+ Ensure that Scylla runs in a trusted
network environment.
+ Limit access to IP / Port by role.
+ Use the minimal privileges principle
+ Avoid Public IP if possible
+ Use VPC if possible
Minimize Network Exposure
Scylla Cloud - Limit cluster access to min
31
How to Bulletproof Your Scylla Deployment
+ Routinely upgrade to latest Scylla and OS versions
+ Routinely check for network exposure
+ Routinely replace keys/passwords
+ Use 2FA (Scylla Cloud)
+ Use minimal privilege principle
+ Apply available security features
Security is an Ongoing Process
33
https://twitter.com/Hackers_bot
Incremental Compaction
Sept 4, 2019 | 10:00 AM PT - 1:00 PM ET
Available on-demand:
How to Shrink Your Datacenter
Footprint by 50%
Data Modeling Best Practices
How to Size Your Scylla Cluster
Q&A
Stay in touch
tzach@scylladb.com
@tzachl
Security Risk Bingo
Sniffing on
Application-DB
Connection
Key Leak
Unauthorized Server
Access
Insider Data Breach
Port Scanning DDoS CQL Injection OS Vulnerabilities
Unauthorized DB
Access
Man-in-the-middle Brute Force Attack Data Leak (logs)
Physical Theft
Non Authenticated
Access
Sniffing on
node-node
Connection
Ransomware
United States
1900 Embarcadero Road
Palo Alto, CA 94303
Israel
11 Galgalei Haplada
Herzelia, Israel
www.scylladb.com
@scylladb
Thank you

More Related Content

PDF
Building a Real-time Streaming ETL Framework Using ksqlDB and NoSQL
PDF
Building Event Streaming Architectures on Scylla and Kafka
PDF
The True Cost of NoSQL DBaaS Options
PDF
Wide Column Store NoSQL vs SQL Data Modeling
PDF
RDBMS to NoSQL: Practical Advice from Successful Migrations
PDF
Introduction to Apache Cassandra™ + What’s New in 4.0
PPTX
Lightweight Transactions in Scylla versus Apache Cassandra
PDF
Feeding Cassandra with Spark-Streaming and Kafka
Building a Real-time Streaming ETL Framework Using ksqlDB and NoSQL
Building Event Streaming Architectures on Scylla and Kafka
The True Cost of NoSQL DBaaS Options
Wide Column Store NoSQL vs SQL Data Modeling
RDBMS to NoSQL: Practical Advice from Successful Migrations
Introduction to Apache Cassandra™ + What’s New in 4.0
Lightweight Transactions in Scylla versus Apache Cassandra
Feeding Cassandra with Spark-Streaming and Kafka

What's hot (20)

PDF
Troubleshooting Cassandra (J.B. Langston, DataStax) | C* Summit 2016
PDF
Webinar: How to Shrink Your Datacenter Footprint by 50%
PPTX
DataStax | DSE Search 5.0 and Beyond (Nick Panahi & Ariel Weisberg) | Cassand...
PDF
Azure + DataStax Enterprise Powers Office 365 Per User Store
PDF
Maximum Overdrive: Tuning the Spark Cassandra Connector (Russell Spitzer, Dat...
PDF
The Promise and Perils of Encrypting Cassandra Data (Ameesh Divatia, Baffle, ...
PPTX
Lessons Learned From Running 1800 Clusters (Brooke Jensen, Instaclustr) | Cas...
PPTX
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
PDF
Advanced Operations
PPTX
Real Time Business Intelligence with Cassandra, Kafka and Hadoop - A Real Sto...
PDF
Under the Hood of a Shard-per-Core Database Architecture
PDF
Make 2016 your year of SMACK talk
PPTX
Using Spark to Load Oracle Data into Cassandra
PDF
TechTalk: Reduce Your Storage Footprint with a Revolutionary New Compaction S...
PDF
GumGum: Multi-Region Cassandra in AWS
PDF
Develop Scalable Applications with DataStax Drivers (Alex Popescu, Bulat Shak...
PDF
Advanced Cassandra
PDF
Webinar how to build a highly available time series solution with kairos-db (1)
PPTX
Productizing a Cassandra-Based Solution (Brij Bhushan Ravat, Ericsson) | C* S...
PDF
DataStax | DataStax Tools for Developers (Alex Popescu) | Cassandra Summit 2016
Troubleshooting Cassandra (J.B. Langston, DataStax) | C* Summit 2016
Webinar: How to Shrink Your Datacenter Footprint by 50%
DataStax | DSE Search 5.0 and Beyond (Nick Panahi & Ariel Weisberg) | Cassand...
Azure + DataStax Enterprise Powers Office 365 Per User Store
Maximum Overdrive: Tuning the Spark Cassandra Connector (Russell Spitzer, Dat...
The Promise and Perils of Encrypting Cassandra Data (Ameesh Divatia, Baffle, ...
Lessons Learned From Running 1800 Clusters (Brooke Jensen, Instaclustr) | Cas...
Tales From the Field: The Wrong Way of Using Cassandra (Carlos Rolo, Pythian)...
Advanced Operations
Real Time Business Intelligence with Cassandra, Kafka and Hadoop - A Real Sto...
Under the Hood of a Shard-per-Core Database Architecture
Make 2016 your year of SMACK talk
Using Spark to Load Oracle Data into Cassandra
TechTalk: Reduce Your Storage Footprint with a Revolutionary New Compaction S...
GumGum: Multi-Region Cassandra in AWS
Develop Scalable Applications with DataStax Drivers (Alex Popescu, Bulat Shak...
Advanced Cassandra
Webinar how to build a highly available time series solution with kairos-db (1)
Productizing a Cassandra-Based Solution (Brij Bhushan Ravat, Ericsson) | C* S...
DataStax | DataStax Tools for Developers (Alex Popescu) | Cassandra Summit 2016
Ad

Similar to How to Bulletproof Your Scylla Deployment (20)

PPTX
How to Secure Your Scylla Deployment: Authorization, Encryption, LDAP Authent...
PPTX
Scylla Summit 2018: Access-control in Scylla - What You Can Do, How It Works,...
PDF
Recent ScyllaDB Cloud Highlights and Future Roadmap by Michael Hollander & Iv...
PPTX
ScyllaDB Cloud: Faster and More Flexible
PDF
Hardening cassandra q2_2016
PDF
Securing Cassandra for Compliance
PDF
Running a DynamoDB-compatible Database on Managed Kubernetes Services
PDF
Running a Cost-Effective DynamoDB-Compatible Database on Managed Kubernetes S...
PDF
Introducing Scylla Cloud
PDF
Demystifying the use of wallets and ssl with your database
PDF
Securing Cassandra The Right Way
PDF
Scylla Summit 2022: How ScyllaDB Powers This Next Tech Cycle
PPTX
Securing Open Source Databases
PDF
MariaDB Server & MySQL Security Essentials 2016
PDF
Better encryption & security with MariaDB 10.1 & MySQL 5.7
PDF
Using ScyllaDB for Extreme Scale Workloads
PDF
MariaDB Security Best Practices
PPTX
MongoDB vs Scylla: Production Experience from Both Dev & Ops Standpoint at Nu...
PDF
Elasticity, Speed & Simplicity: Get the Most Out of New ScyllaDB Capabilities
PDF
Scylla Summit 2022: What’s New in ScyllaDB Operator for Kubernetes
How to Secure Your Scylla Deployment: Authorization, Encryption, LDAP Authent...
Scylla Summit 2018: Access-control in Scylla - What You Can Do, How It Works,...
Recent ScyllaDB Cloud Highlights and Future Roadmap by Michael Hollander & Iv...
ScyllaDB Cloud: Faster and More Flexible
Hardening cassandra q2_2016
Securing Cassandra for Compliance
Running a DynamoDB-compatible Database on Managed Kubernetes Services
Running a Cost-Effective DynamoDB-Compatible Database on Managed Kubernetes S...
Introducing Scylla Cloud
Demystifying the use of wallets and ssl with your database
Securing Cassandra The Right Way
Scylla Summit 2022: How ScyllaDB Powers This Next Tech Cycle
Securing Open Source Databases
MariaDB Server & MySQL Security Essentials 2016
Better encryption & security with MariaDB 10.1 & MySQL 5.7
Using ScyllaDB for Extreme Scale Workloads
MariaDB Security Best Practices
MongoDB vs Scylla: Production Experience from Both Dev & Ops Standpoint at Nu...
Elasticity, Speed & Simplicity: Get the Most Out of New ScyllaDB Capabilities
Scylla Summit 2022: What’s New in ScyllaDB Operator for Kubernetes
Ad

More from ScyllaDB (20)

PDF
Understanding The True Cost of DynamoDB Webinar
PDF
Database Benchmarking for Performance Masterclass: Session 2 - Data Modeling ...
PDF
Database Benchmarking for Performance Masterclass: Session 1 - Benchmarking F...
PDF
New Ways to Reduce Database Costs with ScyllaDB
PDF
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
PDF
Powering a Billion Dreams: Scaling Meesho’s E-commerce Revolution with Scylla...
PDF
Leading a High-Stakes Database Migration
PDF
Achieving Extreme Scale with ScyllaDB: Tips & Tradeoffs
PDF
Securely Serving Millions of Boot Artifacts a Day by João Pedro Lima & Matt ...
PDF
How Agoda Scaled 50x Throughput with ScyllaDB by Worakarn Isaratham
PDF
How Yieldmo Cut Database Costs and Cloud Dependencies Fast by Todd Coleman
PDF
ScyllaDB: 10 Years and Beyond by Dor Laor
PDF
Reduce Your Cloud Spend with ScyllaDB by Tzach Livyatan
PDF
Migrating 50TB Data From a Home-Grown Database to ScyllaDB, Fast by Terence Liu
PDF
Vector Search with ScyllaDB by Szymon Wasik
PDF
Workload Prioritization: How to Balance Multiple Workloads in a Cluster by Fe...
PDF
Two Leading Approaches to Data Virtualization, and Which Scales Better? by Da...
PDF
Scaling a Beast: Lessons from 400x Growth in a High-Stakes Financial System b...
PDF
Object Storage in ScyllaDB by Ran Regev, ScyllaDB
PDF
Lessons Learned from Building a Serverless Notifications System by Srushith R...
Understanding The True Cost of DynamoDB Webinar
Database Benchmarking for Performance Masterclass: Session 2 - Data Modeling ...
Database Benchmarking for Performance Masterclass: Session 1 - Benchmarking F...
New Ways to Reduce Database Costs with ScyllaDB
Designing Low-Latency Systems with Rust and ScyllaDB: An Architectural Deep Dive
Powering a Billion Dreams: Scaling Meesho’s E-commerce Revolution with Scylla...
Leading a High-Stakes Database Migration
Achieving Extreme Scale with ScyllaDB: Tips & Tradeoffs
Securely Serving Millions of Boot Artifacts a Day by João Pedro Lima & Matt ...
How Agoda Scaled 50x Throughput with ScyllaDB by Worakarn Isaratham
How Yieldmo Cut Database Costs and Cloud Dependencies Fast by Todd Coleman
ScyllaDB: 10 Years and Beyond by Dor Laor
Reduce Your Cloud Spend with ScyllaDB by Tzach Livyatan
Migrating 50TB Data From a Home-Grown Database to ScyllaDB, Fast by Terence Liu
Vector Search with ScyllaDB by Szymon Wasik
Workload Prioritization: How to Balance Multiple Workloads in a Cluster by Fe...
Two Leading Approaches to Data Virtualization, and Which Scales Better? by Da...
Scaling a Beast: Lessons from 400x Growth in a High-Stakes Financial System b...
Object Storage in ScyllaDB by Ran Regev, ScyllaDB
Lessons Learned from Building a Serverless Notifications System by Srushith R...

Recently uploaded (20)

PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
NewMind AI Monthly Chronicles - July 2025
DOCX
The AUB Centre for AI in Media Proposal.docx
PPTX
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
cuic standard and advanced reporting.pdf
PDF
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Network Security Unit 5.pdf for BCA BBA.
PPTX
Big Data Technologies - Introduction.pptx
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
Empathic Computing: Creating Shared Understanding
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Advanced methodologies resolving dimensionality complications for autism neur...
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Per capita expenditure prediction using model stacking based on satellite ima...
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
NewMind AI Weekly Chronicles - August'25 Week I
NewMind AI Monthly Chronicles - July 2025
The AUB Centre for AI in Media Proposal.docx
breach-and-attack-simulation-cybersecurity-india-chennai-defenderrabbit-2025....
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
cuic standard and advanced reporting.pdf
Bridging biosciences and deep learning for revolutionary discoveries: a compr...
Mobile App Security Testing_ A Comprehensive Guide.pdf
Network Security Unit 5.pdf for BCA BBA.
Big Data Technologies - Introduction.pptx
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
20250228 LYD VKU AI Blended-Learning.pptx
Empathic Computing: Creating Shared Understanding
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Advanced methodologies resolving dimensionality complications for autism neur...

How to Bulletproof Your Scylla Deployment

  • 1. Tzach Livyatan - Head of Product, ScyllaDB How to Bullet-Proof Your Scylla Deployment
  • 2. 2 Speakers Tzach Livyatan is ScyllaDB Product Manager, and has had a 15 year career in development, system engineering and product management. In the past he worked in the Telecom domain, focusing on carrier grade systems, signalling, policy and charging applications for Oracle and others.
  • 3. 3 + The Real-Time Big Data Database + Drop-in replacement for Apache Cassandra + 10X the performance & low tail latency + Open source and Enterprise editions + New: Scylla Cloud, DBaaS + Founded by the creators of KVM hypervisor + HQs: Palo Alto, CA; Herzelia, Israel About ScyllaDB
  • 4. A System is Never “Bullet-Proof” Securing the system is an endless, ongoing process
  • 5. Security Risks Bingo Sniffing on Application-DB Connection Key Leak Unauthorized Server Access Insider Data Breach Port Scanning DDoS CQL Injection OS Vulnerabilities Unauthorized DB Access Man-in-the-middle Brute Force Attack Data Leak Physical Theft Non Authenticated Access Sniffing on node-node Connection Ransomware
  • 6. Agenda 6 + Authentication + Authorization + RBAC + Encryption In Transit + Encryption at Rest + Auditing + Minimal Exposure + Best Practices
  • 7. + Limit access to the cluster to identified clients + Disabled by default (Enabled in Scylla Cloud) + Enable and Disable Authentication Without Downtime a. Move to a TransitionalAuthenticator b. Enable Auth on each client c. Move to PasswordAuthenticator + Best Practice : use a unique User per application, for easier Auditing and Service Level Authentication
  • 8. Authorization is the process by where users are granted permissions which entitle them to access or change data on specific keyspaces, tables or an entire datacenter. Authorization is enabled using the authorizer setting in scylla.yaml. Scylla has two authorizers available: + AllowAllAuthorizer (default setting) - which performs no checking and so effectively grants all permissions to all roles. + CassandraAuthorizer - which implements permission management functionality and stores its data in Scylla system tables. Authorization
  • 9. Role-Based Access Control + Method of reducing lists of authorized users to a few roles assigned to multiple users + Create the roles and their associated permissions + Roles can be granted to other roles + Users are Roles + Cassandra compatible CQL syntax (users, permissions, roles) here + More info here
  • 10. Users Are Roles (with login) Roles Users
  • 11. Users Are Roles (with login) Customer Trainer Staff Admin TimDennisMaryLisa schedule.cust GRANT SELECT customer.info schedule.train SELECT schedule customer SELECT MODIFY SUPERUSER GRANT GRANT
  • 12. CREATE ROLE customer; GRANT SELECT ON schedule.cust TO customer; CREATE ROLE trainer; GRANT customer TO trainer; GRANT SELECT ON customer.info TO trainer; GRANT SELECT ON schedule.train TO trainer; Role Based Access Control - Example
  • 13. CREATE ROLE lisa WITH PASSWORD = 'password' AND LOGIN = true; CREATE ROLE mary WITH PASSWORD = 'password' AND LOGIN = true; GRANT trainer TO mary; GRANT customer TO lisa; Role Based Access Control - Example
  • 14. Granting Roles and Permissions + Permission: what the role is permitted to do + Resource: the scope over which the permission is granted for GRANT (permission | "ALL PERMISSIONS") ON resource TO role where: • Where permission is CREATE, DESCRIBE, etc. • A resource is one of • “<ks>.<tab>” • “KEYSPACE <ks>” • “ALL KEYSPACES” • “ROLE <role>” • “ALL ROLES” • Note that An unqualified table name assumes the current keyspace
  • 16. + Encryption In Transit + Client to Node + Node to Node + Encryption At Rest + Tables + System + Providers Encryption
  • 17. 17 + SSL Encryption of Data In Flight is available in all versions of Scylla + Client - Node Encryption - The available options are: + Enabled or Not Enabled + When Enabled, all incoming CQL connections require TLS/SSL connectivity. + Setting include: + certificate - A PEM format certificate, either self-signed, or provided by a CA authority. + keyfile - The corresponding PEM format key for the certificate More Info: Encryption: Data in Transit Client to Node Encryption In Transit - Client to Node
  • 18. 18 + SSL Encryption of Data In Flight is available in all versions of Scylla + Internode_encryption - The available options are: + none (default) / all / dc/ rack + Settings include: + certificate - A PEM format certificate, either self-signed, or provided by a certificate authority (CA). + keyfile - The corresponding PEM format key for the certificate + truststore - Optional path to a PEM format certificate store of trusted CA:s. If not provided, Scylla will attempt to use the system trust store to authenticate certificates. More Info: Encryption: Data in Transit Node to Node Encryption In Transit - Node to Node
  • 19. Encryption At Rest + Encryption of user data as stored on disk + SSTables + Commitlog + Hints + Batchlog + Invisible to client + Transparent Data Encryption + Scylla Enterprise 2019.1 19 System level granularity keyspace.table granularity
  • 20. Encryption at Rest + Uses disk block encryption + File level wrapping + Divides file into 4k blocks and encrypts/decrypts on r/w ■ Uses hash of key + block position to derive init vector for block cipher (ESSIV - cryptfs) + Hooked via extension points in sstables/commitlog/hints + Wraps files depending on config/schema 20
  • 21. CREATE TABLE data.atrest (pk text primary key, c0 int) WITH scylla_encryption_options = { 'cipher_algorithm' : 'AES/ECB/PKCS5Padding', 'secret_key_strength' : 128, 'key_provider': 'LocalFileSystemKeyProviderFactory', 'secret_key_file': '/etc/scylla/encryption_keys/data_encryption_keys' } ; + cipher_algoritm - The key type (algorithm) + secret_key_strength - The length of the key in bits + key_provider - Name of the provider for the key 21 Encryption at Rest
  • 22. Encryption at rest cipher_algorithm secret_key_strength AES/CBC/PKCS5Padding (default) 128 (default), 192, or 256 AES/ECB/PKCS5Padding 128, 192, or 256 Blowfish/CBC/PKCS5Padding 32-448 DES/CBC/PKCS5Padding 56 DESede/CBC/PKCS5Padding 112 or 168 RC2/CBC/PKCS5Padding 40-128 cipher_algorithims are available for use with Scylla using OpenSSL.
  • 23. Enable/disable encryption of existing table ALTER TABLE data.atrest (pk text primary key, c0 int) WITH scylla_encryption_options = { 'cipher_algorithm' : 'AES/ECB/PKCS5Padding', 'secret_key_strength' : 192, 'key_provider': 'LocalFileSystemKeyProviderFactory', 'Secret_key_file': '/etc/scylla/encryption_keys/data_encryption_keys' } ; ALTER TABLE ks.test WITH scylla_encryption_options = { 'key_provider' : 'none’ }; 23
  • 24. Enable/disable (cont) + Data is not encrypted or decrypted until SSTables are (re-)written + Must force rewrite to ensure all data is changed + If you remove an encryption key before all data is decrypted/rewritten the data will be lost > nodetool upgradesstables -a <keyspace> <table> 24
  • 25. System Encryption + Encrypts “implicitly” stored user data + Commitlog, hints, batch + Configured on node level (scylla.yaml) system_info_encryption: enabled: <bool> key_provider: (optional) <key provider type> + Uses same key providers and options as table encryption 25
  • 26. 26 Key Providers KMIP + Centralized key management + Replacement/ rotation functionality in server Local + Does not require an external server + Persisted on the node + Manual distribution to all nodes Scylla Tables Distributes keys for SSTables only (no system keys)
  • 27. Local key file System Key file Key Key KMIP host Keys Scylla table Local provider Replicated provider KMIP provider Keys Encryption extension ..either Encryption extension encrypts System table (hints, batchlog) Commit log User table
  • 28. + Who did / looked at / changed what and when + Logging activities a user performs on Scylla cluster + Enable on scylla.yaml (2018.1.x and later) + Three audit storage alternatives: + None (default) - Audit is disabled + Table - Enables audit, messages stored in a Scylla table: audit.audit_log + Syslog - Enables audit, messages are sent to syslog and to an external server 28 Auditing
  • 29. + scylla.yaml params + Audit categories Auditing every DML or QUERY can have significant impact on perf, and consume storage. Use wisely! 29 What Can You Audit?
  • 30. + Ensure that Scylla runs in a trusted network environment. + Limit access to IP / Port by role. + Use the minimal privileges principle + Avoid Public IP if possible + Use VPC if possible Minimize Network Exposure
  • 31. Scylla Cloud - Limit cluster access to min 31
  • 33. + Routinely upgrade to latest Scylla and OS versions + Routinely check for network exposure + Routinely replace keys/passwords + Use 2FA (Scylla Cloud) + Use minimal privilege principle + Apply available security features Security is an Ongoing Process 33 https://twitter.com/Hackers_bot
  • 34. Incremental Compaction Sept 4, 2019 | 10:00 AM PT - 1:00 PM ET Available on-demand: How to Shrink Your Datacenter Footprint by 50% Data Modeling Best Practices How to Size Your Scylla Cluster
  • 36. Security Risk Bingo Sniffing on Application-DB Connection Key Leak Unauthorized Server Access Insider Data Breach Port Scanning DDoS CQL Injection OS Vulnerabilities Unauthorized DB Access Man-in-the-middle Brute Force Attack Data Leak (logs) Physical Theft Non Authenticated Access Sniffing on node-node Connection Ransomware
  • 37. United States 1900 Embarcadero Road Palo Alto, CA 94303 Israel 11 Galgalei Haplada Herzelia, Israel www.scylladb.com @scylladb Thank you