WEBVTT

00:00.000 --> 00:02.280
All right, good afternoon everyone, 3 p.m.

00:02.280 --> 00:04.400
It is my pleasure to introduce Ukuşen.

00:04.400 --> 00:05.980
Thank you.

00:07.840 --> 00:09.500
Hello everyone, welcome to my...

00:09.500 --> 00:11.880
By the way, can you hear my voice in the back side?

00:11.880 --> 00:12.920
It's okay, great.

00:13.260 --> 00:21.100
Welcome to my talk named Generating Personalized Word Lists with Natural Language Processing by Analyzing Tweets.

00:21.960 --> 00:23.960
Let me introduce myself first.

00:23.960 --> 00:29.460
I'm Utkuşen, I'm usually doing researches and writing tools which are about offensive side of security.

00:29.460 --> 00:32.560
I'm currently working for T-Security.

00:32.640 --> 00:38.600
You can find detailed information on my website and you can follow me on Twitter if you are interested in.

00:39.500 --> 00:44.260
In this presentation, I will start by talking about password guessing attacks.

00:44.320 --> 00:50.360
Then, I will explain why reducing the word list size is crucial for password guessing.

00:50.540 --> 00:56.000
After that, we will see how can we generate word lists based on target's personal topics.

00:56.120 --> 00:59.900
Finally, I will demonstrate the Rodeolo tool which does that job.

01:01.520 --> 01:07.520
Passwords are our main security mechanism for the digital account since the beginning of the internet.

01:07.520 --> 01:12.220
Because of that, passwords are main targets for the attackers.

01:12.220 --> 01:15.960
Of course, there are lots of different ways to gather a target's password.

01:15.960 --> 01:23.400
For example, the attacker can prepare a phishing website to trick targets into entering their credentials to a rogue website.

01:23.400 --> 01:28.920
Or an attacker can conduct a password guessing attack through brute forcing.

01:29.200 --> 01:33.320
Password guessing attacks are usually described in two main categories.

01:33.320 --> 01:36.000
They are offline and online attacks.

01:36.880 --> 01:43.740
Offline password guessing attacks are usually conducted against captured hashes or encryption keys.

01:43.740 --> 01:50.540
For example, for hash cracking, attacker calculates some password hash and compares with the target hash.

01:50.540 --> 01:55.280
There are two variables which affects the success other than the password complexity.

01:55.280 --> 01:59.640
They are hardware resources and the type of phishing algorithm.

01:59.880 --> 02:06.540
More hardware resources are providing us speed, therefore increases the chance of success.

02:06.890 --> 02:09.320
The other thing is, of course, phishing algorithm.

02:09.320 --> 02:14.580
For example, cracking an MD5 hash will be faster than cracking a bcrypt one.

02:15.580 --> 02:19.400
However, online password guessing attack is something different.

02:19.400 --> 02:33.060
In online password guessing attack, attacker sends username password combination to a service like HTTP, SSH, et cetera, and tries to identify the correct combination by checking the response from those services.

02:33.200 --> 02:37.660
There are lots of different variables which affects the chance of success.

02:37.660 --> 02:46.900
For example, our connection speed, servers bandwidth, also server can block our IP address or lock targets, accounts, et cetera.

02:46.900 --> 02:48.920
There are lots of counter measurements.

02:49.380 --> 02:53.300
Online attacks and hardware resources has no positive correlation.

02:53.300 --> 02:56.800
Therefore, it's much, much harder than offline attacks.

02:58.480 --> 03:10.020
Most of the web applications have password complexity rules where user have to use at least one number, upper level characters, and of course special character.

03:10.020 --> 03:17.420
Therefore, reducing the brute force size, brute force pull to an acceptable size is very important for the attackers.

03:17.700 --> 03:22.500
Instead of brute forcing all combinations, actually we can make some smarter choices.

03:22.500 --> 03:25.380
For example, we can try the most common passwords.

03:25.380 --> 03:29.640
If it doesn't work, we can make some smarter combinations.

