Encryption and Anonymization in Hadoop Current and Future needs - - PowerPoint PPT Presentation

encryption and anonymization in hadoop
SMART_READER_LITE
LIVE PREVIEW

Encryption and Anonymization in Hadoop Current and Future needs - - PowerPoint PPT Presentation

Encryption and Anonymization in Hadoop Current and Future needs Sept-28-2015 ApacheCon, Budapest Page 1 Agenda Need for data protection Encryption and Anonymization Current State of Encryption in Hadoop Demo Future focus


slide-1
SLIDE 1

Page 1

Encryption and Anonymization in Hadoop

Sept-28-2015 ApacheCon, Budapest

Current and Future needs

slide-2
SLIDE 2

Page 2

Agenda

  • Need for data protection – Encryption and Anonymization
  • Current State of Encryption in Hadoop
  • Demo
  • Future focus areas for the community
slide-3
SLIDE 3

Page 3

Speakers

Chief Security Architect, Hortonworks Committer - Apache Ranger and Apache Hawq Sr Director, Enterprise Security Hortonworks Committer - Apache Ranger

bosco@apache.org bganesan@apache.org

slide-4
SLIDE 4

Page 4

  • Wire encryption

in Hadoop

  • HDFS, Hbase

encryption

  • Centralized

audit reporting w/ Apache Ranger

  • Fine grain access

control with Apache Ranger

Security today in Hadoop

Authorization What can I do? Audit What did I do? Data Protection

Can data be encrypted at rest and over the wire?

  • Kerberos
  • API security with

Apache Knox Authentication Who am I/prove it? Hadoop Ecosystem Centralized Security Administration w/ Ranger

slide-5
SLIDE 5

Page 5

Data Protection

Encryption and Anonymization

Page 5

slide-6
SLIDE 6

Page 6

Why is Encryption at Rest required?

  • Sensitive data could be stored in Hadoop
  • Compliance or external regulation may mandate encryption, example PCI

(Retail, Consumer) or HIPAA ( Healthcare)

  • Cost of not encrypting is increasing
  • Enhanced Security
  • Added layer on top of authentication (passwords) and authorization (ACLs)
  • Protect certain rogue administrators from accessing sensitive data
slide-7
SLIDE 7

Page 7

Available Hadoop Encryption Options

OS HDFS Hbase Custom

Granualrity Ease of implementation

slide-8
SLIDE 8

Page 8

OS Level Encryption – LUKS/DM-CRYPT

Partition 2..n DM - CRYPT Partition 1

/root / grid0 / grid2 / gridn

Hadoop Why it helps?

  • Encrypts entire disk volume

– all data is encrypted

  • Simpler setup, native OS

and Vendor solutions available Cons

  • Performance challenges
  • Admin can still see raw

data

slide-9
SLIDE 9

Page 9

Ranger KMS

HDFS Transparent Encryption Solution

NN A B C D HDFS Client A B C D A B C D DN DN DN

Why it helps?

  • Encrypt only specific data
  • Different access control

levels

  • Transparent to end

application, little changes needed

  • Auditing of Key Access
slide-10
SLIDE 10

Page 10

HDFS Encryption – Protect Application Data

NN A B C D A B C D A B C D DN DN DN HBase Hive Oozie Sqoop Spark

Guidelines

  • Encrypt Hive, Hbase data

stored in HDFS

  • Specific changes in Hive

to ensure scratch dir is encrypted

  • Separate admins in

HDFS, Yarn, Oozie

  • Spark application logs

should be in EZ

slide-11
SLIDE 11

Page 11

Ranger KMS – Centralized Key Management

slide-12
SLIDE 12

Page 12

HDFS TDE Workflow

Create Encryption Zone Create EZ Keys Provide EZ Keys Ranger KMS NN, DN Client NN marks folder as EZ

slide-13
SLIDE 13

Page 13

HDFS TDE Workflow – Write a File

