Authorship Verification and Obfuscation Using Distributional Features Bachelorβs Thesis Defense by Janek Bevendorff Date: 27. October 2016 Referees: Prof. Dr. Benno Stein PD Dr. Andreas Jakoby
What Is Authorship Verification? Authorship Identification Reference Texts Verification Attribution ? ? May solve π’ 1 π’ 2 π’ 1 π’ 2 π’ 3 27. October 2016 2
What Is Authorship Obfuscation? βGiven two documents by the same author, modify one of them so that forensic tools cannot classify it as being written by the same author anymore.β β β π’ 1 π’ 2 27. October 2016 3
Reasons for Obfuscating Authorship ο General privacy concerns ο Protection from prosecution ο Anonymity of single / double blind reviews ο Style imitation (writing contests) ο Impersonation (malicious intents) ο β¦ 27. October 2016 4
Corpus Setup Used corpus: PAN15 Corpus (English) ο Training / test: 100 / 500 cases ο Two classes with balanced number of cases ο Each case consists of two documents either by the same or different author(s) ο Test documents have 400-800 words on average Class: βsame authorβ Class: βdifferent authorsβ β β 50% 50% 27. October 2016 5
Reference Classifier Decision tree classifier with 8 features: ο Kullback-Leibler divergence (KLD) ο Skew divergence (smoothed KLD) ο Jensen-Shannon divergence ο Hellinger distance ο Cosine similarity with TF weights ο Cosine similarity with TF-IDF weights ο Ratio between shared n-gram set and total text mass ο Average sentence length difference in characters The first 7 features use character 3-grams 27. October 2016 6
Classification Results Classification Accuracy (c@1) 78.00% 76.00% 74.00% 72.00% 76.8% 70.00% 75.7% 68.00% 69.4% 66.00% 64.00% Reference Classifier PAN15 Winner PAN15 Runner-Up 27. October 2016 7
Obfuscation Idea (1) ο Attack KLD as main feature ο Assumes other features not to be independent π[π] KLD(π||π ) = π[π] log 2 π [π] π KLD Definition Variables: ο π : n-gram appearing in both texts π’ 1 and π’ 2 ο π[π] : relative frequency of n-gram π in the portion of π’ 1 whose n-grams also appear in π’ 2 ο π [π] : analogous to π[π] 27. October 2016 8
KLD Properties ο KLD range: [0, β) ο KLD = 0 for identical texts ο PAN15 corpus: 0.27 < KLD < 0.91 ο KLD only defined for n-grams where π π > 0 ο PAN15 corpus: at least 25% text coverage by only using n-grams that appear in both texts 27. October 2016 9
Obfuscation Idea (2) Idea: obfuscate by increasing the KLD ο Assumption: not all n-grams are equally important for the KLD ο Only touch those with highest impact ο High-impact n-grams can be found by KLD summand derivative: π π π ππ π log 2 = β π π ln 2 KLD Summand Derivative where π and π denote probabilities π[π] and π [π] for any defined π 27. October 2016 10
Obfuscator Implementation Only need to consider the (modifiable) n-gram π that maximizes π[π] π [π] Three possible obfuscation strategies: N-gram π in π’ 1 : β¦ β¦ N-gram π in π’ 2 : β¦ β¦ - + I: Reduction II: Extension III: Hybrid 27. October 2016 11
Obfuscation Results 27. October 2016 12
Obfuscation Results 27. October 2016 13
Obfuscation Results 27. October 2016 14
Obfuscation Results 27. October 2016 15
Obfuscation Results 27. October 2016 16
Obfuscation Results 27. October 2016 17
Obfuscation Results 27. October 2016 18
Obfuscation Results Observation Hybrid: accuracy rises despite KLD increase Possible explanation: adding n- grams improves other features. Cross-validation with single features confirms explanation: Baseline Accuracy 20 Iterations KLD 67.2% 51.4% TF-IDF 74.4% 82.2% Solution: only use reductions 27. October 2016 19
Results Analysis ο Significant KLD increase possible with only few iterations ο KLD histograms fully overlap after 10-20 iterations (~2% of text modified) ο Overall classification accuracy down to ~66% ο Extensions are problematic for TF-IDF 27. October 2016 20
Corpus Flaws Results promising, but corpus appears to be flawed ο Very short texts ο Test corpus much larger than training corpus ο Corpus-relative TF-IDF very strong feature (discrimination by topic) ο Only chunks of 15 different stage plays by 5 unique authors ο No proper text normalization 27. October 2016 21
Development of New Corpus New corpus was developed with books from Project Gutenberg: ο 274 cases from three genres and two time periods ο Authors unique within genre / period ο Avg. text length of 4000 words (few exceptions) ο Proper text normalization ο 70 / 30 split into training / test (192 / 82 cases) 27. October 2016 22
Classifier Changes Cosine similarity (TF and TF-IDF) features were removed to avoid accidental classification by topic 27. October 2016 23
Classification Results Classification Accuracy (c@1) 85.00% 80.00% 75.00% 70.00% 79.4% 72.0% 71.5% 65.00% 63.4% 60.00% Before Obfuscation After 160 Obfuscation Iterations Reference Classifier PAN15 Winner 27. October 2016 24
Summary ο Medium / high classification accuracy with only simple features ο Obfuscation possible by attacking main feature ο Results reproducible on more diverse corpus ο Obfuscation also works against other verification systems 27. October 2016 25
Future Work ο Improve classifier by ο β¦adding more features ο β¦integrating βUnmaskingβ by Koppel and Schler [2004] ο Attack more features ο Use paraphrasing ο Randomize obfuscation to harden against reversal 27. October 2016 26
Thank you for your attention
Recommend
More recommend