03:30.920 --> 03:36.180
To reduce the combination pull, Hashcat team created a technique called mask attack.

03:36.200 --> 03:41.240
The main idea is people are choosing their passwords with similar patterns.

03:41.240 --> 03:43.260
They are not pure gibberish data.

03:43.260 --> 03:49.240
Therefore, we can define a pattern which is called mask, and we can do brute force with its boundaries.

03:49.240 --> 03:52.780
Let's say our target password is Yulia1984.

03:52.980 --> 03:58.400
With the brute force approach, we need to brute force all nine characters with all of our char sets.

03:58.400 --> 04:03.180
The formula is 9 over 62, which is a very, very big number.

04:03.780 --> 04:08.700
For the mask attack, since we defined the pattern, we don't need to brute force everything.

04:08.740 --> 04:12.300
For example, the first characters can be only upper letter.

04:12.300 --> 04:14.320
There are 29 choices.

04:14.540 --> 04:19.180
The total amount of combinations are way smaller than the pure brute force technique.

04:19.180 --> 04:21.740
It's around 200 billions.

04:22.720 --> 04:25.520
But of course, it's still too much for the online attacks.

04:25.520 --> 04:31.560
We usually can't send 200 billions requests to web application and check its response.

04:33.100 --> 04:38.580
But of course, pure brute force attack and mask attacks are not the only way for password guessing.

04:38.720 --> 04:43.140
There is also science fiction method based on smart guessing.

04:43.240 --> 04:53.640
For example, on Sherlock's Hound of Baskerville episodes, Sherlock Holmes was checking the personal stuff of the target and we're guessing the password in just one shot.

04:55.140 --> 04:58.540
So, we can talk about the third method now.

04:58.560 --> 05:06.780
It seems very unrealistic, but in theory, it's possible to find Julia 1984 password in less than three shots.

05:06.780 --> 05:09.480
We just need to have some Sherlock Holmes skills.

05:14.600 --> 05:19.080
Let's assume the target is posted a tweet and we are a Sherlock Holmes candidate.

05:19.080 --> 05:21.500
We can make following deductions.

05:21.920 --> 05:27.860
Target's author name is Julia and the target loves her so much since he or she tweets about her.

05:28.060 --> 05:33.160
And the target's favorite author is George Orwell whose most popular book is 1984.

05:33.900 --> 05:37.760
So, combine them together, the answer is Julia 1984.

05:38.380 --> 05:40.060
Is this that simple?

05:40.060 --> 05:42.160
We will come back to this later.

05:43.240 --> 05:54.280
So, according to some researchers which are conducted by Carnegie Mellon University, most of the people are choosing words from their hobbies, sports, movies, etc.

05:54.280 --> 05:55.980
for their passwords.

05:56.040 --> 06:03.640
This means that most of the user passwords contain meaningful words and they are related with the password's owner.

06:03.800 --> 06:07.900
So, in theory, we can become a Sherlock Holmes on password guessing.

06:09.280 --> 06:13.720
We can actually prove that people are mostly using meaningful words for their passwords.

06:13.960 --> 06:27.720
When we analyze leaked Myspace and Ashley Madison password lists and generate most used masks, we can see that almost 95% of those passwords are formed by sequential alphabetic characters.

06:27.720 --> 06:31.360
So, there is a high probability that these are meaningful words.

06:32.880 --> 06:36.860
Let's try to prove that they actually contain meaningful words.

06:36.900 --> 06:38.920
So, what is a meaningful word?

06:38.920 --> 06:46.400
We can say that a letter sequence is a meaningful English word if it's listed in an English lexicon.

06:46.400 --> 06:56.520
For those who are not familiar with NLP context, lexicon means that the complete set of meaningful units in a language.

06:56.580 --> 07:01.740
We used Stanford's WordNet lexicon for this job.

07:03.100 --> 07:12.340
Our analysis showed that almost 40% of those word lists are included in WordNet lexicon, hence they are meaningful English words.

07:12.360 --> 07:19.320
Now we need to apply post tagging, which means part of speech tagging, to these words to understand what kind of words they are.

