




下载本文档
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
第八届“认证杯”数学中国编号专用页参赛队伍的参赛队号:(请各个参赛队提前填写好竞赛统一编号(由竞赛送至评委团前编号竞赛评阅编号(由竞赛评委团评阅前进行编号数学建模网络赛第一阶段替换替换关键 替换式破译频率分析单字母替 要以采取的较好的策略是穷搜索。但如果密文很长,我们采用的方式是对密文中的字得到的几张字母替换表,就可以最终确定部分的字母替换规定。以上步骤,编写参赛队号所选题目 英要(选填Inoccasionthatattackerisassumedtohaveaccessonlytoasetofciphertexts,theonlymodelcouldbeassumeisciphertext-onlyattack.Insituationwhereciphertextisrelativelyshort,thebetterstrategyisbrute-search.Howeverinsituationciphertextisrelativelylong,theattackmodetoadoptistomakestatisticalysisoffrequenceoflettersincypertext:collectstatisticsseparayofthetimeseachsingleletterandtwoconsecutivelettersappearintheciphertext,aswellasthetimeseachletterinalphabetholdsthefirst,second,thirdandthelastpositionofeachword,rankthemandcompareitsorderwiththeLetterFrequency,recementchartsofcorrespondentlettersshallbemadeaccordingtothat.Finally,comparetherecementchartswhichwasobtainedpreviouslyincertainrules,shalltherecementrulesoflettersbepartiallydefined.Forpreviousprocedures,wemadealgorithmofthemandcomputedthembyprogrammingwithC-.Ontheotherhand,forthoselettersleftuncertaininciphertext,artificialjudgementshallbehelpfulwiththewritingregulationofEnglishwords.Atthispoint,theentirerecementchartsisaccessible,accordingtowhich,theciphertexthasbeentransformedintointext,soastofinishtheworkofdecipherment.Intheevaluationofitonthecrackmodel,wecombinetheprincipleandtheprogramdesignoftheprogrammingandoperationsituation,identifiedthefollowingthreeevaluationcriteria:"Thenumberofletterswecandetermineinthetable".Infact,themainrulesadoptedinthemodelandthecombinationsofruleswillmakeusgetdifferentlettersubstitutiontable,sothenumberofletterswecandeterminewillbedifferent.Generally,themorerecementaprogramcando,thehigherprecision ewecanget."Timetheprogramneedtogetthelettersubstitutiontable".Thepasswordcrackingperformancetestdependsonthetimesoperationcanrunonaspecifiedtimeaswell.Therefore,soinourmodel,weaddaprogramtocalculatetherunningtimeofthemainprogram(inmilliseconds).Inasense,thelesstimeittakes,thestrongeritis."Thereliabilityofdecodedintext".Theultimategoalistodecipherthemodelandgettheintextthatweneed.Therefore,thereliabilityofdecodedintextisalsothekeypointwhatweconcernof.Consideringthelimitationsofthecomputer,inthisprocess,wewilltesttheworderrorrate,grr,andtheexpressionofsentencesbyourselves.Andthatisastandardastheassessmentofthemodel.Key:Recetypepassword,Cryptysis,Frequencyysis,Singleletter替换式法,但由于其容易被,所以在现代需要加密的场合已经很少使用。如免费的COCA1等相关资料。模型的假设与符号的说模型的假设符号的说明26i字母出现的第i个位置上的符号(包含字第i个位置上的问题一的分析够采取的方式是唯密文。1】FrequenciesofthelettersintheEnglishlanguage(最常用英文字母频率):ETA,O,I,N,S,H,R,D,L,C,U,MW,F,GYP,BVK,J,X,Q,Z3】Themostcommonfirstletterinawordinorderoffrequency(单词中最常见的首T,O,A,W,B,C,D,S,F,M,R,H,I,Y,E,G,L,N,O,U,J,4】Themostcommonsecondletterinawordinorderoffrequency(单词中最常见H,O,E,I,A,U,N,R,5】Themostcommonthirdletterinawordinorderoffrequency(单词中最常见的E,S,A,R,N,6】Themostcommonlastletterinawordinorderoffrequency(单词中最常见的末E,S,T,D,N,R,Y,F,L,O,G,H,A,K,M,P,U,【规则7】Themostcommondigraphsonorderoffrequency(最常用的双连字母):TH,HEANINER,ON,REED,ND,HAATEN,ES,OF,NTEA,TITO,IO,LE,IS,OU,AR,AS,DE,RT,VE,ON,ST,NT,NG,OR,ET,IT,AR,TE,问题二的分析个标准评估我们模型破译能力:密文破译后的准确性就越高。在这样的事实下,“程序运行所得的字母替换表中确定的替换的个数的多少”作为我们评估模型破译能力的第一条标准。1000问题一模型的建立与求解lwnsozbnwvwbaybnvbsqwvwohwdizwrb,bnpbpoouwrpawxawpbwzwmypo,bnpbbnwjpawwrzslwzqjbnwiaxawpbsalibnxwabpiryrpoiwrpqowaienbv,bnpbpusrebnwvwpawoihw,oiqwabjprzbnwfyavyibshnpffirwvv.bnpbbsvwxyawbnwvwaienbv,esdwaruwrbvpawirvbibybwzpusreuwr,zwaidirebnwiatyvbfslwavhasubnwxsrvwrbshbnwesdwarwz,bnpblnwrwdwaprjhsaushesdwaruwrbqwxsuwvzwvbayxbidwshbnwvwwrzv,ibivbnwaienbshbnwfwsfowbspobwasabspqsoivnib,przbsirvbibybwrwlesdwaruwrb,opjireibvhsurzpbisrsrvyxnfairxifowvprzsaeprikireibvfslwavirvyxnhsau,pvbsvwwuusvboicwojbswhhwxbbnwiavphwbjprznpffirwvv.fayzwrxw,irzwwz,lioozixbpbwbnpbwsdwaruwrbvosrewvbpboivnwzvnsyozrsbbwxnprewzhsaoienbprzbaprviwrbxpyvwv;przpxxsazireojpoowaiwrxwnpbnvnwlr,bnpbuprcirzpawusawzivfsvwzbsvyhhwa,lniowwdiovpawvyhhwapbow,bnprbsaienbbnwuvwodwvbjpbsoivnirebnwhsauvbslnixnbnwjpawpxxyvbsuwz.qyblnwrposrebapirshpbyvwvprzyvyafpbisrv,fyavyireirdpaipbojbnwvpuwsbtwxbwdirxwvpzwvierbsawzyxwbnwuyrzwapbvsoybwzwvfsbivu,ibivbnwiaaienb,ibivbnwiazybj,bsbnaslshhvyxnesdwaruwrb,przbsfasdizwrwleypazvhsabnwiahybyawvwxyaiby.说,单词中e出现的频率比x的频率要大得多。在该模型中,我们首先分析密文中单个字记出现的频数记为i,然后成对列出i和i。再选用由Beker和Piper统计得出的Beker-Piper字母频率表(见表1),将上述统计出的各字母频数iBeker-Piper字母频率表,得出由单表 Beker-Piper字母频率abcdefghijklmnopqrstuvwxyz下面,我们用所给密文进行第一轮演示:(程序见附件高到低的顺序排列,根据Beker-Piper字母频率表,给出单个字母替换图(见图1),并制成表格(见表2)。图 单个字母频率分析运行AB FGHNT GXUIJ NOPHB RLAQR VWXVS IEMYZCD在英文中由单个字母组成的单词只有ai,具有很大的特殊性。由于密文中保留了单词间的空格及标点符号,所以,我们可以根据在第i个位置上的符号(包含字母、若i1和i1均为空格或标点,则输出i上的字母,该字母对应明文中的字母a或者字母i。下面,我们用所给密文进行第二轮演示:(程序见附件图 单字母单词分析运行表 单字母单词替换密文字母 明文字母 或密文字母 明文字母 换,现在我们需要做的是观察双连字组合的频率。这里,密文中第i个位置上的再根据【规则7】,将双连字母ii1的频数按由高到低的顺序依次对应到双连字母频率表下面,我们用所给密文进行第三轮演示:(程序见附件图 双连字母频率分析运行 字母多出现T,O,A,W等,第二位出现字母H,O,E,I,A的频率计较高,以此类CF程序统计各个字母重复出现的次数,即统计i3】,将首下面,我们用所给密文进行第四轮演示:(程序见附件图 首字母频率分析运行 P SWFH O BCDSLFOMZRAHEIXYUENGQRYTCDLNOUJK图 第二位字母频率分析运行表 第二位字母替换AABRCDEFGHTIJKLMNOPUHQRSTUVWXEOIYZN图6 AB FGHNIJ NOPSQR VWXREIYZA图 末字母频率分析运行末字母替换密文字母ABCDEFGH明文字母NSUWLO密文字母IJKLMNOP明文字母YKGAM密文字母QRSTUVWX明文字母FRHTE密文字母YZ明文字母PD根据表2至表8的对应结果,以及频率的规则,我们先取各表频数最高的两位,比对的替换判断为正确替换。由此得到7对替换。单词结果见图8),并制成表格(见表9)。图 单词匹配分析运行AB FGHRT FIJ NOPIYWHLAQR VWXBN SECYZUD根据表2至表8,我们能大致确定一些字母的替换(见表9),由此我们可以知道密文中还F、G、K、M、T5个字母没有确定,明文中则剩下J、P、Q、X、Z5个字母。现在,借助英文单词书写规律进行人工确定。happinessFP替换。以此类推,我们可以推出ABCDEFGHRTKVGPXFIJKLMNOPIYZWQHLAQRSTUVWXBNOJMSECYZUD问题二模型的建立与求解破译率替换出的字母个数字母总80.77%。此后,我们也用该程序试验过几篇密文,其破译率维持在80%左右,可见,此程序的破译能力较高。9weholdthesetruthstobeself-evident,thatallmenarecreatedequal,thattheyareendowedbytheircreatorwithcertainunalienablerights,thatamongthesearelife,libertyandthepursuitofhappiness.thattosecuretheserights, ernmentsareinstitutedamongmen,derivingtheirjustpowersfromtheconsentoftheerned,thatwheneveranyformof esdestructiveoftheseends,itistherightofthepeopletoalterortoabolishit,andtoinstitutenewernment,layingitsfoundationonsuchprinciplesandorganizingitspowersinsuchform,astothemshallseemmostlikelytoeffecttheirsafetyandhappiness.prudence,indeed,willdictatethaternmentslongestablishedshouldnotbechangedforlightandtransientcauses;andaccordinglyallexperiencehathshewn,thatmankindaremoredisposedtosuffer,whileevilsaresufferable,thantorightthemselvesbyabolishingtheformstowhichtheyareaccustomed.butwhenalongtrainofabusesandusurpations,pursuinginvariablythesameobjectevincesadesigntoreducethemunderabsolutedespotism,itistheirright,itistheirduty,tothrowoffsuchernment,andtoprovidenewfortheirfuture e,用此类的文章作为明文的密不适用本模型。参考文吴干华.基于频率分析的代替破译方法及其程序实现[J].福建电脑王彩霞 分析中几种方法的研究及其设计与实现[D].西学吴俊杰.的编制与破译:破译时间的研究[J].中国教育,2014,19:78-#include<stringh>constintmax_L=1000;voidmain(){inttext_a[26];charinti,j,k,max;}for(i=0;i<26;i++)text_a[i]=0;//初始intlen=strlen(text1);{}}{printf("%c的个数为}{if(text_a[i]>text_a[max])}}%c} }}{}}}#include<stringh>charchar*{returnNULL;inti=0;{}char*p;return}void{char*p;}}#include<stringh>constintletter_num=26;constintmax_L=1000;intmain(){charchartext_b[letter_num*letter_num][3]={"TH","HE","AN","IN","ER","ON","RE","ED","ND","AT","EN","ES","OF","NT","EA","TI","TO","IO","LE","IS","OU","AR","AS","DE","VE","ON","ST","NT","NG","OR","ET","IT","AR","TE",inti,j,k,l,max1,max2; for(inti=1;i<max_L;i++)intlen=strlen(text1);{if(text1[i]>='a'&&text1[i]<='z'&&}}{//printf("%c的个数}for(i=0;i<len-{{{{}}} text_a[max1][max2]=-}} } }for(j=0;j<38-{}if(j==38-{}{}}
return0;}【首字母频率分析】(第二位、第三位字母频率分析程序中改变代码中 的值intflag=1;intflag2=0;charchar*{char*p;inti=0;{}return}int{charinput[100];inttext_a[26],i,j;char*p; intmax;intk=p[flag-1]-'a';} printf("%c\个数为}{printf("%c的个数为}{} {}{}}
printf("%c-->%c\n",text_falg2[i],text_flag[flag-printf("%c-->#include<stringh>intflag=1;intflag2=-1;charchar*{char*p;inti=0;{}returnp;}int{charinput[100];inttext_a[26],i,j;char*p; intmax;intk=p[flag-1]-'a';} }{printf("%c的个数为}{} {}{}}
printf("%c-->%c\n",text_falg2[i],text_flag[flag-printf("%c-->#in
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- GB/T 7037-2025载重汽车翻新轮胎
- 公司房屋装修合同正式合同范本
- 全新人身意外伤害保险合同范本
- 外币贷款合同书标准格式
- 有关终止合作合同的通知书
- Module 3 unit 3 language in use教学设计2024-2025学年外研版八年级英语上册
- 杭州市房地产买卖居间合同
- 酒店股份转让合同
- 企业与个人投资合作合同范本
- 拆迁项目旧房拆除合同书模板
- 建函201521号 广铁集团建管处关于发布《邻近营业线施工物理隔离防护办法》的通知
- 写作必备制造悬念的145个方法
- 一年级下册劳动教案
- 付款申请英文模板
- 大同大学综测细则
- 生活会前谈心谈话提纲
- 比较思想政治教育(第二版)第十二章课件
- 普通外科常见疾病临床路径
- 人教版九年级下册初中英语全册作业设计一课一练(课时练)
- 2021新版GJB9001C-2017体系文件内审检查表
- 风筛式清选机的使用与维护
评论
0/150
提交评论