+ All Categories
Home > Data & Analytics > Is That Normal? Behaviour Modelling On The Cheap

Is That Normal? Behaviour Modelling On The Cheap

Date post: 29-Jun-2015
Category:
Upload: mark-nunnikhoven
View: 429 times
Download: 1 times
Share this document with a friend
Description:
Originally presented at BSides Ottawa on 06-Sep-2014, this talk lays out the challenges faced by todays defender (for context), the gap in our current defensive strategies (what we'll address), and explains how to start a basic behavioural analysis practice with minimal investment. Remember this is a BSides presentation so there may be some language which causes a double-take ;-) Open with caution.
Popular Tags:
38
Mark Nunnikhoven, bunch of letters @marknca Just like you probably can’t see this, I can’t see the backchannel Tweet me now @marknca, I’ll reply after the talk… Is That Normal? Behaviour modelling on the cheap
Transcript
Page 1: Is That Normal? Behaviour Modelling On The Cheap

Mark Nunnikhoven, bunch of letters @marknca

Just like you probably can’t see this, I can’t see the backchannel Tweet me now @marknca, I’ll reply after the talk…

Is That Normal?Behaviour modelling on the cheap

Page 2: Is That Normal? Behaviour Modelling On The Cheap

What is it?

What folks are doing

Page 3: Is That Normal? Behaviour Modelling On The Cheap

Today’s talk

Context The gap Getting started

Page 4: Is That Normal? Behaviour Modelling On The Cheap

Recently…

Page 5: Is That Normal? Behaviour Modelling On The Cheap
Page 6: Is That Normal? Behaviour Modelling On The Cheap

450 000 000

Page 7: Is That Normal? Behaviour Modelling On The Cheap

Target 27-Nov-2013—15-Dec-2013

First CEO “resignation” due to information security incident

Page 8: Is That Normal? Behaviour Modelling On The Cheap

The Home Depot Early May-2014—Late Aug-2014

a/k/a “Target 2”

Page 9: Is That Normal? Behaviour Modelling On The Cheap

ebay Late Feb-2014—Mid May-2014

Nominated for “Worst Communications During An Incident”

Page 10: Is That Normal? Behaviour Modelling On The Cheap

Houston Astros 17-Jun–2013—17-Oct-2014

“Oh shit, they tried to trade me for an old bus and a hot dog vendor?”

Page 11: Is That Normal? Behaviour Modelling On The Cheap

Amazing visualization from Information Is Beautiful “World’s Biggest Data Breaches & Hacks”

Page 12: Is That Normal? Behaviour Modelling On The Cheap

0d

Because it was successful, it was “an APT”…at least according to marketing

Page 13: Is That Normal? Behaviour Modelling On The Cheap

KISS

Simple works. A lot. With minimal effort Why waste a “bunker buster” when they left the door open?

Page 14: Is That Normal? Behaviour Modelling On The Cheap

The Problem

Page 15: Is That Normal? Behaviour Modelling On The Cheap

Restrict inbound Restrict outbound Heavily monitor access

Data

Page 16: Is That Normal? Behaviour Modelling On The Cheap

Restrict inbound Allow outbound Little to no monitoring

User

Page 17: Is That Normal? Behaviour Modelling On The Cheap
Page 18: Is That Normal? Behaviour Modelling On The Cheap

Yes, we only use 2 types of controls to police this space. Amazing isn’t it?

Authentication Authorization

Page 19: Is That Normal? Behaviour Modelling On The Cheap

3 is more than 2. So that’s an immediate win when reporting up to your boss(es)

Authentication Authorization Behaviour analysis

Page 20: Is That Normal? Behaviour Modelling On The Cheap

How?

Page 21: Is That Normal? Behaviour Modelling On The Cheap

What to look at

All traffic leaving user space

Page 22: Is That Normal? Behaviour Modelling On The Cheap

What to look at

All traffic leaving user space

Page 23: Is That Normal? Behaviour Modelling On The Cheap

What to look for

Malicious patterns

You might want to consider buying something here or at least Martin’s solution However, if you don’t have a strong process for handling alerts don’t bother!

Page 24: Is That Normal? Behaviour Modelling On The Cheap

What to look for

Odd access patterns

You can buy products that help here but we can get good ROI with DIY If you already have a SIEM, put this effort into tuning it’s rules & alerts

Page 25: Is That Normal? Behaviour Modelling On The Cheap

Starting point

…and only a starting point

Page 26: Is That Normal? Behaviour Modelling On The Cheap

The Goal

Provide actionable information to your team

You’re never going to get 100% automated here BUT you can reduce your team’s workload

Page 27: Is That Normal? Behaviour Modelling On The Cheap

In order of importance

Access Transactions Authentication

<< fancy circles for no particular reason

Page 28: Is That Normal? Behaviour Modelling On The Cheap

And then?

Dump it all in a database

Yes, an old school relational database

Page 29: Is That Normal? Behaviour Modelling On The Cheap

Dump it?

Well no…that’ll cause problems*

The #1 problem with RDBMS is that few people consider what they want to get _out_ of them

* Only if you want to do anything with the data. If you want a(nother) shelfware project, go ahead

Page 30: Is That Normal? Behaviour Modelling On The Cheap

It’s amazing what an old school DB can do when structured properly There is a reason why we’ve stuck with the tech for 40+ years

Hardware Table Structure

Desktop HourBigger DayBiggest Week

Bigger-est MonthRidiculous

This talk has “on the Cheap” in the title. Stop showing off

Page 31: Is That Normal? Behaviour Modelling On The Cheap

Anything else?

Add metadata on ingestion*

I felt like using the term “metadata” would add more credibility and a nice NSA-esque feeling here

* You’re trying to save computation later on. And it’s easier to line up usernames or groups now rather than later. You can do fun things with caching too

Page 32: Is That Normal? Behaviour Modelling On The Cheap

Indices?

Store the timestamp as YYYY-MM-DD-HH-MM-SS*

First person to say “what about seconds since the epoch?” gets a free gift It’s not a good gift. You don’t want it. Trust me on this

* No wiggle room. It’s easier to do computations on this way

Page 33: Is That Normal? Behaviour Modelling On The Cheap

How you structure your query has a major impact on performance That should be obvious. If not, it is now

Hardware Query Breadth (in tables)

Desktop 1Bigger 2-3Biggest 3-5

Bigger-est 3-5Ridiculous Didn’t you get the message on 2 slides ago?

Page 34: Is That Normal? Behaviour Modelling On The Cheap

More dimensions == slower performance but potentially more useful answers Use your judgement here

Hardware Query Size (in dimensions)

Desktop 2-3Bigger 3-5Biggest 5-7

Bigger-est 5-7Ridiculous Seriously, WTF?

Page 35: Is That Normal? Behaviour Modelling On The Cheap

How do I frame questions for the data?

Based on the average of X, what are the outliers?

Not the Malcolm Gladwell Outliers, actual math-y type ones

* select min(thing_I_want) from (group_of_things_I_want) select max(thing_I_want) from (group_of_things_I_want)

Page 36: Is That Normal? Behaviour Modelling On The Cheap

Start simple, build up the questions you ask based on success “If it isn’t actionable, get rid of it”, Rob Edwards < awesome guy

Questions you should ask your data?

<Timeline for logins> <Period of access for user> <Size of transaction> <Number of domains per day>* These four will net a lot of interesting info

Page 37: Is That Normal? Behaviour Modelling On The Cheap

Use your logs Reduce work for your team Start small, build

Page 38: Is That Normal? Behaviour Modelling On The Cheap

Thanks!

Mark Nunnikhoven @marknca

Now send me a tweet ;-)


Recommended