07:19.760 --> 07:22.320
Post tagging is a process to find a word's class.

07:22.320 --> 07:26.540
There are eight different part of speeches in English language.

07:27.020 --> 07:29.480
For example, I learned them in English lessons.

07:29.480 --> 07:38.300
For example, for those who are not familiar with those, for example, there are nouns like table chair, there are verbs like eating, going, et cetera.

07:38.960 --> 07:48.080
So, we analyzed those words with the help of Python's NLTK library and results showed that most of these words are singular noun.

07:50.000 --> 07:53.040
So, let's recap what kind of facts that we have so far.

07:53.040 --> 07:58.840
First, our analysis showed that people are using meaningful words for their passwords.

07:58.840 --> 08:06.720
And second, from the research conducted by various universities, we know that passwords are mostly based on personal topics.

08:06.880 --> 08:10.880
So, Sherlock Holmes' method is legit in theory.

08:12.120 --> 08:14.660
But can it be done in practice?

08:15.000 --> 08:18.940
What Sherlock Holmes did was analyzing personal topics of the target.

08:19.000 --> 08:23.320
Then, he combined them in his mind and came up with a candidate password.

08:23.900 --> 08:26.440
But how can we do it in real life?

08:26.600 --> 08:34.820
To achieve this, we need the information about the target and algorithm which extracts good password candidates from that information.

08:36.060 --> 08:39.420
We need a data source just like Sherlock Holmes said.

08:39.920 --> 08:45.960
We need a source where we can find hobbies and other interest areas of the targets.

08:46.100 --> 08:48.800
And actually, we all know that kind of source.

08:49.240 --> 08:50.840
It's Twitter, of course.

08:51.260 --> 08:56.980
In Twitter, people tend to write posts about their hobbies and other interest area mostly.

08:57.020 --> 09:02.740
Since there's a character limitation for each tweet, users need to write things more focused.

09:02.740 --> 09:08.660
And this makes things easier for us because we don't need to deal with large gibberish texts.

09:08.660 --> 09:15.400
So let's use Twitter as a data source and try to build our personalized wordless generation algorithm.

09:16.900 --> 09:21.680
First of all, we need to gather tweets from target via Twitter's API.

09:22.180 --> 09:25.800
Then, we need to get rid of unnecessary data.

09:26.040 --> 09:30.360
But how do we know if a word is necessary or unnecessary?

09:30.620 --> 09:37.140
Since we're trying to find personalized things, we can remove stop words since everybody are using them.

09:37.140 --> 09:40.680
For example, we can remove things like I, my, she, etc.

09:40.680 --> 09:42.320
from the tweets.

09:42.600 --> 09:48.900
Secondly, as you recall, our research showed that people are mostly using nouns for their passwords.

09:48.900 --> 09:51.560
We can remove any verbs.

09:51.780 --> 09:55.540
For example, we removed suggest verb from the tweets.

09:56.700 --> 10:03.860
As you can remember from the previous slides, leaked word lists were mostly formed by nouns.

10:03.860 --> 10:09.480
So we can apply post tagging to the rest of the words to detect most used nouns and proper nouns.

10:09.480 --> 10:13.010
For this tweet, nouns are daughter and author.

10:13.420 --> 10:16.190
Proper nouns are George Orwell and Yulia.

10:18.420 --> 10:22.660
Sometimes users are combining two meaningful words for their passwords.

10:22.920 --> 10:26.300
But of course, they are not like two random words.

10:26.300 --> 10:28.860
They have a kind of semantic similarity.

10:29.180 --> 10:31.780
We also need to combine similar words.

10:31.900 --> 10:40.280
We used WordNet's pet similarity algorithm for detecting semantic similarity of the words which are extracted from the tweets.

10:40.560 --> 10:44.420
Pet similarity algorithm gives us a score between zero and one.

10:44.420 --> 10:48.860
And we are combining two words if their score is greater than 0.12.

10:49.340 --> 10:55.120
In the example shown in the slide, we will combine cat, dog, and flame thrower with each other.