Receive EDEK. Request DEK Create DEK and encrypt with EZ Key Decrypt EDEK, provide DEK NN, DN Client Client request to write to EZ NN does access check. Encrypt data and write to DN. Send block information to

  • client. EDEK

stored with file Ranger KMS

slide-14
SLIDE 14

Page 14

HDFS TDE Workflow – Read a File

Receive EDEK. Request DEK Decrypt EDEK, provide DEK NN, DN Client Client request to read from EZ NN does access check. Provide data, EDEK Use DEK to read file data Ranger KMS

slide-15
SLIDE 15

Page 15

Hbase Encryption in 0.98

Why it helps?

  • Hfile

encrypted and stored in disk

  • Per CF

configuration

  • Keys stored

in Java keystore

slide-16
SLIDE 16

Page 16

Demo

Don Bosco Durai

Page 16

slide-17
SLIDE 17

Page 17

Future Work

Focus areas for the community

slide-18
SLIDE 18

Page 18

Encryption and Anonymization - Future Focus Areas

² Hive Column Encryption ² Solidifying Hbase Encryption ² Kafka and Solr Encryption ² Need for Tokenization/Masking

slide-19
SLIDE 19

Page 19

Hive Column Encryption

  • Being discussed in the community. Apache JIRA #

ORC-14

  • Handled at the ORC layer
  • Elegant solution. Encryption done after ORC compression.
  • Each columns are different files and they can be

encrypted with different key

  • Leverage keyprovider API. Potentially can use Hadoop/

Ranger KMS

How it will help?

  • Encrypt

fields instead of file

  • Data

protected in HDFS as well as OS layer

slide-20
SLIDE 20

Page 20

Kafka Encryption

  • Discussion going on in Kafka community
  • Two possible approaches
  • Broker encrypts and stores the data
  • Client(s) encrypt/decrypt the data
  • Pros with client side encrypt/decrypt
  • No encryption/decryption overhead on Broker side
  • Keys not available on Broker, so data safe from everyone
  • No need for wire encryption
  • Cons with client side encrypt/decrypt
  • Compaction/compression not effective with encrypted data.
  • Needs protocol change and update client libraries.

How it will help?

  • Encrypt any

local data stored in disks

  • Data

encrypted

  • n wire
slide-21
SLIDE 21

Page 21

Solr Encryption

  • No active discussion currently
  • Will be good to have native support
  • Index files could be encrypted/decrypted just like

ORC

  • Could be integrated with external KMS (Hadoop/

Ranger)

How it will help?

  • Sensitive data

could be stored in indexes, may need to be encrypted

  • Higher

granularity than OS or HDFS encryption

slide-22
SLIDE 22

Page 22

Beyond Encryption... Anonymization1?

  • Tokenization – Replace a sensitive field (eg: card

number) with some other value. Could be format preserving or random unique value.

  • Redaction - Mask sensitive data (eg: card numbers

can be changed to xxxx xxxx xxxx 1234)

  • 1. http://blogs.gartner.com/merv-adrian/2014/01/13/aaa-is-not-enough-security-in-the-big-data-era/

How it helps?

  • Protect

sensitive data beyond access control

  • Field level

control

  • Enable

compliance to privacy laws

slide-23
SLIDE 23

Page 23

Where is it applicable?

  • Sensitive data in HDFS file
  • Column values in Hive or Hbase
  • Field values in Solr
  • Messages in Kafka or NiFi
slide-24
SLIDE 24

Page 24

How?

  • Tokenize on source
  • Tokenize while ingesting data (Flume, NiFi, Sqoop, etc.)
  • Data stored tokenized, so safe to give access to others.
  • Selective users can de-tokenize if needed
  • Tokenize/Mask on read
  • E.g. select name, mobile_number from customer;

Based on policy, if user is Data Scientist, then tokenize/mask data before returning Name Returned (Format Preserved) Actual John Doe 415-123-4567 415-682-5638 Jane Smith 408-123-4567 408-802-4027 Mary Pick 650-123-4567 650-865-6921

slide-25
SLIDE 25

Page 25

Questions ??