




版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請(qǐng)進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡(jiǎn)介
1、Program ObfuscationXU, Hui August 6, 2022COMP130159.011. Overview2The Problem of Software IP ProtectionExamples of MATE attacks:Disable License CheckingSteal AlgorithmsClone Codesif (verifyLicense (key) startProgram();else printf (“invalid key”); exit(-1);Software intellectual property:Server side (
2、secure)Client side (vulnerable)MATE (Man-At-The-End) attack Collberg11: reverse engineerCollberg11 C. Collberg, et al. Toward digital asset protection. IEEE Intelligent Systems, 2011.3Software Obfuscation for IP ProtectionC. Collberg, et al. A taxonomy of obfuscating transformations, 1997Obfuscator:
3、 a program that transforms the application into one that is functionally identical to the original but which is much more difficult to understand.Evaluation CriteriaPotency: to what degree is a human reader confusedResilience: how well are automatic deobfuscation attacks resistedCost: how much overh
4、ead is added to the applicationStealth: how well does obfuscated code blend in with the original code42. Software Obfuscation5Obfuscation TargetComponents6 pile Java Bytecode is EasyAPKjd-guiunzipdex2jarview7Software ObfuscationLexical obfuscationUse meaningless identifiers to replace meaningful one
5、s,Typically with alphabets or short random strings.Control-flow obfuscationIncrease the complexity of the control-flow graph, e.g., by adding bogus control flows.Data obfuscationOriginal programDifferent Versions of obfuscated programYadegari, et. al, A Generic Approach to Automatic Deobfuscation of
6、 Executable Code, S&P 20158Lexical ObfuscationWhat lexical information can be scrambled?Variable nameMethod nameField namePerform a def-use analysis for each identifier to obfuscate.Make sure both def and use are changed Try it yourself via static data-flow analysisWhat cannot be changed?Identifiers
7、 defined by other libraries9Obfuscating Android Apps During CompilationClassic tool: ProGuardLatest tool in Android Studio: R810Effectiveness of Obfuscation11Residual Informationresidual information“We can recover a large portion of lexical information based on the residual information, e.g., names
8、of invoked methods and strings.”B. Bichsel, et al. Statistical deobfuscation of android applications, CCS, 2016.Java Source CodeJava APIThird-party LibrariesAndroid Framework APIinvocation12How to Obfuscate ponent Information?Use call wrappers and dispatchersOriginal VersionObfuscated Version3-rd pa
9、rty libraryfunA()funB()funC()Java ClassfunB()invoke3-rd party libraryfunA()funB()funC()Java Classdispatcher()invokeWrapper Classdispatcher()invoke13Control-flow ObfuscationIncrease the (Cyclomatic) complexity of the program withBogus control flowControl-flow flatteningE = the number of edges of the
10、graph.N = the number of nodes of the graph.P = the number of connected components.ababbogusccdispatcherabc14Obfuscation with Obfuscator-LLVM -mllvm -bcf: activates the bogus control flow pass-mllvm -bcf_loop=3: if the pass is activated, applies it 3 times on a function. Default: 1-mllvm -bcf_prob=40
11、: if the pass is activated, a basic bloc will be obfuscated with a probability of 40%. Default: 30Use LLVM to compile C programs with the following arguments:Other features in Obfuscator-LLVMControl-flow flatteningInstructions substitution15Bogus Control FlowP. Junod, et. al, Obfuscator-LLVM - Softw
12、are Protection for the Masses, 2015If-elseadd junk codes16Opaque Predicate Used in Obf-LLVMx7 = 0;y8 = 0;if(x7(x7 1)%2 = 0|y81) if(x%2=1) x=3*x+1; else x = x/2; if (x = 1) /always reachable OriginalCode();20Relationship with Symbolic Executionint opaque(int x) int *p=&x; int*q=&x; int y=0; if(x*x3)/
13、contextual opaque predicate if(x*x-4x+30) x=x1; if(*p)%2=0)/dynamic opaque predicate y=x+1; else y=x+1; y=y+2; if(*q)%2=0) y=y+2; x=y+3; else x=y+3; return x;Use symbolic execution to analyze these path constraints21Control-Flow Flatteningif-elsewhile+switch-caseFlattening22Control-Flow FlatteningLs
14、zl, Tmea, and kos Kiss. Obfuscating C+ programs via control flow flattening. 200923VM-based ObfuscationCamouflage widely used by malware.Convert x86 machine code into virtual machine bytecode and execute it at runtimeAvailable tools: VMProtectCode VirtualizerRolfRolles x86 Virtualizer 24Virtualizati
15、on Virtualization25VM Section263. Theoretical Limitations27Program ObfuscatorB. Barak et al., On the (im) possibility of obfuscating programs, CRYPTO, 200128Theoretical Limitation of ObfuscationVirtual block-box property (VBBP): The obfuscated program does not help in determine the program result (e
16、ven leaks 1-bit information) than given only oracle access.VBBP is not always possible.B. Barak et al., On the (im) possibility of obfuscating programs, CRYPTO, 200129Proof VBBP with A Counter ExampleProof by contraction. Details can be found in Baraks paper.B. Barak et al., On the (im) possibility
17、of obfuscating programs, CRYPTO, 200130Indistinguishable Property31Idea for Achieving IOS. Garg et al., Candidate indistinguishability obfuscation and functional encryption for all circuits, FOCS 201332Convert to Branching Programs1s2s9s3s4s5s6s7s800011111bit1s1011000001bit2bit3bit4bit5bit6bit7bit8i
18、f(x = 7) return 1;else return 0;Example: convert a point function33Convert to Matrix Branching Programsmatrices for bit1head matrixtail matrix34MBP Randomization35Encrypt RMBP with Graded EncodingCandidate algorithms: GGH, CLTEncrypt each element with a key, like public key encryption.The computatio
19、n is noisy (non-deterministic) by introducing some small integers.The final evaluation function (zero-testing) is deterministic.Far from practical usage Results achieved when encrypting a point function.Lewi, et al. 5gen: A framework for prototyping applications using multilinear maps and matrix branching programs.“CCS 2016.36Comparison of The Two FieldsPROGRAM OBFUSCATOR(THEORETICAL)CODE OBFUSCATORRESEARCH COMMUNITYtheory scientistssoftware scientistsTarget Programcircuit/Turing-Machinec
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請(qǐng)下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請(qǐng)聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會(huì)有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲(chǔ)空間,僅對(duì)用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對(duì)用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對(duì)任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請(qǐng)與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對(duì)自己和他人造成任何形式的傷害或損失。
最新文檔
- 會(huì)展產(chǎn)品合同范本
- 出口種子銷售合同范本
- 轉(zhuǎn)賣音響合同范本
- 勞務(wù)外包合同范例
- 中介委托租房電子合同范本
- 凱倫股合同范本
- 養(yǎng)牛合伙合同范本
- 北海吊車出租合同范本
- 公司中途入股合同范本
- 產(chǎn)品服務(wù)合同范例
- 2025年國家自然科學(xué)基金委員會(huì)招聘流動(dòng)編制人員59人歷年高頻重點(diǎn)模擬試卷提升(共500題附帶答案詳解)
- 寧波2025年浙江寧波市鄞州區(qū)衛(wèi)健系統(tǒng)其他事業(yè)單位招聘事業(yè)編制46人筆試歷年參考題庫附帶答案詳解
- 2025江蘇太倉市城市建設(shè)投資集團(tuán)限公司招聘易考易錯(cuò)模擬試題(共500題)試卷后附參考答案
- 小學(xué)二年級(jí)數(shù)學(xué)上冊(cè)口算題
- 2025年個(gè)體戶合伙投資協(xié)議(三篇)
- 2024-2025學(xué)年第二學(xué)期(2025春季學(xué)期)學(xué)校工作計(jì)劃(附2月-6月安排表)
- 14磁極與方向(教學(xué)設(shè)計(jì))-二年級(jí)科學(xué)下冊(cè)(教科版)
- 2025年山西經(jīng)貿(mào)職業(yè)學(xué)院高職單招職業(yè)技能測(cè)試近5年常考版參考題庫含答案解析
- 廣東省佛山市禪城區(qū)2024-2025學(xué)年八年級(jí)上學(xué)期期末考試語文試題(含答案)
- 第04課 輸入輸出與計(jì)算(說課稿)2024-2025學(xué)年六年級(jí)上冊(cè)信息技術(shù)人教版
- 小學(xué)教師讀書分享活動(dòng)課件
評(píng)論
0/150
提交評(píng)論