10:57.060 --> 11:03.400
Researchers have also found that some of the most used semantic themes in passwords are locations and years.

11:03.400 --> 11:10.850
For this job, we will send the extracted nouns to Wikipedia and parse related years and cities from them.

11:11.160 --> 11:19.270
In this example tweet, we sent George Orwell to Wikipedia and it returned us words like London, 1984, et cetera.

11:20.460 --> 11:23.490
So the last step is combining all of our data.

11:23.920 --> 11:30.670
From the example tweet, we got George Orwell word, we sent it to Wikipedia, and it returned us 1984 words.

11:30.670 --> 11:33.950
Beyond that, we also had a Yulia as a proper noun.

11:33.990 --> 11:40.570
So when we combine all of our data, we will have the correct password, Yulia1984, in somewhere.

11:40.890 --> 11:47.410
So instead of millions of combinations, we could correct this password in less than 20 or less steps.

11:47.570 --> 11:50.290
So it's just like Sherlock Holmes did.

11:51.430 --> 11:56.470
So to automatize all processes, I coded a tool named Rodeola.

11:56.470 --> 12:00.290
It's written in Python and mostly based on NLTK library.

12:00.290 --> 12:04.270
It follows the algorithm that I described in the previous section.

12:04.270 --> 12:15.970
With a given Twitter handle, it can automatically compile a personalized word list with elements such as nouns, proper nouns, cities, years related to them.

12:16.330 --> 12:22.210
Currently, it only supports English language, but I will finish the Turkish and German support soon.

12:24.210 --> 12:27.270
You can use Rodeola in three different modes.

12:27.270 --> 12:35.430
In the base mode, Rodeola takes a Twitter handle as an argument and generates personalized word lists without any fancy stuff.

12:35.510 --> 12:44.910
For example, when you give Elon Musk username, it will generate passwords like Tesla, car, SpaceX, boring machine 2018, et cetera.

12:46.330 --> 12:51.510
In the regex mode, a user can generate additional strings with the provided regex.

12:51.510 --> 12:56.310
These generated strings will be appended prefix or suffix to the words.

12:56.550 --> 13:02.930
For this mode, Rodeola takes a regex value as an argument, defines the string placement.

13:03.030 --> 13:10.910
With the regex shown in the slide, it will generate passwords like Tesla root 01, Tesla root 02, and it goes like this.

13:12.170 --> 13:17.790
In the mask mode, user can provide hashcat style mask values for the word list generation.

13:18.050 --> 13:26.050
So in this example, we used mask in which first character is upper letter, second one is lower letter, and the third one is upper letter again.

13:27.290 --> 13:33.430
If you don't have any Twitter API or you want to use another data source, you can bring your own data.

13:33.830 --> 13:36.270
Rodeola provides you two different options.

13:36.270 --> 13:42.270
In the first one, you can provide a text file to Rodeola which contains lots of harvested texts.

13:42.270 --> 13:51.610
In the second one, you can provide a URL list and Rodeola harvests text from these URL automatically and will build the personalized word list right away.

13:53.110 --> 13:58.450
You can download and try the tool from our GitHub page by yourself.

14:00.630 --> 14:02.690
Okay, so demo time.

14:02.750 --> 14:12.650
To make this demo, I will get a Twitter handle from the audience, a volunteer, and we'll pass it to Rodeola and we will check its results all together.

14:12.790 --> 14:18.170
So is there anyone who are actively using Twitter in English and willing to share the username with me?

14:19.910 --> 14:20.710
Yes, sir.

14:20.710 --> 14:23.790
But let me open up my terminal first.

14:37.380 --> 14:39.460
Okay, I'm all ears.

14:43.830 --> 15:02.490
A, B, A, B, E, E, K, yep, D, E, E, all right, S, this one.

15:02.510 --> 15:06.510
Okay, let's see what we will have got.

15:07.670 --> 15:11.110
Now it's downloaded a bit from that Twitter handle.

15:11.930 --> 15:18.190
Probably it will download like 2,500 because it's Twitter's API limitation.

15:23.870 --> 15:26.870
I hope I have a internet connection right now.

15:38.900 --> 15:40.060
Weird.

15:45.810 --> 15:49.450
All right, DEF CON Wi-Fi is not working.

15:57.360 --> 16:01.020
Are there anyone who are using DEF CON Wi-Fi right now?

16:01.020 --> 16:02.680
Is it not working?

16:03.960 --> 16:06.360
They were saying they were getting rate limited earlier.

16:06.380 --> 16:07.180
Sorry?

16:07.180 --> 16:09.400
They said they were getting rate limited earlier.

16:09.400 --> 16:10.360
The Wi-Fi?

16:10.360 --> 16:11.180
Yeah.

16:11.280 --> 16:12.140
Weird.

16:12.580 --> 16:18.080
Actually, it was working for like three days and it just stopped in my presentation.

16:19.900 --> 16:24.320
Anyway, but I want, it can't stop me, you know?

16:24.320 --> 16:26.300
I will use my hotspot.

16:27.800 --> 16:28.920
Sorry?

16:29.400 --> 16:30.640
DEF CON open.

16:33.960 --> 16:35.980
Nah, it's rogue Wi-Fi, right?

16:36.640 --> 16:42.670
Come on.

16:45.330 --> 16:46.210
Yep.

16:54.600 --> 16:55.440
Yep.

16:55.440 --> 16:57.360
Now we have a working Wi-Fi.

17:04.050 --> 17:05.310
Come on, man.

17:13.980 --> 17:14.700
No internet?

17:14.700 --> 17:15.280
Yeah.

17:15.460 --> 17:16.340
Okay.

17:16.540 --> 17:17.320
Great.

17:19.580 --> 17:21.840
I hope we can find your password then.

17:37.110 --> 17:38.750
Yeah, you have lots of tweets, sir.

17:39.410 --> 17:41.290
Too late.

17:44.070 --> 17:45.230
Sorry?

17:48.830 --> 17:52.630
Actually, it can't do that at this moment.

17:52.630 --> 17:55.250
It just downloads like 2,000 tweets.

17:55.250 --> 17:58.530
Actually, it will complete in a second, probably.

17:59.970 --> 18:02.070
Yeah, good idea.

18:02.990 --> 18:08.950
Actually, it downloads faster, but because of my internet connection, it's a little bit slow.

18:08.950 --> 18:09.950
No, okay.

18:09.950 --> 18:19.550
Now it analyzes the downloaded tweets and we'll get like most used nouns, proper nouns, and we will see them in a second.

18:32.190 --> 18:33.110
Okay.

18:33.490 --> 18:41.970
So, most used nouns are, wow, giants, let's hope, let's go giants.

18:41.970 --> 18:44.610
So is there like sport team or something?

18:44.610 --> 18:45.390
Yeah.

18:45.390 --> 18:45.950
Yeah .

18:48.710 --> 18:53.430
United, Manchester United, NFL.

18:53.770 --> 18:55.990
So does this make sense to you?

18:55.990 --> 18:56.630
Yes.

18:56.630 --> 18:57.430
Great.

18:57.430 --> 18:59.210
These are the things I dreamed about.

18:59.210 --> 19:00.310
No.

19:01.430 --> 19:08.230
Okay, now it sent those words to Wikipedia and parsed related locations and years from them.

19:08.230 --> 19:11.170
And let's see what kind of passwords we have.

19:12.490 --> 19:13.210
So.

19:15.390 --> 19:16.150
Uh.

19:18.690 --> 19:20.330
I don't know.

19:24.180 --> 19:25.460
Actually.

19:26.800 --> 19:37.620
Now, I don't know the reason, but it couldn't parse related years, but it should have, probably because of main connection or something.

19:38.220 --> 19:41.720
So, sir, is your password listed in this word list?

19:41.880 --> 19:44.180
Could you please take a look again?

19:44.180 --> 19:44.980
No?

19:45.640 --> 19:52.640
All right, so of course it will be a miracle to create a password with this method to a DEF CON attendee.

19:52.920 --> 19:56.360
All right, so let's turn back to the slide again.

20:02.190 --> 20:03.150
Right.

20:05.650 --> 20:08.230
Anyway, I can stop the mirror.

20:08.970 --> 20:30.550
Anyway, so as a conclusion, since people tend to use words from their hobbies, movies, sports, et cetera, for their passwords, users should not use these words for their passwords since we can create some kind of accurate word list with given data.

20:30.670 --> 20:39.270
Beyond that, any actor that has much more data about that person will have an ability to create more accurate word lists for the target people.

20:39.450 --> 20:48.430
So people should avoid using those kind of times in their passwords and should use password manager with random passwords.

20:48.670 --> 20:51.690
So that's all I have today.

20:51.690 --> 20:53.970
Thank you coming for listening to me.

20:57.810 --> 21:00.330
So are there any questions?

21:00.670 --> 21:01.830
Yes, please, sir.

21:08.680 --> 21:10.460
What kind of list?

21:15.090 --> 21:16.630
Yeah, yeah, of course.

21:16.630 --> 21:19.690
They are leaked MySpace and HLM medicine word lists.

21:19.690 --> 21:26.950
So when you analyze them with the pack tool, you can find it on GitHub, you will see the same statistics.

21:27.830 --> 21:29.910
So yeah, please.

21:35.140 --> 21:39.560
Yeah, currently you can't do that, but in future I will do that.

21:39.560 --> 21:46.000
Because since it's some kind of experimental project, I didn't want to limit, you know, password length.

21:48.900 --> 21:49.820
Please.

22:03.210 --> 22:04.330
Yeah.

22:07.590 --> 22:10.010
To be honest, zero.

22:11.310 --> 22:19.670
Yeah, of course I couldn't crack any like, for example, my friends are using mostly, you know, complex passwords, etc.

22:19.670 --> 22:22.530
And I couldn't crack any of these passwords.

22:22.530 --> 22:31.110
But when you try it on your, for example, mother or, you know, some older person or some not ungeek person, it may work.

22:31.110 --> 22:32.110
So.

22:33.870 --> 22:34.450
Yeah.

22:40.190 --> 22:45.610
But I need to know the real identity of the targets.

22:45.610 --> 22:53.210
So I need to get like their hobbies, their something and like cross check with all of them.

22:53.890 --> 23:02.110
But if only I know the correct real identity of the MySpace word lists, probably your method will work.

23:02.110 --> 23:05.290
But actually it can be done in Html medicine word lists.

23:05.290 --> 23:08.770
Probably their real identity is already revealed.

23:09.090 --> 23:10.570
Maybe I can check them, yeah.

23:11.210 --> 23:11.890
Please.

23:20.820 --> 23:23.440
Good idea, actually, I haven't thought about that.

23:23.440 --> 23:24.500
Yeah, good idea.

23:26.820 --> 23:30.680
So there's, as far as I can see, there's no question.

23:30.680 --> 23:31.160
Thank you.

23:31.160 --> 23:32.500
Yeah, there's a question.

23:34.680 --> 23:38.080
I use Python's NLTK library mostly.

23:39.420 --> 23:40.200
Sorry?

23:41.020 --> 23:46.740
I only know Python supports, probably it only has Python support.

23:47.620 --> 23:50.800
So wasn't that your answer?

23:52.640 --> 23:54.040
Only Python.

23:56.040 --> 23:58.720
Only English, only English, yeah.

23:58.720 --> 24:06.720
Actually, I think it's kind of supports French or Spanish, but they are not strong as English one.

24:07.440 --> 24:15.980
So you need, if you are working on a different language, you need to find some local implementation for the NLP stuff.

24:19.420 --> 24:21.940
Actually, each language has own websites.

24:21.940 --> 24:30.760
So for example, for Turkish language, there's, I can download some items from university websites, but I didn't research about the other language.

24:30.760 --> 24:34.920
But there is no single place that you can download everything.

24:37.530 --> 24:38.810
Okay, so that's all.

24:38.810 --> 24:39.510
Thank you.

