testmgr.h 456 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486
  1. /*
  2. * Algorithm testing framework and tests.
  3. *
  4. * Copyright (c) 2002 James Morris <jmorris@intercode.com.au>
  5. * Copyright (c) 2002 Jean-Francois Dive <jef@linuxbe.org>
  6. * Copyright (c) 2007 Nokia Siemens Networks
  7. * Copyright (c) 2008 Herbert Xu <herbert@gondor.apana.org.au>
  8. *
  9. * Updated RFC4106 AES-GCM testing. Some test vectors were taken from
  10. * http://csrc.nist.gov/groups/ST/toolkit/BCM/documents/proposedmodes/
  11. * gcm/gcm-test-vectors.tar.gz
  12. * Authors: Aidan O'Mahony (aidan.o.mahony@intel.com)
  13. * Adrian Hoban <adrian.hoban@intel.com>
  14. * Gabriele Paoloni <gabriele.paoloni@intel.com>
  15. * Tadeusz Struk (tadeusz.struk@intel.com)
  16. * Copyright (c) 2010, Intel Corporation.
  17. *
  18. * This program is free software; you can redistribute it and/or modify it
  19. * under the terms of the GNU General Public License as published by the Free
  20. * Software Foundation; either version 2 of the License, or (at your option)
  21. * any later version.
  22. *
  23. */
  24. #ifndef _CRYPTO_TESTMGR_H
  25. #define _CRYPTO_TESTMGR_H
  26. #include <linux/netlink.h>
  27. #include <linux/zlib.h>
  28. #include <crypto/compress.h>
  29. #define MAX_DIGEST_SIZE 64
  30. #define MAX_TAP 8
  31. #define MAX_KEYLEN 56
  32. #define MAX_IVLEN 32
  33. struct hash_testvec {
  34. /* only used with keyed hash algorithms */
  35. char *key;
  36. char *plaintext;
  37. char *digest;
  38. unsigned char tap[MAX_TAP];
  39. unsigned char psize;
  40. unsigned char np;
  41. unsigned char ksize;
  42. };
  43. struct cipher_testvec {
  44. char *key;
  45. char *iv;
  46. char *input;
  47. char *result;
  48. unsigned short tap[MAX_TAP];
  49. int np;
  50. unsigned char fail;
  51. unsigned char wk; /* weak key flag */
  52. unsigned char klen;
  53. unsigned short ilen;
  54. unsigned short rlen;
  55. };
  56. struct aead_testvec {
  57. char *key;
  58. char *iv;
  59. char *input;
  60. char *assoc;
  61. char *result;
  62. unsigned char tap[MAX_TAP];
  63. unsigned char atap[MAX_TAP];
  64. int np;
  65. int anp;
  66. unsigned char fail;
  67. unsigned char novrfy; /* ccm dec verification failure expected */
  68. unsigned char wk; /* weak key flag */
  69. unsigned char klen;
  70. unsigned short ilen;
  71. unsigned short alen;
  72. unsigned short rlen;
  73. };
  74. struct cprng_testvec {
  75. char *key;
  76. char *dt;
  77. char *v;
  78. char *result;
  79. unsigned char klen;
  80. unsigned short dtlen;
  81. unsigned short vlen;
  82. unsigned short rlen;
  83. unsigned short loops;
  84. };
  85. static char zeroed_string[48];
  86. /*
  87. * MD4 test vectors from RFC1320
  88. */
  89. #define MD4_TEST_VECTORS 7
  90. static struct hash_testvec md4_tv_template [] = {
  91. {
  92. .plaintext = "",
  93. .digest = "\x31\xd6\xcf\xe0\xd1\x6a\xe9\x31"
  94. "\xb7\x3c\x59\xd7\xe0\xc0\x89\xc0",
  95. }, {
  96. .plaintext = "a",
  97. .psize = 1,
  98. .digest = "\xbd\xe5\x2c\xb3\x1d\xe3\x3e\x46"
  99. "\x24\x5e\x05\xfb\xdb\xd6\xfb\x24",
  100. }, {
  101. .plaintext = "abc",
  102. .psize = 3,
  103. .digest = "\xa4\x48\x01\x7a\xaf\x21\xd8\x52"
  104. "\x5f\xc1\x0a\xe8\x7a\xa6\x72\x9d",
  105. }, {
  106. .plaintext = "message digest",
  107. .psize = 14,
  108. .digest = "\xd9\x13\x0a\x81\x64\x54\x9f\xe8"
  109. "\x18\x87\x48\x06\xe1\xc7\x01\x4b",
  110. }, {
  111. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  112. .psize = 26,
  113. .digest = "\xd7\x9e\x1c\x30\x8a\xa5\xbb\xcd"
  114. "\xee\xa8\xed\x63\xdf\x41\x2d\xa9",
  115. .np = 2,
  116. .tap = { 13, 13 },
  117. }, {
  118. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",
  119. .psize = 62,
  120. .digest = "\x04\x3f\x85\x82\xf2\x41\xdb\x35"
  121. "\x1c\xe6\x27\xe1\x53\xe7\xf0\xe4",
  122. }, {
  123. .plaintext = "123456789012345678901234567890123456789012345678901234567890123"
  124. "45678901234567890",
  125. .psize = 80,
  126. .digest = "\xe3\x3b\x4d\xdc\x9c\x38\xf2\x19"
  127. "\x9c\x3e\x7b\x16\x4f\xcc\x05\x36",
  128. },
  129. };
  130. /*
  131. * MD5 test vectors from RFC1321
  132. */
  133. #define MD5_TEST_VECTORS 7
  134. static struct hash_testvec md5_tv_template[] = {
  135. {
  136. .digest = "\xd4\x1d\x8c\xd9\x8f\x00\xb2\x04"
  137. "\xe9\x80\x09\x98\xec\xf8\x42\x7e",
  138. }, {
  139. .plaintext = "a",
  140. .psize = 1,
  141. .digest = "\x0c\xc1\x75\xb9\xc0\xf1\xb6\xa8"
  142. "\x31\xc3\x99\xe2\x69\x77\x26\x61",
  143. }, {
  144. .plaintext = "abc",
  145. .psize = 3,
  146. .digest = "\x90\x01\x50\x98\x3c\xd2\x4f\xb0"
  147. "\xd6\x96\x3f\x7d\x28\xe1\x7f\x72",
  148. }, {
  149. .plaintext = "message digest",
  150. .psize = 14,
  151. .digest = "\xf9\x6b\x69\x7d\x7c\xb7\x93\x8d"
  152. "\x52\x5a\x2f\x31\xaa\xf1\x61\xd0",
  153. }, {
  154. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  155. .psize = 26,
  156. .digest = "\xc3\xfc\xd3\xd7\x61\x92\xe4\x00"
  157. "\x7d\xfb\x49\x6c\xca\x67\xe1\x3b",
  158. .np = 2,
  159. .tap = {13, 13}
  160. }, {
  161. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",
  162. .psize = 62,
  163. .digest = "\xd1\x74\xab\x98\xd2\x77\xd9\xf5"
  164. "\xa5\x61\x1c\x2c\x9f\x41\x9d\x9f",
  165. }, {
  166. .plaintext = "12345678901234567890123456789012345678901234567890123456789012"
  167. "345678901234567890",
  168. .psize = 80,
  169. .digest = "\x57\xed\xf4\xa2\x2b\xe3\xc9\x55"
  170. "\xac\x49\xda\x2e\x21\x07\xb6\x7a",
  171. }
  172. };
  173. /*
  174. * RIPEMD-128 test vectors from ISO/IEC 10118-3:2004(E)
  175. */
  176. #define RMD128_TEST_VECTORS 10
  177. static struct hash_testvec rmd128_tv_template[] = {
  178. {
  179. .digest = "\xcd\xf2\x62\x13\xa1\x50\xdc\x3e"
  180. "\xcb\x61\x0f\x18\xf6\xb3\x8b\x46",
  181. }, {
  182. .plaintext = "a",
  183. .psize = 1,
  184. .digest = "\x86\xbe\x7a\xfa\x33\x9d\x0f\xc7"
  185. "\xcf\xc7\x85\xe7\x2f\x57\x8d\x33",
  186. }, {
  187. .plaintext = "abc",
  188. .psize = 3,
  189. .digest = "\xc1\x4a\x12\x19\x9c\x66\xe4\xba"
  190. "\x84\x63\x6b\x0f\x69\x14\x4c\x77",
  191. }, {
  192. .plaintext = "message digest",
  193. .psize = 14,
  194. .digest = "\x9e\x32\x7b\x3d\x6e\x52\x30\x62"
  195. "\xaf\xc1\x13\x2d\x7d\xf9\xd1\xb8",
  196. }, {
  197. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  198. .psize = 26,
  199. .digest = "\xfd\x2a\xa6\x07\xf7\x1d\xc8\xf5"
  200. "\x10\x71\x49\x22\xb3\x71\x83\x4e",
  201. }, {
  202. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
  203. "fghijklmnopqrstuvwxyz0123456789",
  204. .psize = 62,
  205. .digest = "\xd1\xe9\x59\xeb\x17\x9c\x91\x1f"
  206. "\xae\xa4\x62\x4c\x60\xc5\xc7\x02",
  207. }, {
  208. .plaintext = "1234567890123456789012345678901234567890"
  209. "1234567890123456789012345678901234567890",
  210. .psize = 80,
  211. .digest = "\x3f\x45\xef\x19\x47\x32\xc2\xdb"
  212. "\xb2\xc4\xa2\xc7\x69\x79\x5f\xa3",
  213. }, {
  214. .plaintext = "abcdbcdecdefdefgefghfghighij"
  215. "hijkijkljklmklmnlmnomnopnopq",
  216. .psize = 56,
  217. .digest = "\xa1\xaa\x06\x89\xd0\xfa\xfa\x2d"
  218. "\xdc\x22\xe8\x8b\x49\x13\x3a\x06",
  219. .np = 2,
  220. .tap = { 28, 28 },
  221. }, {
  222. .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghi"
  223. "jklmghijklmnhijklmnoijklmnopjklmnopqklmnopqr"
  224. "lmnopqrsmnopqrstnopqrstu",
  225. .psize = 112,
  226. .digest = "\xd4\xec\xc9\x13\xe1\xdf\x77\x6b"
  227. "\xf4\x8d\xe9\xd5\x5b\x1f\x25\x46",
  228. }, {
  229. .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
  230. .psize = 32,
  231. .digest = "\x13\xfc\x13\xe8\xef\xff\x34\x7d"
  232. "\xe1\x93\xff\x46\xdb\xac\xcf\xd4",
  233. }
  234. };
  235. /*
  236. * RIPEMD-160 test vectors from ISO/IEC 10118-3:2004(E)
  237. */
  238. #define RMD160_TEST_VECTORS 10
  239. static struct hash_testvec rmd160_tv_template[] = {
  240. {
  241. .digest = "\x9c\x11\x85\xa5\xc5\xe9\xfc\x54\x61\x28"
  242. "\x08\x97\x7e\xe8\xf5\x48\xb2\x25\x8d\x31",
  243. }, {
  244. .plaintext = "a",
  245. .psize = 1,
  246. .digest = "\x0b\xdc\x9d\x2d\x25\x6b\x3e\xe9\xda\xae"
  247. "\x34\x7b\xe6\xf4\xdc\x83\x5a\x46\x7f\xfe",
  248. }, {
  249. .plaintext = "abc",
  250. .psize = 3,
  251. .digest = "\x8e\xb2\x08\xf7\xe0\x5d\x98\x7a\x9b\x04"
  252. "\x4a\x8e\x98\xc6\xb0\x87\xf1\x5a\x0b\xfc",
  253. }, {
  254. .plaintext = "message digest",
  255. .psize = 14,
  256. .digest = "\x5d\x06\x89\xef\x49\xd2\xfa\xe5\x72\xb8"
  257. "\x81\xb1\x23\xa8\x5f\xfa\x21\x59\x5f\x36",
  258. }, {
  259. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  260. .psize = 26,
  261. .digest = "\xf7\x1c\x27\x10\x9c\x69\x2c\x1b\x56\xbb"
  262. "\xdc\xeb\x5b\x9d\x28\x65\xb3\x70\x8d\xbc",
  263. }, {
  264. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
  265. "fghijklmnopqrstuvwxyz0123456789",
  266. .psize = 62,
  267. .digest = "\xb0\xe2\x0b\x6e\x31\x16\x64\x02\x86\xed"
  268. "\x3a\x87\xa5\x71\x30\x79\xb2\x1f\x51\x89",
  269. }, {
  270. .plaintext = "1234567890123456789012345678901234567890"
  271. "1234567890123456789012345678901234567890",
  272. .psize = 80,
  273. .digest = "\x9b\x75\x2e\x45\x57\x3d\x4b\x39\xf4\xdb"
  274. "\xd3\x32\x3c\xab\x82\xbf\x63\x32\x6b\xfb",
  275. }, {
  276. .plaintext = "abcdbcdecdefdefgefghfghighij"
  277. "hijkijkljklmklmnlmnomnopnopq",
  278. .psize = 56,
  279. .digest = "\x12\xa0\x53\x38\x4a\x9c\x0c\x88\xe4\x05"
  280. "\xa0\x6c\x27\xdc\xf4\x9a\xda\x62\xeb\x2b",
  281. .np = 2,
  282. .tap = { 28, 28 },
  283. }, {
  284. .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghi"
  285. "jklmghijklmnhijklmnoijklmnopjklmnopqklmnopqr"
  286. "lmnopqrsmnopqrstnopqrstu",
  287. .psize = 112,
  288. .digest = "\x6f\x3f\xa3\x9b\x6b\x50\x3c\x38\x4f\x91"
  289. "\x9a\x49\xa7\xaa\x5c\x2c\x08\xbd\xfb\x45",
  290. }, {
  291. .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
  292. .psize = 32,
  293. .digest = "\x94\xc2\x64\x11\x54\x04\xe6\x33\x79\x0d"
  294. "\xfc\xc8\x7b\x58\x7d\x36\x77\x06\x7d\x9f",
  295. }
  296. };
  297. /*
  298. * RIPEMD-256 test vectors
  299. */
  300. #define RMD256_TEST_VECTORS 8
  301. static struct hash_testvec rmd256_tv_template[] = {
  302. {
  303. .digest = "\x02\xba\x4c\x4e\x5f\x8e\xcd\x18"
  304. "\x77\xfc\x52\xd6\x4d\x30\xe3\x7a"
  305. "\x2d\x97\x74\xfb\x1e\x5d\x02\x63"
  306. "\x80\xae\x01\x68\xe3\xc5\x52\x2d",
  307. }, {
  308. .plaintext = "a",
  309. .psize = 1,
  310. .digest = "\xf9\x33\x3e\x45\xd8\x57\xf5\xd9"
  311. "\x0a\x91\xba\xb7\x0a\x1e\xba\x0c"
  312. "\xfb\x1b\xe4\xb0\x78\x3c\x9a\xcf"
  313. "\xcd\x88\x3a\x91\x34\x69\x29\x25",
  314. }, {
  315. .plaintext = "abc",
  316. .psize = 3,
  317. .digest = "\xaf\xbd\x6e\x22\x8b\x9d\x8c\xbb"
  318. "\xce\xf5\xca\x2d\x03\xe6\xdb\xa1"
  319. "\x0a\xc0\xbc\x7d\xcb\xe4\x68\x0e"
  320. "\x1e\x42\xd2\xe9\x75\x45\x9b\x65",
  321. }, {
  322. .plaintext = "message digest",
  323. .psize = 14,
  324. .digest = "\x87\xe9\x71\x75\x9a\x1c\xe4\x7a"
  325. "\x51\x4d\x5c\x91\x4c\x39\x2c\x90"
  326. "\x18\xc7\xc4\x6b\xc1\x44\x65\x55"
  327. "\x4a\xfc\xdf\x54\xa5\x07\x0c\x0e",
  328. }, {
  329. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  330. .psize = 26,
  331. .digest = "\x64\x9d\x30\x34\x75\x1e\xa2\x16"
  332. "\x77\x6b\xf9\xa1\x8a\xcc\x81\xbc"
  333. "\x78\x96\x11\x8a\x51\x97\x96\x87"
  334. "\x82\xdd\x1f\xd9\x7d\x8d\x51\x33",
  335. }, {
  336. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
  337. "fghijklmnopqrstuvwxyz0123456789",
  338. .psize = 62,
  339. .digest = "\x57\x40\xa4\x08\xac\x16\xb7\x20"
  340. "\xb8\x44\x24\xae\x93\x1c\xbb\x1f"
  341. "\xe3\x63\xd1\xd0\xbf\x40\x17\xf1"
  342. "\xa8\x9f\x7e\xa6\xde\x77\xa0\xb8",
  343. }, {
  344. .plaintext = "1234567890123456789012345678901234567890"
  345. "1234567890123456789012345678901234567890",
  346. .psize = 80,
  347. .digest = "\x06\xfd\xcc\x7a\x40\x95\x48\xaa"
  348. "\xf9\x13\x68\xc0\x6a\x62\x75\xb5"
  349. "\x53\xe3\xf0\x99\xbf\x0e\xa4\xed"
  350. "\xfd\x67\x78\xdf\x89\xa8\x90\xdd",
  351. }, {
  352. .plaintext = "abcdbcdecdefdefgefghfghighij"
  353. "hijkijkljklmklmnlmnomnopnopq",
  354. .psize = 56,
  355. .digest = "\x38\x43\x04\x55\x83\xaa\xc6\xc8"
  356. "\xc8\xd9\x12\x85\x73\xe7\xa9\x80"
  357. "\x9a\xfb\x2a\x0f\x34\xcc\xc3\x6e"
  358. "\xa9\xe7\x2f\x16\xf6\x36\x8e\x3f",
  359. .np = 2,
  360. .tap = { 28, 28 },
  361. }
  362. };
  363. /*
  364. * RIPEMD-320 test vectors
  365. */
  366. #define RMD320_TEST_VECTORS 8
  367. static struct hash_testvec rmd320_tv_template[] = {
  368. {
  369. .digest = "\x22\xd6\x5d\x56\x61\x53\x6c\xdc\x75\xc1"
  370. "\xfd\xf5\xc6\xde\x7b\x41\xb9\xf2\x73\x25"
  371. "\xeb\xc6\x1e\x85\x57\x17\x7d\x70\x5a\x0e"
  372. "\xc8\x80\x15\x1c\x3a\x32\xa0\x08\x99\xb8",
  373. }, {
  374. .plaintext = "a",
  375. .psize = 1,
  376. .digest = "\xce\x78\x85\x06\x38\xf9\x26\x58\xa5\xa5"
  377. "\x85\x09\x75\x79\x92\x6d\xda\x66\x7a\x57"
  378. "\x16\x56\x2c\xfc\xf6\xfb\xe7\x7f\x63\x54"
  379. "\x2f\x99\xb0\x47\x05\xd6\x97\x0d\xff\x5d",
  380. }, {
  381. .plaintext = "abc",
  382. .psize = 3,
  383. .digest = "\xde\x4c\x01\xb3\x05\x4f\x89\x30\xa7\x9d"
  384. "\x09\xae\x73\x8e\x92\x30\x1e\x5a\x17\x08"
  385. "\x5b\xef\xfd\xc1\xb8\xd1\x16\x71\x3e\x74"
  386. "\xf8\x2f\xa9\x42\xd6\x4c\xdb\xc4\x68\x2d",
  387. }, {
  388. .plaintext = "message digest",
  389. .psize = 14,
  390. .digest = "\x3a\x8e\x28\x50\x2e\xd4\x5d\x42\x2f\x68"
  391. "\x84\x4f\x9d\xd3\x16\xe7\xb9\x85\x33\xfa"
  392. "\x3f\x2a\x91\xd2\x9f\x84\xd4\x25\xc8\x8d"
  393. "\x6b\x4e\xff\x72\x7d\xf6\x6a\x7c\x01\x97",
  394. }, {
  395. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  396. .psize = 26,
  397. .digest = "\xca\xbd\xb1\x81\x0b\x92\x47\x0a\x20\x93"
  398. "\xaa\x6b\xce\x05\x95\x2c\x28\x34\x8c\xf4"
  399. "\x3f\xf6\x08\x41\x97\x51\x66\xbb\x40\xed"
  400. "\x23\x40\x04\xb8\x82\x44\x63\xe6\xb0\x09",
  401. }, {
  402. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcde"
  403. "fghijklmnopqrstuvwxyz0123456789",
  404. .psize = 62,
  405. .digest = "\xed\x54\x49\x40\xc8\x6d\x67\xf2\x50\xd2"
  406. "\x32\xc3\x0b\x7b\x3e\x57\x70\xe0\xc6\x0c"
  407. "\x8c\xb9\xa4\xca\xfe\x3b\x11\x38\x8a\xf9"
  408. "\x92\x0e\x1b\x99\x23\x0b\x84\x3c\x86\xa4",
  409. }, {
  410. .plaintext = "1234567890123456789012345678901234567890"
  411. "1234567890123456789012345678901234567890",
  412. .psize = 80,
  413. .digest = "\x55\x78\x88\xaf\x5f\x6d\x8e\xd6\x2a\xb6"
  414. "\x69\x45\xc6\xd2\xa0\xa4\x7e\xcd\x53\x41"
  415. "\xe9\x15\xeb\x8f\xea\x1d\x05\x24\x95\x5f"
  416. "\x82\x5d\xc7\x17\xe4\xa0\x08\xab\x2d\x42",
  417. }, {
  418. .plaintext = "abcdbcdecdefdefgefghfghighij"
  419. "hijkijkljklmklmnlmnomnopnopq",
  420. .psize = 56,
  421. .digest = "\xd0\x34\xa7\x95\x0c\xf7\x22\x02\x1b\xa4"
  422. "\xb8\x4d\xf7\x69\xa5\xde\x20\x60\xe2\x59"
  423. "\xdf\x4c\x9b\xb4\xa4\x26\x8c\x0e\x93\x5b"
  424. "\xbc\x74\x70\xa9\x69\xc9\xd0\x72\xa1\xac",
  425. .np = 2,
  426. .tap = { 28, 28 },
  427. }
  428. };
  429. /*
  430. * SHA1 test vectors from from FIPS PUB 180-1
  431. * Long vector from CAVS 5.0
  432. */
  433. #define SHA1_TEST_VECTORS 3
  434. static struct hash_testvec sha1_tv_template[] = {
  435. {
  436. .plaintext = "abc",
  437. .psize = 3,
  438. .digest = "\xa9\x99\x3e\x36\x47\x06\x81\x6a\xba\x3e"
  439. "\x25\x71\x78\x50\xc2\x6c\x9c\xd0\xd8\x9d",
  440. }, {
  441. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  442. .psize = 56,
  443. .digest = "\x84\x98\x3e\x44\x1c\x3b\xd2\x6e\xba\xae"
  444. "\x4a\xa1\xf9\x51\x29\xe5\xe5\x46\x70\xf1",
  445. .np = 2,
  446. .tap = { 28, 28 }
  447. }, {
  448. .plaintext = "\xec\x29\x56\x12\x44\xed\xe7\x06"
  449. "\xb6\xeb\x30\xa1\xc3\x71\xd7\x44"
  450. "\x50\xa1\x05\xc3\xf9\x73\x5f\x7f"
  451. "\xa9\xfe\x38\xcf\x67\xf3\x04\xa5"
  452. "\x73\x6a\x10\x6e\x92\xe1\x71\x39"
  453. "\xa6\x81\x3b\x1c\x81\xa4\xf3\xd3"
  454. "\xfb\x95\x46\xab\x42\x96\xfa\x9f"
  455. "\x72\x28\x26\xc0\x66\x86\x9e\xda"
  456. "\xcd\x73\xb2\x54\x80\x35\x18\x58"
  457. "\x13\xe2\x26\x34\xa9\xda\x44\x00"
  458. "\x0d\x95\xa2\x81\xff\x9f\x26\x4e"
  459. "\xcc\xe0\xa9\x31\x22\x21\x62\xd0"
  460. "\x21\xcc\xa2\x8d\xb5\xf3\xc2\xaa"
  461. "\x24\x94\x5a\xb1\xe3\x1c\xb4\x13"
  462. "\xae\x29\x81\x0f\xd7\x94\xca\xd5"
  463. "\xdf\xaf\x29\xec\x43\xcb\x38\xd1"
  464. "\x98\xfe\x4a\xe1\xda\x23\x59\x78"
  465. "\x02\x21\x40\x5b\xd6\x71\x2a\x53"
  466. "\x05\xda\x4b\x1b\x73\x7f\xce\x7c"
  467. "\xd2\x1c\x0e\xb7\x72\x8d\x08\x23"
  468. "\x5a\x90\x11",
  469. .psize = 163,
  470. .digest = "\x97\x01\x11\xc4\xe7\x7b\xcc\x88\xcc\x20"
  471. "\x45\x9c\x02\xb6\x9b\x4a\xa8\xf5\x82\x17",
  472. .np = 4,
  473. .tap = { 63, 64, 31, 5 }
  474. }
  475. };
  476. /*
  477. * SHA224 test vectors from from FIPS PUB 180-2
  478. */
  479. #define SHA224_TEST_VECTORS 2
  480. static struct hash_testvec sha224_tv_template[] = {
  481. {
  482. .plaintext = "abc",
  483. .psize = 3,
  484. .digest = "\x23\x09\x7D\x22\x34\x05\xD8\x22"
  485. "\x86\x42\xA4\x77\xBD\xA2\x55\xB3"
  486. "\x2A\xAD\xBC\xE4\xBD\xA0\xB3\xF7"
  487. "\xE3\x6C\x9D\xA7",
  488. }, {
  489. .plaintext =
  490. "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  491. .psize = 56,
  492. .digest = "\x75\x38\x8B\x16\x51\x27\x76\xCC"
  493. "\x5D\xBA\x5D\xA1\xFD\x89\x01\x50"
  494. "\xB0\xC6\x45\x5C\xB4\xF5\x8B\x19"
  495. "\x52\x52\x25\x25",
  496. .np = 2,
  497. .tap = { 28, 28 }
  498. }
  499. };
  500. /*
  501. * SHA256 test vectors from from NIST
  502. */
  503. #define SHA256_TEST_VECTORS 2
  504. static struct hash_testvec sha256_tv_template[] = {
  505. {
  506. .plaintext = "abc",
  507. .psize = 3,
  508. .digest = "\xba\x78\x16\xbf\x8f\x01\xcf\xea"
  509. "\x41\x41\x40\xde\x5d\xae\x22\x23"
  510. "\xb0\x03\x61\xa3\x96\x17\x7a\x9c"
  511. "\xb4\x10\xff\x61\xf2\x00\x15\xad",
  512. }, {
  513. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  514. .psize = 56,
  515. .digest = "\x24\x8d\x6a\x61\xd2\x06\x38\xb8"
  516. "\xe5\xc0\x26\x93\x0c\x3e\x60\x39"
  517. "\xa3\x3c\xe4\x59\x64\xff\x21\x67"
  518. "\xf6\xec\xed\xd4\x19\xdb\x06\xc1",
  519. .np = 2,
  520. .tap = { 28, 28 }
  521. },
  522. };
  523. /*
  524. * SHA384 test vectors from from NIST and kerneli
  525. */
  526. #define SHA384_TEST_VECTORS 4
  527. static struct hash_testvec sha384_tv_template[] = {
  528. {
  529. .plaintext= "abc",
  530. .psize = 3,
  531. .digest = "\xcb\x00\x75\x3f\x45\xa3\x5e\x8b"
  532. "\xb5\xa0\x3d\x69\x9a\xc6\x50\x07"
  533. "\x27\x2c\x32\xab\x0e\xde\xd1\x63"
  534. "\x1a\x8b\x60\x5a\x43\xff\x5b\xed"
  535. "\x80\x86\x07\x2b\xa1\xe7\xcc\x23"
  536. "\x58\xba\xec\xa1\x34\xc8\x25\xa7",
  537. }, {
  538. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  539. .psize = 56,
  540. .digest = "\x33\x91\xfd\xdd\xfc\x8d\xc7\x39"
  541. "\x37\x07\xa6\x5b\x1b\x47\x09\x39"
  542. "\x7c\xf8\xb1\xd1\x62\xaf\x05\xab"
  543. "\xfe\x8f\x45\x0d\xe5\xf3\x6b\xc6"
  544. "\xb0\x45\x5a\x85\x20\xbc\x4e\x6f"
  545. "\x5f\xe9\x5b\x1f\xe3\xc8\x45\x2b",
  546. }, {
  547. .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghijklmghijklmn"
  548. "hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstnopqrstu",
  549. .psize = 112,
  550. .digest = "\x09\x33\x0c\x33\xf7\x11\x47\xe8"
  551. "\x3d\x19\x2f\xc7\x82\xcd\x1b\x47"
  552. "\x53\x11\x1b\x17\x3b\x3b\x05\xd2"
  553. "\x2f\xa0\x80\x86\xe3\xb0\xf7\x12"
  554. "\xfc\xc7\xc7\x1a\x55\x7e\x2d\xb9"
  555. "\x66\xc3\xe9\xfa\x91\x74\x60\x39",
  556. }, {
  557. .plaintext = "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd"
  558. "efghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz",
  559. .psize = 104,
  560. .digest = "\x3d\x20\x89\x73\xab\x35\x08\xdb"
  561. "\xbd\x7e\x2c\x28\x62\xba\x29\x0a"
  562. "\xd3\x01\x0e\x49\x78\xc1\x98\xdc"
  563. "\x4d\x8f\xd0\x14\xe5\x82\x82\x3a"
  564. "\x89\xe1\x6f\x9b\x2a\x7b\xbc\x1a"
  565. "\xc9\x38\xe2\xd1\x99\xe8\xbe\xa4",
  566. .np = 4,
  567. .tap = { 26, 26, 26, 26 }
  568. },
  569. };
  570. /*
  571. * SHA512 test vectors from from NIST and kerneli
  572. */
  573. #define SHA512_TEST_VECTORS 4
  574. static struct hash_testvec sha512_tv_template[] = {
  575. {
  576. .plaintext = "abc",
  577. .psize = 3,
  578. .digest = "\xdd\xaf\x35\xa1\x93\x61\x7a\xba"
  579. "\xcc\x41\x73\x49\xae\x20\x41\x31"
  580. "\x12\xe6\xfa\x4e\x89\xa9\x7e\xa2"
  581. "\x0a\x9e\xee\xe6\x4b\x55\xd3\x9a"
  582. "\x21\x92\x99\x2a\x27\x4f\xc1\xa8"
  583. "\x36\xba\x3c\x23\xa3\xfe\xeb\xbd"
  584. "\x45\x4d\x44\x23\x64\x3c\xe8\x0e"
  585. "\x2a\x9a\xc9\x4f\xa5\x4c\xa4\x9f",
  586. }, {
  587. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  588. .psize = 56,
  589. .digest = "\x20\x4a\x8f\xc6\xdd\xa8\x2f\x0a"
  590. "\x0c\xed\x7b\xeb\x8e\x08\xa4\x16"
  591. "\x57\xc1\x6e\xf4\x68\xb2\x28\xa8"
  592. "\x27\x9b\xe3\x31\xa7\x03\xc3\x35"
  593. "\x96\xfd\x15\xc1\x3b\x1b\x07\xf9"
  594. "\xaa\x1d\x3b\xea\x57\x78\x9c\xa0"
  595. "\x31\xad\x85\xc7\xa7\x1d\xd7\x03"
  596. "\x54\xec\x63\x12\x38\xca\x34\x45",
  597. }, {
  598. .plaintext = "abcdefghbcdefghicdefghijdefghijkefghijklfghijklmghijklmn"
  599. "hijklmnoijklmnopjklmnopqklmnopqrlmnopqrsmnopqrstnopqrstu",
  600. .psize = 112,
  601. .digest = "\x8e\x95\x9b\x75\xda\xe3\x13\xda"
  602. "\x8c\xf4\xf7\x28\x14\xfc\x14\x3f"
  603. "\x8f\x77\x79\xc6\xeb\x9f\x7f\xa1"
  604. "\x72\x99\xae\xad\xb6\x88\x90\x18"
  605. "\x50\x1d\x28\x9e\x49\x00\xf7\xe4"
  606. "\x33\x1b\x99\xde\xc4\xb5\x43\x3a"
  607. "\xc7\xd3\x29\xee\xb6\xdd\x26\x54"
  608. "\x5e\x96\xe5\x5b\x87\x4b\xe9\x09",
  609. }, {
  610. .plaintext = "abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd"
  611. "efghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz",
  612. .psize = 104,
  613. .digest = "\x93\x0d\x0c\xef\xcb\x30\xff\x11"
  614. "\x33\xb6\x89\x81\x21\xf1\xcf\x3d"
  615. "\x27\x57\x8a\xfc\xaf\xe8\x67\x7c"
  616. "\x52\x57\xcf\x06\x99\x11\xf7\x5d"
  617. "\x8f\x58\x31\xb5\x6e\xbf\xda\x67"
  618. "\xb2\x78\xe6\x6d\xff\x8b\x84\xfe"
  619. "\x2b\x28\x70\xf7\x42\xa5\x80\xd8"
  620. "\xed\xb4\x19\x87\x23\x28\x50\xc9",
  621. .np = 4,
  622. .tap = { 26, 26, 26, 26 }
  623. },
  624. };
  625. /*
  626. * WHIRLPOOL test vectors from Whirlpool package
  627. * by Vincent Rijmen and Paulo S. L. M. Barreto as part of the NESSIE
  628. * submission
  629. */
  630. #define WP512_TEST_VECTORS 8
  631. static struct hash_testvec wp512_tv_template[] = {
  632. {
  633. .plaintext = "",
  634. .psize = 0,
  635. .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
  636. "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
  637. "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
  638. "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7"
  639. "\x3E\x83\xBE\x69\x8B\x28\x8F\xEB"
  640. "\xCF\x88\xE3\xE0\x3C\x4F\x07\x57"
  641. "\xEA\x89\x64\xE5\x9B\x63\xD9\x37"
  642. "\x08\xB1\x38\xCC\x42\xA6\x6E\xB3",
  643. }, {
  644. .plaintext = "a",
  645. .psize = 1,
  646. .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
  647. "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
  648. "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
  649. "\x73\xC4\x50\x01\xD0\x08\x7B\x42"
  650. "\xD1\x1B\xC6\x45\x41\x3A\xEF\xF6"
  651. "\x3A\x42\x39\x1A\x39\x14\x5A\x59"
  652. "\x1A\x92\x20\x0D\x56\x01\x95\xE5"
  653. "\x3B\x47\x85\x84\xFD\xAE\x23\x1A",
  654. }, {
  655. .plaintext = "abc",
  656. .psize = 3,
  657. .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
  658. "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
  659. "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
  660. "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C"
  661. "\x71\x81\xEE\xBD\xB6\xC5\x7E\x27"
  662. "\x7D\x0E\x34\x95\x71\x14\xCB\xD6"
  663. "\xC7\x97\xFC\x9D\x95\xD8\xB5\x82"
  664. "\xD2\x25\x29\x20\x76\xD4\xEE\xF5",
  665. }, {
  666. .plaintext = "message digest",
  667. .psize = 14,
  668. .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
  669. "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
  670. "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
  671. "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B"
  672. "\x84\x21\x55\x76\x59\xEF\x55\xC1"
  673. "\x06\xB4\xB5\x2A\xC5\xA4\xAA\xA6"
  674. "\x92\xED\x92\x00\x52\x83\x8F\x33"
  675. "\x62\xE8\x6D\xBD\x37\xA8\x90\x3E",
  676. }, {
  677. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  678. .psize = 26,
  679. .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
  680. "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
  681. "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
  682. "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B"
  683. "\x08\xBF\x2A\x92\x51\xC3\x0B\x6A"
  684. "\x0B\x8A\xAE\x86\x17\x7A\xB4\xA6"
  685. "\xF6\x8F\x67\x3E\x72\x07\x86\x5D"
  686. "\x5D\x98\x19\xA3\xDB\xA4\xEB\x3B",
  687. }, {
  688. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
  689. "abcdefghijklmnopqrstuvwxyz0123456789",
  690. .psize = 62,
  691. .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
  692. "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
  693. "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
  694. "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E"
  695. "\x08\xEB\xA2\x66\x29\x12\x9D\x8F"
  696. "\xB7\xCB\x57\x21\x1B\x92\x81\xA6"
  697. "\x55\x17\xCC\x87\x9D\x7B\x96\x21"
  698. "\x42\xC6\x5F\x5A\x7A\xF0\x14\x67",
  699. }, {
  700. .plaintext = "1234567890123456789012345678901234567890"
  701. "1234567890123456789012345678901234567890",
  702. .psize = 80,
  703. .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
  704. "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
  705. "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
  706. "\x54\x9C\x4A\xFA\xDB\x60\x14\x29"
  707. "\x4D\x5B\xD8\xDF\x2A\x6C\x44\xE5"
  708. "\x38\xCD\x04\x7B\x26\x81\xA5\x1A"
  709. "\x2C\x60\x48\x1E\x88\xC5\xA2\x0B"
  710. "\x2C\x2A\x80\xCF\x3A\x9A\x08\x3B",
  711. }, {
  712. .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
  713. .psize = 32,
  714. .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
  715. "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
  716. "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
  717. "\x07\xC5\x62\xF9\x88\xE9\x5C\x69"
  718. "\x16\xBD\xC8\x03\x1B\xC5\xBE\x1B"
  719. "\x7B\x94\x76\x39\xFE\x05\x0B\x56"
  720. "\x93\x9B\xAA\xA0\xAD\xFF\x9A\xE6"
  721. "\x74\x5B\x7B\x18\x1C\x3B\xE3\xFD",
  722. },
  723. };
  724. #define WP384_TEST_VECTORS 8
  725. static struct hash_testvec wp384_tv_template[] = {
  726. {
  727. .plaintext = "",
  728. .psize = 0,
  729. .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
  730. "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
  731. "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
  732. "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7"
  733. "\x3E\x83\xBE\x69\x8B\x28\x8F\xEB"
  734. "\xCF\x88\xE3\xE0\x3C\x4F\x07\x57",
  735. }, {
  736. .plaintext = "a",
  737. .psize = 1,
  738. .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
  739. "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
  740. "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
  741. "\x73\xC4\x50\x01\xD0\x08\x7B\x42"
  742. "\xD1\x1B\xC6\x45\x41\x3A\xEF\xF6"
  743. "\x3A\x42\x39\x1A\x39\x14\x5A\x59",
  744. }, {
  745. .plaintext = "abc",
  746. .psize = 3,
  747. .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
  748. "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
  749. "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
  750. "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C"
  751. "\x71\x81\xEE\xBD\xB6\xC5\x7E\x27"
  752. "\x7D\x0E\x34\x95\x71\x14\xCB\xD6",
  753. }, {
  754. .plaintext = "message digest",
  755. .psize = 14,
  756. .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
  757. "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
  758. "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
  759. "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B"
  760. "\x84\x21\x55\x76\x59\xEF\x55\xC1"
  761. "\x06\xB4\xB5\x2A\xC5\xA4\xAA\xA6",
  762. }, {
  763. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  764. .psize = 26,
  765. .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
  766. "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
  767. "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
  768. "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B"
  769. "\x08\xBF\x2A\x92\x51\xC3\x0B\x6A"
  770. "\x0B\x8A\xAE\x86\x17\x7A\xB4\xA6",
  771. }, {
  772. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
  773. "abcdefghijklmnopqrstuvwxyz0123456789",
  774. .psize = 62,
  775. .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
  776. "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
  777. "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
  778. "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E"
  779. "\x08\xEB\xA2\x66\x29\x12\x9D\x8F"
  780. "\xB7\xCB\x57\x21\x1B\x92\x81\xA6",
  781. }, {
  782. .plaintext = "1234567890123456789012345678901234567890"
  783. "1234567890123456789012345678901234567890",
  784. .psize = 80,
  785. .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
  786. "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
  787. "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
  788. "\x54\x9C\x4A\xFA\xDB\x60\x14\x29"
  789. "\x4D\x5B\xD8\xDF\x2A\x6C\x44\xE5"
  790. "\x38\xCD\x04\x7B\x26\x81\xA5\x1A",
  791. }, {
  792. .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
  793. .psize = 32,
  794. .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
  795. "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
  796. "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
  797. "\x07\xC5\x62\xF9\x88\xE9\x5C\x69"
  798. "\x16\xBD\xC8\x03\x1B\xC5\xBE\x1B"
  799. "\x7B\x94\x76\x39\xFE\x05\x0B\x56",
  800. },
  801. };
  802. #define WP256_TEST_VECTORS 8
  803. static struct hash_testvec wp256_tv_template[] = {
  804. {
  805. .plaintext = "",
  806. .psize = 0,
  807. .digest = "\x19\xFA\x61\xD7\x55\x22\xA4\x66"
  808. "\x9B\x44\xE3\x9C\x1D\x2E\x17\x26"
  809. "\xC5\x30\x23\x21\x30\xD4\x07\xF8"
  810. "\x9A\xFE\xE0\x96\x49\x97\xF7\xA7",
  811. }, {
  812. .plaintext = "a",
  813. .psize = 1,
  814. .digest = "\x8A\xCA\x26\x02\x79\x2A\xEC\x6F"
  815. "\x11\xA6\x72\x06\x53\x1F\xB7\xD7"
  816. "\xF0\xDF\xF5\x94\x13\x14\x5E\x69"
  817. "\x73\xC4\x50\x01\xD0\x08\x7B\x42",
  818. }, {
  819. .plaintext = "abc",
  820. .psize = 3,
  821. .digest = "\x4E\x24\x48\xA4\xC6\xF4\x86\xBB"
  822. "\x16\xB6\x56\x2C\x73\xB4\x02\x0B"
  823. "\xF3\x04\x3E\x3A\x73\x1B\xCE\x72"
  824. "\x1A\xE1\xB3\x03\xD9\x7E\x6D\x4C",
  825. }, {
  826. .plaintext = "message digest",
  827. .psize = 14,
  828. .digest = "\x37\x8C\x84\xA4\x12\x6E\x2D\xC6"
  829. "\xE5\x6D\xCC\x74\x58\x37\x7A\xAC"
  830. "\x83\x8D\x00\x03\x22\x30\xF5\x3C"
  831. "\xE1\xF5\x70\x0C\x0F\xFB\x4D\x3B",
  832. }, {
  833. .plaintext = "abcdefghijklmnopqrstuvwxyz",
  834. .psize = 26,
  835. .digest = "\xF1\xD7\x54\x66\x26\x36\xFF\xE9"
  836. "\x2C\x82\xEB\xB9\x21\x2A\x48\x4A"
  837. "\x8D\x38\x63\x1E\xAD\x42\x38\xF5"
  838. "\x44\x2E\xE1\x3B\x80\x54\xE4\x1B",
  839. }, {
  840. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
  841. "abcdefghijklmnopqrstuvwxyz0123456789",
  842. .psize = 62,
  843. .digest = "\xDC\x37\xE0\x08\xCF\x9E\xE6\x9B"
  844. "\xF1\x1F\x00\xED\x9A\xBA\x26\x90"
  845. "\x1D\xD7\xC2\x8C\xDE\xC0\x66\xCC"
  846. "\x6A\xF4\x2E\x40\xF8\x2F\x3A\x1E",
  847. }, {
  848. .plaintext = "1234567890123456789012345678901234567890"
  849. "1234567890123456789012345678901234567890",
  850. .psize = 80,
  851. .digest = "\x46\x6E\xF1\x8B\xAB\xB0\x15\x4D"
  852. "\x25\xB9\xD3\x8A\x64\x14\xF5\xC0"
  853. "\x87\x84\x37\x2B\xCC\xB2\x04\xD6"
  854. "\x54\x9C\x4A\xFA\xDB\x60\x14\x29",
  855. }, {
  856. .plaintext = "abcdbcdecdefdefgefghfghighijhijk",
  857. .psize = 32,
  858. .digest = "\x2A\x98\x7E\xA4\x0F\x91\x70\x61"
  859. "\xF5\xD6\xF0\xA0\xE4\x64\x4F\x48"
  860. "\x8A\x7A\x5A\x52\xDE\xEE\x65\x62"
  861. "\x07\xC5\x62\xF9\x88\xE9\x5C\x69",
  862. },
  863. };
  864. /*
  865. * TIGER test vectors from Tiger website
  866. */
  867. #define TGR192_TEST_VECTORS 6
  868. static struct hash_testvec tgr192_tv_template[] = {
  869. {
  870. .plaintext = "",
  871. .psize = 0,
  872. .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
  873. "\x16\x16\x6e\x76\xb1\xbb\x92\x5f"
  874. "\xf3\x73\xde\x2d\x49\x58\x4e\x7a",
  875. }, {
  876. .plaintext = "abc",
  877. .psize = 3,
  878. .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
  879. "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf"
  880. "\x93\x5f\x7b\x95\x1c\x13\x29\x51",
  881. }, {
  882. .plaintext = "Tiger",
  883. .psize = 5,
  884. .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
  885. "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec"
  886. "\x37\x79\x0c\x11\x6f\x9d\x2b\xdf",
  887. }, {
  888. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
  889. .psize = 64,
  890. .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
  891. "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e"
  892. "\xb5\x86\x44\x50\x34\xa5\xa3\x86",
  893. }, {
  894. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
  895. .psize = 64,
  896. .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
  897. "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9"
  898. "\x57\x89\x65\x65\x97\x5f\x91\x97",
  899. }, {
  900. .plaintext = "Tiger - A Fast New Hash Function, "
  901. "by Ross Anderson and Eli Biham, "
  902. "proceedings of Fast Software Encryption 3, "
  903. "Cambridge, 1996.",
  904. .psize = 125,
  905. .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
  906. "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24"
  907. "\xdd\x68\x15\x1d\x50\x39\x74\xfc",
  908. },
  909. };
  910. #define TGR160_TEST_VECTORS 6
  911. static struct hash_testvec tgr160_tv_template[] = {
  912. {
  913. .plaintext = "",
  914. .psize = 0,
  915. .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
  916. "\x16\x16\x6e\x76\xb1\xbb\x92\x5f"
  917. "\xf3\x73\xde\x2d",
  918. }, {
  919. .plaintext = "abc",
  920. .psize = 3,
  921. .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
  922. "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf"
  923. "\x93\x5f\x7b\x95",
  924. }, {
  925. .plaintext = "Tiger",
  926. .psize = 5,
  927. .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
  928. "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec"
  929. "\x37\x79\x0c\x11",
  930. }, {
  931. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
  932. .psize = 64,
  933. .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
  934. "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e"
  935. "\xb5\x86\x44\x50",
  936. }, {
  937. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
  938. .psize = 64,
  939. .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
  940. "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9"
  941. "\x57\x89\x65\x65",
  942. }, {
  943. .plaintext = "Tiger - A Fast New Hash Function, "
  944. "by Ross Anderson and Eli Biham, "
  945. "proceedings of Fast Software Encryption 3, "
  946. "Cambridge, 1996.",
  947. .psize = 125,
  948. .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
  949. "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24"
  950. "\xdd\x68\x15\x1d",
  951. },
  952. };
  953. #define TGR128_TEST_VECTORS 6
  954. static struct hash_testvec tgr128_tv_template[] = {
  955. {
  956. .plaintext = "",
  957. .psize = 0,
  958. .digest = "\x24\xf0\x13\x0c\x63\xac\x93\x32"
  959. "\x16\x16\x6e\x76\xb1\xbb\x92\x5f",
  960. }, {
  961. .plaintext = "abc",
  962. .psize = 3,
  963. .digest = "\xf2\x58\xc1\xe8\x84\x14\xab\x2a"
  964. "\x52\x7a\xb5\x41\xff\xc5\xb8\xbf",
  965. }, {
  966. .plaintext = "Tiger",
  967. .psize = 5,
  968. .digest = "\x9f\x00\xf5\x99\x07\x23\x00\xdd"
  969. "\x27\x6a\xbb\x38\xc8\xeb\x6d\xec",
  970. }, {
  971. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-",
  972. .psize = 64,
  973. .digest = "\x87\xfb\x2a\x90\x83\x85\x1c\xf7"
  974. "\x47\x0d\x2c\xf8\x10\xe6\xdf\x9e",
  975. }, {
  976. .plaintext = "ABCDEFGHIJKLMNOPQRSTUVWXYZ=abcdefghijklmnopqrstuvwxyz+0123456789",
  977. .psize = 64,
  978. .digest = "\x46\x7d\xb8\x08\x63\xeb\xce\x48"
  979. "\x8d\xf1\xcd\x12\x61\x65\x5d\xe9",
  980. }, {
  981. .plaintext = "Tiger - A Fast New Hash Function, "
  982. "by Ross Anderson and Eli Biham, "
  983. "proceedings of Fast Software Encryption 3, "
  984. "Cambridge, 1996.",
  985. .psize = 125,
  986. .digest = "\x3d\x9a\xeb\x03\xd1\xbd\x1a\x63"
  987. "\x57\xb2\x77\x4d\xfd\x6d\x5b\x24",
  988. },
  989. };
  990. #define GHASH_TEST_VECTORS 1
  991. static struct hash_testvec ghash_tv_template[] =
  992. {
  993. {
  994. .key = "\xdf\xa6\xbf\x4d\xed\x81\xdb\x03\xff\xca\xff\x95\xf8\x30\xf0\x61",
  995. .ksize = 16,
  996. .plaintext = "\x95\x2b\x2a\x56\xa5\x60\x04a\xc0\xb3\x2b\x66\x56\xa0\x5b\x40\xb6",
  997. .psize = 16,
  998. .digest = "\xda\x53\xeb\x0a\xd2\xc5\x5b\xb6"
  999. "\x4f\xc4\x80\x2c\xc3\xfe\xda\x60",
  1000. },
  1001. };
  1002. /*
  1003. * HMAC-MD5 test vectors from RFC2202
  1004. * (These need to be fixed to not use strlen).
  1005. */
  1006. #define HMAC_MD5_TEST_VECTORS 7
  1007. static struct hash_testvec hmac_md5_tv_template[] =
  1008. {
  1009. {
  1010. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
  1011. .ksize = 16,
  1012. .plaintext = "Hi There",
  1013. .psize = 8,
  1014. .digest = "\x92\x94\x72\x7a\x36\x38\xbb\x1c"
  1015. "\x13\xf4\x8e\xf8\x15\x8b\xfc\x9d",
  1016. }, {
  1017. .key = "Jefe",
  1018. .ksize = 4,
  1019. .plaintext = "what do ya want for nothing?",
  1020. .psize = 28,
  1021. .digest = "\x75\x0c\x78\x3e\x6a\xb0\xb5\x03"
  1022. "\xea\xa8\x6e\x31\x0a\x5d\xb7\x38",
  1023. .np = 2,
  1024. .tap = {14, 14}
  1025. }, {
  1026. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
  1027. .ksize = 16,
  1028. .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1029. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1030. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1031. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
  1032. .psize = 50,
  1033. .digest = "\x56\xbe\x34\x52\x1d\x14\x4c\x88"
  1034. "\xdb\xb8\xc7\x33\xf0\xe8\xb3\xf6",
  1035. }, {
  1036. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1037. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1038. "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
  1039. .ksize = 25,
  1040. .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1041. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1042. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1043. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
  1044. .psize = 50,
  1045. .digest = "\x69\x7e\xaf\x0a\xca\x3a\x3a\xea"
  1046. "\x3a\x75\x16\x47\x46\xff\xaa\x79",
  1047. }, {
  1048. .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
  1049. .ksize = 16,
  1050. .plaintext = "Test With Truncation",
  1051. .psize = 20,
  1052. .digest = "\x56\x46\x1e\xf2\x34\x2e\xdc\x00"
  1053. "\xf9\xba\xb9\x95\x69\x0e\xfd\x4c",
  1054. }, {
  1055. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1056. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1057. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1058. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1059. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1060. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1061. "\xaa\xaa",
  1062. .ksize = 80,
  1063. .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
  1064. .psize = 54,
  1065. .digest = "\x6b\x1a\xb7\xfe\x4b\xd7\xbf\x8f"
  1066. "\x0b\x62\xe6\xce\x61\xb9\xd0\xcd",
  1067. }, {
  1068. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1069. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1070. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1071. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1072. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1073. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1074. "\xaa\xaa",
  1075. .ksize = 80,
  1076. .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
  1077. "Block-Size Data",
  1078. .psize = 73,
  1079. .digest = "\x6f\x63\x0f\xad\x67\xcd\xa0\xee"
  1080. "\x1f\xb1\xf5\x62\xdb\x3a\xa5\x3e",
  1081. },
  1082. };
  1083. /*
  1084. * HMAC-RIPEMD128 test vectors from RFC2286
  1085. */
  1086. #define HMAC_RMD128_TEST_VECTORS 7
  1087. static struct hash_testvec hmac_rmd128_tv_template[] = {
  1088. {
  1089. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
  1090. .ksize = 16,
  1091. .plaintext = "Hi There",
  1092. .psize = 8,
  1093. .digest = "\xfb\xf6\x1f\x94\x92\xaa\x4b\xbf"
  1094. "\x81\xc1\x72\xe8\x4e\x07\x34\xdb",
  1095. }, {
  1096. .key = "Jefe",
  1097. .ksize = 4,
  1098. .plaintext = "what do ya want for nothing?",
  1099. .psize = 28,
  1100. .digest = "\x87\x5f\x82\x88\x62\xb6\xb3\x34"
  1101. "\xb4\x27\xc5\x5f\x9f\x7f\xf0\x9b",
  1102. .np = 2,
  1103. .tap = { 14, 14 },
  1104. }, {
  1105. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
  1106. .ksize = 16,
  1107. .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1108. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1109. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1110. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
  1111. .psize = 50,
  1112. .digest = "\x09\xf0\xb2\x84\x6d\x2f\x54\x3d"
  1113. "\xa3\x63\xcb\xec\x8d\x62\xa3\x8d",
  1114. }, {
  1115. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1116. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1117. "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
  1118. .ksize = 25,
  1119. .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1120. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1121. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1122. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
  1123. .psize = 50,
  1124. .digest = "\xbd\xbb\xd7\xcf\x03\xe4\x4b\x5a"
  1125. "\xa6\x0a\xf8\x15\xbe\x4d\x22\x94",
  1126. }, {
  1127. .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
  1128. .ksize = 16,
  1129. .plaintext = "Test With Truncation",
  1130. .psize = 20,
  1131. .digest = "\xe7\x98\x08\xf2\x4b\x25\xfd\x03"
  1132. "\x1c\x15\x5f\x0d\x55\x1d\x9a\x3a",
  1133. }, {
  1134. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1135. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1136. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1137. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1138. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1139. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1140. "\xaa\xaa",
  1141. .ksize = 80,
  1142. .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
  1143. .psize = 54,
  1144. .digest = "\xdc\x73\x29\x28\xde\x98\x10\x4a"
  1145. "\x1f\x59\xd3\x73\xc1\x50\xac\xbb",
  1146. }, {
  1147. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1148. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1149. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1150. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1151. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1152. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1153. "\xaa\xaa",
  1154. .ksize = 80,
  1155. .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
  1156. "Block-Size Data",
  1157. .psize = 73,
  1158. .digest = "\x5c\x6b\xec\x96\x79\x3e\x16\xd4"
  1159. "\x06\x90\xc2\x37\x63\x5f\x30\xc5",
  1160. },
  1161. };
  1162. /*
  1163. * HMAC-RIPEMD160 test vectors from RFC2286
  1164. */
  1165. #define HMAC_RMD160_TEST_VECTORS 7
  1166. static struct hash_testvec hmac_rmd160_tv_template[] = {
  1167. {
  1168. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
  1169. .ksize = 20,
  1170. .plaintext = "Hi There",
  1171. .psize = 8,
  1172. .digest = "\x24\xcb\x4b\xd6\x7d\x20\xfc\x1a\x5d\x2e"
  1173. "\xd7\x73\x2d\xcc\x39\x37\x7f\x0a\x56\x68",
  1174. }, {
  1175. .key = "Jefe",
  1176. .ksize = 4,
  1177. .plaintext = "what do ya want for nothing?",
  1178. .psize = 28,
  1179. .digest = "\xdd\xa6\xc0\x21\x3a\x48\x5a\x9e\x24\xf4"
  1180. "\x74\x20\x64\xa7\xf0\x33\xb4\x3c\x40\x69",
  1181. .np = 2,
  1182. .tap = { 14, 14 },
  1183. }, {
  1184. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
  1185. .ksize = 20,
  1186. .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1187. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1188. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1189. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
  1190. .psize = 50,
  1191. .digest = "\xb0\xb1\x05\x36\x0d\xe7\x59\x96\x0a\xb4"
  1192. "\xf3\x52\x98\xe1\x16\xe2\x95\xd8\xe7\xc1",
  1193. }, {
  1194. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1195. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1196. "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
  1197. .ksize = 25,
  1198. .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1199. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1200. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1201. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
  1202. .psize = 50,
  1203. .digest = "\xd5\xca\x86\x2f\x4d\x21\xd5\xe6\x10\xe1"
  1204. "\x8b\x4c\xf1\xbe\xb9\x7a\x43\x65\xec\xf4",
  1205. }, {
  1206. .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
  1207. .ksize = 20,
  1208. .plaintext = "Test With Truncation",
  1209. .psize = 20,
  1210. .digest = "\x76\x19\x69\x39\x78\xf9\x1d\x90\x53\x9a"
  1211. "\xe7\x86\x50\x0f\xf3\xd8\xe0\x51\x8e\x39",
  1212. }, {
  1213. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1214. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1215. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1216. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1217. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1218. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1219. "\xaa\xaa",
  1220. .ksize = 80,
  1221. .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
  1222. .psize = 54,
  1223. .digest = "\x64\x66\xca\x07\xac\x5e\xac\x29\xe1\xbd"
  1224. "\x52\x3e\x5a\xda\x76\x05\xb7\x91\xfd\x8b",
  1225. }, {
  1226. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1227. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1228. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1229. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1230. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1231. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1232. "\xaa\xaa",
  1233. .ksize = 80,
  1234. .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
  1235. "Block-Size Data",
  1236. .psize = 73,
  1237. .digest = "\x69\xea\x60\x79\x8d\x71\x61\x6c\xce\x5f"
  1238. "\xd0\x87\x1e\x23\x75\x4c\xd7\x5d\x5a\x0a",
  1239. },
  1240. };
  1241. /*
  1242. * HMAC-SHA1 test vectors from RFC2202
  1243. */
  1244. #define HMAC_SHA1_TEST_VECTORS 7
  1245. static struct hash_testvec hmac_sha1_tv_template[] = {
  1246. {
  1247. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b",
  1248. .ksize = 20,
  1249. .plaintext = "Hi There",
  1250. .psize = 8,
  1251. .digest = "\xb6\x17\x31\x86\x55\x05\x72\x64"
  1252. "\xe2\x8b\xc0\xb6\xfb\x37\x8c\x8e\xf1"
  1253. "\x46\xbe",
  1254. }, {
  1255. .key = "Jefe",
  1256. .ksize = 4,
  1257. .plaintext = "what do ya want for nothing?",
  1258. .psize = 28,
  1259. .digest = "\xef\xfc\xdf\x6a\xe5\xeb\x2f\xa2\xd2\x74"
  1260. "\x16\xd5\xf1\x84\xdf\x9c\x25\x9a\x7c\x79",
  1261. .np = 2,
  1262. .tap = { 14, 14 }
  1263. }, {
  1264. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
  1265. .ksize = 20,
  1266. .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1267. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1268. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1269. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
  1270. .psize = 50,
  1271. .digest = "\x12\x5d\x73\x42\xb9\xac\x11\xcd\x91\xa3"
  1272. "\x9a\xf4\x8a\xa1\x7b\x4f\x63\xf1\x75\xd3",
  1273. }, {
  1274. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1275. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1276. "\x11\x12\x13\x14\x15\x16\x17\x18\x19",
  1277. .ksize = 25,
  1278. .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1279. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1280. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1281. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
  1282. .psize = 50,
  1283. .digest = "\x4c\x90\x07\xf4\x02\x62\x50\xc6\xbc\x84"
  1284. "\x14\xf9\xbf\x50\xc8\x6c\x2d\x72\x35\xda",
  1285. }, {
  1286. .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c",
  1287. .ksize = 20,
  1288. .plaintext = "Test With Truncation",
  1289. .psize = 20,
  1290. .digest = "\x4c\x1a\x03\x42\x4b\x55\xe0\x7f\xe7\xf2"
  1291. "\x7b\xe1\xd5\x8b\xb9\x32\x4a\x9a\x5a\x04",
  1292. }, {
  1293. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1294. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1295. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1296. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1297. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1298. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1299. "\xaa\xaa",
  1300. .ksize = 80,
  1301. .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
  1302. .psize = 54,
  1303. .digest = "\xaa\x4a\xe5\xe1\x52\x72\xd0\x0e\x95\x70"
  1304. "\x56\x37\xce\x8a\x3b\x55\xed\x40\x21\x12",
  1305. }, {
  1306. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1307. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1308. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1309. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1310. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1311. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1312. "\xaa\xaa",
  1313. .ksize = 80,
  1314. .plaintext = "Test Using Larger Than Block-Size Key and Larger Than One "
  1315. "Block-Size Data",
  1316. .psize = 73,
  1317. .digest = "\xe8\xe9\x9d\x0f\x45\x23\x7d\x78\x6d\x6b"
  1318. "\xba\xa7\x96\x5c\x78\x08\xbb\xff\x1a\x91",
  1319. },
  1320. };
  1321. /*
  1322. * SHA224 HMAC test vectors from RFC4231
  1323. */
  1324. #define HMAC_SHA224_TEST_VECTORS 4
  1325. static struct hash_testvec hmac_sha224_tv_template[] = {
  1326. {
  1327. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1328. "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1329. "\x0b\x0b\x0b\x0b",
  1330. .ksize = 20,
  1331. /* ("Hi There") */
  1332. .plaintext = "\x48\x69\x20\x54\x68\x65\x72\x65",
  1333. .psize = 8,
  1334. .digest = "\x89\x6f\xb1\x12\x8a\xbb\xdf\x19"
  1335. "\x68\x32\x10\x7c\xd4\x9d\xf3\x3f"
  1336. "\x47\xb4\xb1\x16\x99\x12\xba\x4f"
  1337. "\x53\x68\x4b\x22",
  1338. }, {
  1339. .key = "Jefe",
  1340. .ksize = 4,
  1341. /* ("what do ya want for nothing?") */
  1342. .plaintext = "\x77\x68\x61\x74\x20\x64\x6f\x20"
  1343. "\x79\x61\x20\x77\x61\x6e\x74\x20"
  1344. "\x66\x6f\x72\x20\x6e\x6f\x74\x68"
  1345. "\x69\x6e\x67\x3f",
  1346. .psize = 28,
  1347. .digest = "\xa3\x0e\x01\x09\x8b\xc6\xdb\xbf"
  1348. "\x45\x69\x0f\x3a\x7e\x9e\x6d\x0f"
  1349. "\x8b\xbe\xa2\xa3\x9e\x61\x48\x00"
  1350. "\x8f\xd0\x5e\x44",
  1351. .np = 4,
  1352. .tap = { 7, 7, 7, 7 }
  1353. }, {
  1354. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1355. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1356. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1357. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1358. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1359. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1360. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1361. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1362. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1363. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1364. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1365. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1366. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1367. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1368. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1369. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1370. "\xaa\xaa\xaa",
  1371. .ksize = 131,
  1372. /* ("Test Using Larger Than Block-Size Key - Hash Key First") */
  1373. .plaintext = "\x54\x65\x73\x74\x20\x55\x73\x69"
  1374. "\x6e\x67\x20\x4c\x61\x72\x67\x65"
  1375. "\x72\x20\x54\x68\x61\x6e\x20\x42"
  1376. "\x6c\x6f\x63\x6b\x2d\x53\x69\x7a"
  1377. "\x65\x20\x4b\x65\x79\x20\x2d\x20"
  1378. "\x48\x61\x73\x68\x20\x4b\x65\x79"
  1379. "\x20\x46\x69\x72\x73\x74",
  1380. .psize = 54,
  1381. .digest = "\x95\xe9\xa0\xdb\x96\x20\x95\xad"
  1382. "\xae\xbe\x9b\x2d\x6f\x0d\xbc\xe2"
  1383. "\xd4\x99\xf1\x12\xf2\xd2\xb7\x27"
  1384. "\x3f\xa6\x87\x0e",
  1385. }, {
  1386. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1387. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1388. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1389. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1390. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1391. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1392. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1393. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1394. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1395. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1396. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1397. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1398. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1399. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1400. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1401. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1402. "\xaa\xaa\xaa",
  1403. .ksize = 131,
  1404. /* ("This is a test using a larger than block-size key and a")
  1405. (" larger than block-size data. The key needs to be")
  1406. (" hashed before being used by the HMAC algorithm.") */
  1407. .plaintext = "\x54\x68\x69\x73\x20\x69\x73\x20"
  1408. "\x61\x20\x74\x65\x73\x74\x20\x75"
  1409. "\x73\x69\x6e\x67\x20\x61\x20\x6c"
  1410. "\x61\x72\x67\x65\x72\x20\x74\x68"
  1411. "\x61\x6e\x20\x62\x6c\x6f\x63\x6b"
  1412. "\x2d\x73\x69\x7a\x65\x20\x6b\x65"
  1413. "\x79\x20\x61\x6e\x64\x20\x61\x20"
  1414. "\x6c\x61\x72\x67\x65\x72\x20\x74"
  1415. "\x68\x61\x6e\x20\x62\x6c\x6f\x63"
  1416. "\x6b\x2d\x73\x69\x7a\x65\x20\x64"
  1417. "\x61\x74\x61\x2e\x20\x54\x68\x65"
  1418. "\x20\x6b\x65\x79\x20\x6e\x65\x65"
  1419. "\x64\x73\x20\x74\x6f\x20\x62\x65"
  1420. "\x20\x68\x61\x73\x68\x65\x64\x20"
  1421. "\x62\x65\x66\x6f\x72\x65\x20\x62"
  1422. "\x65\x69\x6e\x67\x20\x75\x73\x65"
  1423. "\x64\x20\x62\x79\x20\x74\x68\x65"
  1424. "\x20\x48\x4d\x41\x43\x20\x61\x6c"
  1425. "\x67\x6f\x72\x69\x74\x68\x6d\x2e",
  1426. .psize = 152,
  1427. .digest = "\x3a\x85\x41\x66\xac\x5d\x9f\x02"
  1428. "\x3f\x54\xd5\x17\xd0\xb3\x9d\xbd"
  1429. "\x94\x67\x70\xdb\x9c\x2b\x95\xc9"
  1430. "\xf6\xf5\x65\xd1",
  1431. },
  1432. };
  1433. /*
  1434. * HMAC-SHA256 test vectors from
  1435. * draft-ietf-ipsec-ciph-sha-256-01.txt
  1436. */
  1437. #define HMAC_SHA256_TEST_VECTORS 10
  1438. static struct hash_testvec hmac_sha256_tv_template[] = {
  1439. {
  1440. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1441. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1442. "\x11\x12\x13\x14\x15\x16\x17\x18"
  1443. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
  1444. .ksize = 32,
  1445. .plaintext = "abc",
  1446. .psize = 3,
  1447. .digest = "\xa2\x1b\x1f\x5d\x4c\xf4\xf7\x3a"
  1448. "\x4d\xd9\x39\x75\x0f\x7a\x06\x6a"
  1449. "\x7f\x98\xcc\x13\x1c\xb1\x6a\x66"
  1450. "\x92\x75\x90\x21\xcf\xab\x81\x81",
  1451. }, {
  1452. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1453. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1454. "\x11\x12\x13\x14\x15\x16\x17\x18"
  1455. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
  1456. .ksize = 32,
  1457. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  1458. .psize = 56,
  1459. .digest = "\x10\x4f\xdc\x12\x57\x32\x8f\x08"
  1460. "\x18\x4b\xa7\x31\x31\xc5\x3c\xae"
  1461. "\xe6\x98\xe3\x61\x19\x42\x11\x49"
  1462. "\xea\x8c\x71\x24\x56\x69\x7d\x30",
  1463. }, {
  1464. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1465. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1466. "\x11\x12\x13\x14\x15\x16\x17\x18"
  1467. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20",
  1468. .ksize = 32,
  1469. .plaintext = "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq"
  1470. "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq",
  1471. .psize = 112,
  1472. .digest = "\x47\x03\x05\xfc\x7e\x40\xfe\x34"
  1473. "\xd3\xee\xb3\xe7\x73\xd9\x5a\xab"
  1474. "\x73\xac\xf0\xfd\x06\x04\x47\xa5"
  1475. "\xeb\x45\x95\xbf\x33\xa9\xd1\xa3",
  1476. }, {
  1477. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1478. "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1479. "\x0b\x0b\x0b\x0b\x0b\x0b",
  1480. .ksize = 32,
  1481. .plaintext = "Hi There",
  1482. .psize = 8,
  1483. .digest = "\x19\x8a\x60\x7e\xb4\x4b\xfb\xc6"
  1484. "\x99\x03\xa0\xf1\xcf\x2b\xbd\xc5"
  1485. "\xba\x0a\xa3\xf3\xd9\xae\x3c\x1c"
  1486. "\x7a\x3b\x16\x96\xa0\xb6\x8c\xf7",
  1487. }, {
  1488. .key = "Jefe",
  1489. .ksize = 4,
  1490. .plaintext = "what do ya want for nothing?",
  1491. .psize = 28,
  1492. .digest = "\x5b\xdc\xc1\x46\xbf\x60\x75\x4e"
  1493. "\x6a\x04\x24\x26\x08\x95\x75\xc7"
  1494. "\x5a\x00\x3f\x08\x9d\x27\x39\x83"
  1495. "\x9d\xec\x58\xb9\x64\xec\x38\x43",
  1496. .np = 2,
  1497. .tap = { 14, 14 }
  1498. }, {
  1499. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1500. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1501. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa",
  1502. .ksize = 32,
  1503. .plaintext = "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1504. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1505. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd"
  1506. "\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd\xdd",
  1507. .psize = 50,
  1508. .digest = "\xcd\xcb\x12\x20\xd1\xec\xcc\xea"
  1509. "\x91\xe5\x3a\xba\x30\x92\xf9\x62"
  1510. "\xe5\x49\xfe\x6c\xe9\xed\x7f\xdc"
  1511. "\x43\x19\x1f\xbd\xe4\x5c\x30\xb0",
  1512. }, {
  1513. .key = "\x01\x02\x03\x04\x05\x06\x07\x08"
  1514. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  1515. "\x11\x12\x13\x14\x15\x16\x17\x18"
  1516. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20"
  1517. "\x21\x22\x23\x24\x25",
  1518. .ksize = 37,
  1519. .plaintext = "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1520. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1521. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd"
  1522. "\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd\xcd",
  1523. .psize = 50,
  1524. .digest = "\xd4\x63\x3c\x17\xf6\xfb\x8d\x74"
  1525. "\x4c\x66\xde\xe0\xf8\xf0\x74\x55"
  1526. "\x6e\xc4\xaf\x55\xef\x07\x99\x85"
  1527. "\x41\x46\x8e\xb4\x9b\xd2\xe9\x17",
  1528. }, {
  1529. .key = "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c"
  1530. "\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c\x0c"
  1531. "\x0c\x0c\x0c\x0c\x0c\x0c",
  1532. .ksize = 32,
  1533. .plaintext = "Test With Truncation",
  1534. .psize = 20,
  1535. .digest = "\x75\x46\xaf\x01\x84\x1f\xc0\x9b"
  1536. "\x1a\xb9\xc3\x74\x9a\x5f\x1c\x17"
  1537. "\xd4\xf5\x89\x66\x8a\x58\x7b\x27"
  1538. "\x00\xa9\xc9\x7c\x11\x93\xcf\x42",
  1539. }, {
  1540. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1541. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1542. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1543. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1544. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1545. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1546. "\xaa\xaa",
  1547. .ksize = 80,
  1548. .plaintext = "Test Using Larger Than Block-Size Key - Hash Key First",
  1549. .psize = 54,
  1550. .digest = "\x69\x53\x02\x5e\xd9\x6f\x0c\x09"
  1551. "\xf8\x0a\x96\xf7\x8e\x65\x38\xdb"
  1552. "\xe2\xe7\xb8\x20\xe3\xdd\x97\x0e"
  1553. "\x7d\xdd\x39\x09\x1b\x32\x35\x2f",
  1554. }, {
  1555. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1556. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1557. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1558. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1559. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1560. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1561. "\xaa\xaa",
  1562. .ksize = 80,
  1563. .plaintext = "Test Using Larger Than Block-Size Key and Larger Than "
  1564. "One Block-Size Data",
  1565. .psize = 73,
  1566. .digest = "\x63\x55\xac\x22\xe8\x90\xd0\xa3"
  1567. "\xc8\x48\x1a\x5c\xa4\x82\x5b\xc8"
  1568. "\x84\xd3\xe7\xa1\xff\x98\xa2\xfc"
  1569. "\x2a\xc7\xd8\xe0\x64\xc3\xb2\xe6",
  1570. },
  1571. };
  1572. #define XCBC_AES_TEST_VECTORS 6
  1573. static struct hash_testvec aes_xcbc128_tv_template[] = {
  1574. {
  1575. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1576. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1577. .plaintext = zeroed_string,
  1578. .digest = "\x75\xf0\x25\x1d\x52\x8a\xc0\x1c"
  1579. "\x45\x73\xdf\xd5\x84\xd7\x9f\x29",
  1580. .psize = 0,
  1581. .ksize = 16,
  1582. }, {
  1583. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1584. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1585. .plaintext = "\x00\x01\x02",
  1586. .digest = "\x5b\x37\x65\x80\xae\x2f\x19\xaf"
  1587. "\xe7\x21\x9c\xee\xf1\x72\x75\x6f",
  1588. .psize = 3,
  1589. .ksize = 16,
  1590. } , {
  1591. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1592. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1593. .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1594. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1595. .digest = "\xd2\xa2\x46\xfa\x34\x9b\x68\xa7"
  1596. "\x99\x98\xa4\x39\x4f\xf7\xa2\x63",
  1597. .psize = 16,
  1598. .ksize = 16,
  1599. }, {
  1600. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1601. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1602. .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1603. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  1604. "\x10\x11\x12\x13",
  1605. .digest = "\x47\xf5\x1b\x45\x64\x96\x62\x15"
  1606. "\xb8\x98\x5c\x63\x05\x5e\xd3\x08",
  1607. .tap = { 10, 10 },
  1608. .psize = 20,
  1609. .np = 2,
  1610. .ksize = 16,
  1611. }, {
  1612. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1613. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1614. .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1615. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  1616. "\x10\x11\x12\x13\x14\x15\x16\x17"
  1617. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  1618. .digest = "\xf5\x4f\x0e\xc8\xd2\xb9\xf3\xd3"
  1619. "\x68\x07\x73\x4b\xd5\x28\x3f\xd4",
  1620. .psize = 32,
  1621. .ksize = 16,
  1622. }, {
  1623. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1624. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1625. .plaintext = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1626. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  1627. "\x10\x11\x12\x13\x14\x15\x16\x17"
  1628. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  1629. "\x20\x21",
  1630. .digest = "\xbe\xcb\xb3\xbc\xcd\xb5\x18\xa3"
  1631. "\x06\x77\xd5\x48\x1f\xb6\xb4\xd8",
  1632. .tap = { 17, 17 },
  1633. .psize = 34,
  1634. .np = 2,
  1635. .ksize = 16,
  1636. }
  1637. };
  1638. #define VMAC_AES_TEST_VECTORS 8
  1639. static char vmac_string1[128] = {'\x01', '\x01', '\x01', '\x01',
  1640. '\x02', '\x03', '\x02', '\x02',
  1641. '\x02', '\x04', '\x01', '\x07',
  1642. '\x04', '\x01', '\x04', '\x03',};
  1643. static char vmac_string2[128] = {'a', 'b', 'c',};
  1644. static char vmac_string3[128] = {'a', 'b', 'c', 'a', 'b', 'c',
  1645. 'a', 'b', 'c', 'a', 'b', 'c',
  1646. 'a', 'b', 'c', 'a', 'b', 'c',
  1647. 'a', 'b', 'c', 'a', 'b', 'c',
  1648. 'a', 'b', 'c', 'a', 'b', 'c',
  1649. 'a', 'b', 'c', 'a', 'b', 'c',
  1650. 'a', 'b', 'c', 'a', 'b', 'c',
  1651. 'a', 'b', 'c', 'a', 'b', 'c',
  1652. };
  1653. static struct hash_testvec aes_vmac128_tv_template[] = {
  1654. {
  1655. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1656. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1657. .plaintext = NULL,
  1658. .digest = "\x07\x58\x80\x35\x77\xa4\x7b\x54",
  1659. .psize = 0,
  1660. .ksize = 16,
  1661. }, {
  1662. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1663. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1664. .plaintext = vmac_string1,
  1665. .digest = "\xce\xf5\x3c\xd3\xae\x68\x8c\xa1",
  1666. .psize = 128,
  1667. .ksize = 16,
  1668. }, {
  1669. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1670. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1671. .plaintext = vmac_string2,
  1672. .digest = "\xc9\x27\xb0\x73\x81\xbd\x14\x2d",
  1673. .psize = 128,
  1674. .ksize = 16,
  1675. }, {
  1676. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  1677. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  1678. .plaintext = vmac_string3,
  1679. .digest = "\x8d\x1a\x95\x8c\x98\x47\x0b\x19",
  1680. .psize = 128,
  1681. .ksize = 16,
  1682. }, {
  1683. .key = "abcdefghijklmnop",
  1684. .plaintext = NULL,
  1685. .digest = "\x3b\x89\xa1\x26\x9e\x55\x8f\x84",
  1686. .psize = 0,
  1687. .ksize = 16,
  1688. }, {
  1689. .key = "abcdefghijklmnop",
  1690. .plaintext = vmac_string1,
  1691. .digest = "\xab\x5e\xab\xb0\xf6\x8d\x74\xc2",
  1692. .psize = 128,
  1693. .ksize = 16,
  1694. }, {
  1695. .key = "abcdefghijklmnop",
  1696. .plaintext = vmac_string2,
  1697. .digest = "\x11\x15\x68\x42\x3d\x7b\x09\xdf",
  1698. .psize = 128,
  1699. .ksize = 16,
  1700. }, {
  1701. .key = "abcdefghijklmnop",
  1702. .plaintext = vmac_string3,
  1703. .digest = "\x8b\x32\x8f\xe1\xed\x8f\xfa\xd4",
  1704. .psize = 128,
  1705. .ksize = 16,
  1706. },
  1707. };
  1708. /*
  1709. * SHA384 HMAC test vectors from RFC4231
  1710. */
  1711. #define HMAC_SHA384_TEST_VECTORS 4
  1712. static struct hash_testvec hmac_sha384_tv_template[] = {
  1713. {
  1714. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1715. "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1716. "\x0b\x0b\x0b\x0b",
  1717. .ksize = 20,
  1718. .plaintext = "Hi There",
  1719. .psize = 8,
  1720. .digest = "\xaf\xd0\x39\x44\xd8\x48\x95\x62"
  1721. "\x6b\x08\x25\xf4\xab\x46\x90\x7f"
  1722. "\x15\xf9\xda\xdb\xe4\x10\x1e\xc6"
  1723. "\x82\xaa\x03\x4c\x7c\xeb\xc5\x9c"
  1724. "\xfa\xea\x9e\xa9\x07\x6e\xde\x7f"
  1725. "\x4a\xf1\x52\xe8\xb2\xfa\x9c\xb6",
  1726. }, {
  1727. .key = "Jefe",
  1728. .ksize = 4,
  1729. .plaintext = "what do ya want for nothing?",
  1730. .psize = 28,
  1731. .digest = "\xaf\x45\xd2\xe3\x76\x48\x40\x31"
  1732. "\x61\x7f\x78\xd2\xb5\x8a\x6b\x1b"
  1733. "\x9c\x7e\xf4\x64\xf5\xa0\x1b\x47"
  1734. "\xe4\x2e\xc3\x73\x63\x22\x44\x5e"
  1735. "\x8e\x22\x40\xca\x5e\x69\xe2\xc7"
  1736. "\x8b\x32\x39\xec\xfa\xb2\x16\x49",
  1737. .np = 4,
  1738. .tap = { 7, 7, 7, 7 }
  1739. }, {
  1740. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1741. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1742. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1743. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1744. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1745. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1746. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1747. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1748. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1749. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1750. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1751. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1752. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1753. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1754. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1755. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1756. "\xaa\xaa\xaa",
  1757. .ksize = 131,
  1758. .plaintext = "Test Using Larger Than Block-Siz"
  1759. "e Key - Hash Key First",
  1760. .psize = 54,
  1761. .digest = "\x4e\xce\x08\x44\x85\x81\x3e\x90"
  1762. "\x88\xd2\xc6\x3a\x04\x1b\xc5\xb4"
  1763. "\x4f\x9e\xf1\x01\x2a\x2b\x58\x8f"
  1764. "\x3c\xd1\x1f\x05\x03\x3a\xc4\xc6"
  1765. "\x0c\x2e\xf6\xab\x40\x30\xfe\x82"
  1766. "\x96\x24\x8d\xf1\x63\xf4\x49\x52",
  1767. }, {
  1768. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1769. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1770. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1771. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1772. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1773. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1774. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1775. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1776. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1777. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1778. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1779. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1780. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1781. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1782. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1783. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1784. "\xaa\xaa\xaa",
  1785. .ksize = 131,
  1786. .plaintext = "This is a test u"
  1787. "sing a larger th"
  1788. "an block-size ke"
  1789. "y and a larger t"
  1790. "han block-size d"
  1791. "ata. The key nee"
  1792. "ds to be hashed "
  1793. "before being use"
  1794. "d by the HMAC al"
  1795. "gorithm.",
  1796. .psize = 152,
  1797. .digest = "\x66\x17\x17\x8e\x94\x1f\x02\x0d"
  1798. "\x35\x1e\x2f\x25\x4e\x8f\xd3\x2c"
  1799. "\x60\x24\x20\xfe\xb0\xb8\xfb\x9a"
  1800. "\xdc\xce\xbb\x82\x46\x1e\x99\xc5"
  1801. "\xa6\x78\xcc\x31\xe7\x99\x17\x6d"
  1802. "\x38\x60\xe6\x11\x0c\x46\x52\x3e",
  1803. },
  1804. };
  1805. /*
  1806. * SHA512 HMAC test vectors from RFC4231
  1807. */
  1808. #define HMAC_SHA512_TEST_VECTORS 4
  1809. static struct hash_testvec hmac_sha512_tv_template[] = {
  1810. {
  1811. .key = "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1812. "\x0b\x0b\x0b\x0b\x0b\x0b\x0b\x0b"
  1813. "\x0b\x0b\x0b\x0b",
  1814. .ksize = 20,
  1815. .plaintext = "Hi There",
  1816. .psize = 8,
  1817. .digest = "\x87\xaa\x7c\xde\xa5\xef\x61\x9d"
  1818. "\x4f\xf0\xb4\x24\x1a\x1d\x6c\xb0"
  1819. "\x23\x79\xf4\xe2\xce\x4e\xc2\x78"
  1820. "\x7a\xd0\xb3\x05\x45\xe1\x7c\xde"
  1821. "\xda\xa8\x33\xb7\xd6\xb8\xa7\x02"
  1822. "\x03\x8b\x27\x4e\xae\xa3\xf4\xe4"
  1823. "\xbe\x9d\x91\x4e\xeb\x61\xf1\x70"
  1824. "\x2e\x69\x6c\x20\x3a\x12\x68\x54",
  1825. }, {
  1826. .key = "Jefe",
  1827. .ksize = 4,
  1828. .plaintext = "what do ya want for nothing?",
  1829. .psize = 28,
  1830. .digest = "\x16\x4b\x7a\x7b\xfc\xf8\x19\xe2"
  1831. "\xe3\x95\xfb\xe7\x3b\x56\xe0\xa3"
  1832. "\x87\xbd\x64\x22\x2e\x83\x1f\xd6"
  1833. "\x10\x27\x0c\xd7\xea\x25\x05\x54"
  1834. "\x97\x58\xbf\x75\xc0\x5a\x99\x4a"
  1835. "\x6d\x03\x4f\x65\xf8\xf0\xe6\xfd"
  1836. "\xca\xea\xb1\xa3\x4d\x4a\x6b\x4b"
  1837. "\x63\x6e\x07\x0a\x38\xbc\xe7\x37",
  1838. .np = 4,
  1839. .tap = { 7, 7, 7, 7 }
  1840. }, {
  1841. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1842. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1843. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1844. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1845. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1846. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1847. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1848. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1849. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1850. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1851. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1852. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1853. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1854. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1855. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1856. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1857. "\xaa\xaa\xaa",
  1858. .ksize = 131,
  1859. .plaintext = "Test Using Large"
  1860. "r Than Block-Siz"
  1861. "e Key - Hash Key"
  1862. " First",
  1863. .psize = 54,
  1864. .digest = "\x80\xb2\x42\x63\xc7\xc1\xa3\xeb"
  1865. "\xb7\x14\x93\xc1\xdd\x7b\xe8\xb4"
  1866. "\x9b\x46\xd1\xf4\x1b\x4a\xee\xc1"
  1867. "\x12\x1b\x01\x37\x83\xf8\xf3\x52"
  1868. "\x6b\x56\xd0\x37\xe0\x5f\x25\x98"
  1869. "\xbd\x0f\xd2\x21\x5d\x6a\x1e\x52"
  1870. "\x95\xe6\x4f\x73\xf6\x3f\x0a\xec"
  1871. "\x8b\x91\x5a\x98\x5d\x78\x65\x98",
  1872. }, {
  1873. .key = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1874. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1875. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1876. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1877. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1878. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1879. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1880. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1881. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1882. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1883. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1884. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1885. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1886. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1887. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1888. "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  1889. "\xaa\xaa\xaa",
  1890. .ksize = 131,
  1891. .plaintext =
  1892. "This is a test u"
  1893. "sing a larger th"
  1894. "an block-size ke"
  1895. "y and a larger t"
  1896. "han block-size d"
  1897. "ata. The key nee"
  1898. "ds to be hashed "
  1899. "before being use"
  1900. "d by the HMAC al"
  1901. "gorithm.",
  1902. .psize = 152,
  1903. .digest = "\xe3\x7b\x6a\x77\x5d\xc8\x7d\xba"
  1904. "\xa4\xdf\xa9\xf9\x6e\x5e\x3f\xfd"
  1905. "\xde\xbd\x71\xf8\x86\x72\x89\x86"
  1906. "\x5d\xf5\xa3\x2d\x20\xcd\xc9\x44"
  1907. "\xb6\x02\x2c\xac\x3c\x49\x82\xb1"
  1908. "\x0d\x5e\xeb\x55\xc3\xe4\xde\x15"
  1909. "\x13\x46\x76\xfb\x6d\xe0\x44\x60"
  1910. "\x65\xc9\x74\x40\xfa\x8c\x6a\x58",
  1911. },
  1912. };
  1913. /*
  1914. * DES test vectors.
  1915. */
  1916. #define DES_ENC_TEST_VECTORS 10
  1917. #define DES_DEC_TEST_VECTORS 4
  1918. #define DES_CBC_ENC_TEST_VECTORS 5
  1919. #define DES_CBC_DEC_TEST_VECTORS 4
  1920. #define DES3_EDE_ENC_TEST_VECTORS 3
  1921. #define DES3_EDE_DEC_TEST_VECTORS 3
  1922. #define DES3_EDE_CBC_ENC_TEST_VECTORS 1
  1923. #define DES3_EDE_CBC_DEC_TEST_VECTORS 1
  1924. static struct cipher_testvec des_enc_tv_template[] = {
  1925. { /* From Applied Cryptography */
  1926. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1927. .klen = 8,
  1928. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
  1929. .ilen = 8,
  1930. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
  1931. .rlen = 8,
  1932. }, { /* Same key, different plaintext block */
  1933. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1934. .klen = 8,
  1935. .input = "\x22\x33\x44\x55\x66\x77\x88\x99",
  1936. .ilen = 8,
  1937. .result = "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
  1938. .rlen = 8,
  1939. }, { /* Sbox test from NBS */
  1940. .key = "\x7c\xa1\x10\x45\x4a\x1a\x6e\x57",
  1941. .klen = 8,
  1942. .input = "\x01\xa1\xd6\xd0\x39\x77\x67\x42",
  1943. .ilen = 8,
  1944. .result = "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
  1945. .rlen = 8,
  1946. }, { /* Three blocks */
  1947. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1948. .klen = 8,
  1949. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  1950. "\x22\x33\x44\x55\x66\x77\x88\x99"
  1951. "\xca\xfe\xba\xbe\xfe\xed\xbe\xef",
  1952. .ilen = 24,
  1953. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  1954. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
  1955. "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90",
  1956. .rlen = 24,
  1957. }, { /* Weak key */
  1958. .fail = 1,
  1959. .wk = 1,
  1960. .key = "\x01\x01\x01\x01\x01\x01\x01\x01",
  1961. .klen = 8,
  1962. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
  1963. .ilen = 8,
  1964. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
  1965. .rlen = 8,
  1966. }, { /* Two blocks -- for testing encryption across pages */
  1967. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1968. .klen = 8,
  1969. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  1970. "\x22\x33\x44\x55\x66\x77\x88\x99",
  1971. .ilen = 16,
  1972. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  1973. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
  1974. .rlen = 16,
  1975. .np = 2,
  1976. .tap = { 8, 8 }
  1977. }, { /* Four blocks -- for testing encryption with chunking */
  1978. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1979. .klen = 8,
  1980. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  1981. "\x22\x33\x44\x55\x66\x77\x88\x99"
  1982. "\xca\xfe\xba\xbe\xfe\xed\xbe\xef"
  1983. "\x22\x33\x44\x55\x66\x77\x88\x99",
  1984. .ilen = 32,
  1985. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  1986. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
  1987. "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90"
  1988. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
  1989. .rlen = 32,
  1990. .np = 3,
  1991. .tap = { 14, 10, 8 }
  1992. }, {
  1993. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  1994. .klen = 8,
  1995. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  1996. "\x22\x33\x44\x55\x66\x77\x88\x99"
  1997. "\xca\xfe\xba\xbe\xfe\xed\xbe\xef",
  1998. .ilen = 24,
  1999. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  2000. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b"
  2001. "\xb4\x99\x26\xf7\x1f\xe1\xd4\x90",
  2002. .rlen = 24,
  2003. .np = 4,
  2004. .tap = { 2, 1, 3, 18 }
  2005. }, {
  2006. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2007. .klen = 8,
  2008. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  2009. "\x22\x33\x44\x55\x66\x77\x88\x99",
  2010. .ilen = 16,
  2011. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  2012. "\xf7\x9c\x89\x2a\x33\x8f\x4a\x8b",
  2013. .rlen = 16,
  2014. .np = 5,
  2015. .tap = { 2, 2, 2, 2, 8 }
  2016. }, {
  2017. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2018. .klen = 8,
  2019. .input = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
  2020. .ilen = 8,
  2021. .result = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
  2022. .rlen = 8,
  2023. .np = 8,
  2024. .tap = { 1, 1, 1, 1, 1, 1, 1, 1 }
  2025. },
  2026. };
  2027. static struct cipher_testvec des_dec_tv_template[] = {
  2028. { /* From Applied Cryptography */
  2029. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2030. .klen = 8,
  2031. .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d",
  2032. .ilen = 8,
  2033. .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7",
  2034. .rlen = 8,
  2035. }, { /* Sbox test from NBS */
  2036. .key = "\x7c\xa1\x10\x45\x4a\x1a\x6e\x57",
  2037. .klen = 8,
  2038. .input = "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
  2039. .ilen = 8,
  2040. .result = "\x01\xa1\xd6\xd0\x39\x77\x67\x42",
  2041. .rlen = 8,
  2042. }, { /* Two blocks, for chunking test */
  2043. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2044. .klen = 8,
  2045. .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  2046. "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
  2047. .ilen = 16,
  2048. .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  2049. "\xa3\x99\x7b\xca\xaf\x69\xa0\xf5",
  2050. .rlen = 16,
  2051. .np = 2,
  2052. .tap = { 8, 8 }
  2053. }, {
  2054. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2055. .klen = 8,
  2056. .input = "\xc9\x57\x44\x25\x6a\x5e\xd3\x1d"
  2057. "\x69\x0f\x5b\x0d\x9a\x26\x93\x9b",
  2058. .ilen = 16,
  2059. .result = "\x01\x23\x45\x67\x89\xab\xcd\xe7"
  2060. "\xa3\x99\x7b\xca\xaf\x69\xa0\xf5",
  2061. .rlen = 16,
  2062. .np = 3,
  2063. .tap = { 3, 12, 1 }
  2064. },
  2065. };
  2066. static struct cipher_testvec des_cbc_enc_tv_template[] = {
  2067. { /* From OpenSSL */
  2068. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2069. .klen = 8,
  2070. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2071. .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
  2072. "\x4e\x6f\x77\x20\x69\x73\x20\x74"
  2073. "\x68\x65\x20\x74\x69\x6d\x65\x20",
  2074. .ilen = 24,
  2075. .result = "\xcc\xd1\x73\xff\xab\x20\x39\xf4"
  2076. "\xac\xd8\xae\xfd\xdf\xd8\xa1\xeb"
  2077. "\x46\x8e\x91\x15\x78\x88\xba\x68",
  2078. .rlen = 24,
  2079. }, { /* FIPS Pub 81 */
  2080. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2081. .klen = 8,
  2082. .iv = "\x12\x34\x56\x78\x90\xab\xcd\xef",
  2083. .input = "\x4e\x6f\x77\x20\x69\x73\x20\x74",
  2084. .ilen = 8,
  2085. .result = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
  2086. .rlen = 8,
  2087. }, {
  2088. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2089. .klen = 8,
  2090. .iv = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
  2091. .input = "\x68\x65\x20\x74\x69\x6d\x65\x20",
  2092. .ilen = 8,
  2093. .result = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
  2094. .rlen = 8,
  2095. }, {
  2096. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2097. .klen = 8,
  2098. .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
  2099. .input = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
  2100. .ilen = 8,
  2101. .result = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
  2102. .rlen = 8,
  2103. }, { /* Copy of openssl vector for chunk testing */
  2104. /* From OpenSSL */
  2105. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2106. .klen = 8,
  2107. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2108. .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
  2109. "\x4e\x6f\x77\x20\x69\x73\x20\x74"
  2110. "\x68\x65\x20\x74\x69\x6d\x65\x20",
  2111. .ilen = 24,
  2112. .result = "\xcc\xd1\x73\xff\xab\x20\x39\xf4"
  2113. "\xac\xd8\xae\xfd\xdf\xd8\xa1\xeb"
  2114. "\x46\x8e\x91\x15\x78\x88\xba\x68",
  2115. .rlen = 24,
  2116. .np = 2,
  2117. .tap = { 13, 11 }
  2118. },
  2119. };
  2120. static struct cipher_testvec des_cbc_dec_tv_template[] = {
  2121. { /* FIPS Pub 81 */
  2122. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2123. .klen = 8,
  2124. .iv = "\x12\x34\x56\x78\x90\xab\xcd\xef",
  2125. .input = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
  2126. .ilen = 8,
  2127. .result = "\x4e\x6f\x77\x20\x69\x73\x20\x74",
  2128. .rlen = 8,
  2129. }, {
  2130. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2131. .klen = 8,
  2132. .iv = "\xe5\xc7\xcd\xde\x87\x2b\xf2\x7c",
  2133. .input = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
  2134. .ilen = 8,
  2135. .result = "\x68\x65\x20\x74\x69\x6d\x65\x20",
  2136. .rlen = 8,
  2137. }, {
  2138. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2139. .klen = 8,
  2140. .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
  2141. .input = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
  2142. .ilen = 8,
  2143. .result = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
  2144. .rlen = 8,
  2145. }, { /* Copy of above, for chunk testing */
  2146. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2147. .klen = 8,
  2148. .iv = "\x43\xe9\x34\x00\x8c\x38\x9c\x0f",
  2149. .input = "\x68\x37\x88\x49\x9a\x7c\x05\xf6",
  2150. .ilen = 8,
  2151. .result = "\x66\x6f\x72\x20\x61\x6c\x6c\x20",
  2152. .rlen = 8,
  2153. .np = 2,
  2154. .tap = { 4, 4 }
  2155. },
  2156. };
  2157. static struct cipher_testvec des3_ede_enc_tv_template[] = {
  2158. { /* These are from openssl */
  2159. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2160. "\x55\x55\x55\x55\x55\x55\x55\x55"
  2161. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2162. .klen = 24,
  2163. .input = "\x73\x6f\x6d\x65\x64\x61\x74\x61",
  2164. .ilen = 8,
  2165. .result = "\x18\xd7\x48\xe5\x63\x62\x05\x72",
  2166. .rlen = 8,
  2167. }, {
  2168. .key = "\x03\x52\x02\x07\x67\x20\x82\x17"
  2169. "\x86\x02\x87\x66\x59\x08\x21\x98"
  2170. "\x64\x05\x6a\xbd\xfe\xa9\x34\x57",
  2171. .klen = 24,
  2172. .input = "\x73\x71\x75\x69\x67\x67\x6c\x65",
  2173. .ilen = 8,
  2174. .result = "\xc0\x7d\x2a\x0f\xa5\x66\xfa\x30",
  2175. .rlen = 8,
  2176. }, {
  2177. .key = "\x10\x46\x10\x34\x89\x98\x80\x20"
  2178. "\x91\x07\xd0\x15\x89\x19\x01\x01"
  2179. "\x19\x07\x92\x10\x98\x1a\x01\x01",
  2180. .klen = 24,
  2181. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2182. .ilen = 8,
  2183. .result = "\xe1\xef\x62\xc3\x32\xfe\x82\x5b",
  2184. .rlen = 8,
  2185. },
  2186. };
  2187. static struct cipher_testvec des3_ede_dec_tv_template[] = {
  2188. { /* These are from openssl */
  2189. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2190. "\x55\x55\x55\x55\x55\x55\x55\x55"
  2191. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2192. .klen = 24,
  2193. .input = "\x18\xd7\x48\xe5\x63\x62\x05\x72",
  2194. .ilen = 8,
  2195. .result = "\x73\x6f\x6d\x65\x64\x61\x74\x61",
  2196. .rlen = 8,
  2197. }, {
  2198. .key = "\x03\x52\x02\x07\x67\x20\x82\x17"
  2199. "\x86\x02\x87\x66\x59\x08\x21\x98"
  2200. "\x64\x05\x6a\xbd\xfe\xa9\x34\x57",
  2201. .klen = 24,
  2202. .input = "\xc0\x7d\x2a\x0f\xa5\x66\xfa\x30",
  2203. .ilen = 8,
  2204. .result = "\x73\x71\x75\x69\x67\x67\x6c\x65",
  2205. .rlen = 8,
  2206. }, {
  2207. .key = "\x10\x46\x10\x34\x89\x98\x80\x20"
  2208. "\x91\x07\xd0\x15\x89\x19\x01\x01"
  2209. "\x19\x07\x92\x10\x98\x1a\x01\x01",
  2210. .klen = 24,
  2211. .input = "\xe1\xef\x62\xc3\x32\xfe\x82\x5b",
  2212. .ilen = 8,
  2213. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2214. .rlen = 8,
  2215. },
  2216. };
  2217. static struct cipher_testvec des3_ede_cbc_enc_tv_template[] = {
  2218. { /* Generated from openssl */
  2219. .key = "\xE9\xC0\xFF\x2E\x76\x0B\x64\x24"
  2220. "\x44\x4D\x99\x5A\x12\xD6\x40\xC0"
  2221. "\xEA\xC2\x84\xE8\x14\x95\xDB\xE8",
  2222. .klen = 24,
  2223. .iv = "\x7D\x33\x88\x93\x0F\x93\xB2\x42",
  2224. .input = "\x6f\x54\x20\x6f\x61\x4d\x79\x6e"
  2225. "\x53\x20\x63\x65\x65\x72\x73\x74"
  2226. "\x54\x20\x6f\x6f\x4d\x20\x6e\x61"
  2227. "\x20\x79\x65\x53\x72\x63\x74\x65"
  2228. "\x20\x73\x6f\x54\x20\x6f\x61\x4d"
  2229. "\x79\x6e\x53\x20\x63\x65\x65\x72"
  2230. "\x73\x74\x54\x20\x6f\x6f\x4d\x20"
  2231. "\x6e\x61\x20\x79\x65\x53\x72\x63"
  2232. "\x74\x65\x20\x73\x6f\x54\x20\x6f"
  2233. "\x61\x4d\x79\x6e\x53\x20\x63\x65"
  2234. "\x65\x72\x73\x74\x54\x20\x6f\x6f"
  2235. "\x4d\x20\x6e\x61\x20\x79\x65\x53"
  2236. "\x72\x63\x74\x65\x20\x73\x6f\x54"
  2237. "\x20\x6f\x61\x4d\x79\x6e\x53\x20"
  2238. "\x63\x65\x65\x72\x73\x74\x54\x20"
  2239. "\x6f\x6f\x4d\x20\x6e\x61\x0a\x79",
  2240. .ilen = 128,
  2241. .result = "\x0e\x2d\xb6\x97\x3c\x56\x33\xf4"
  2242. "\x67\x17\x21\xc7\x6e\x8a\xd5\x49"
  2243. "\x74\xb3\x49\x05\xc5\x1c\xd0\xed"
  2244. "\x12\x56\x5c\x53\x96\xb6\x00\x7d"
  2245. "\x90\x48\xfc\xf5\x8d\x29\x39\xcc"
  2246. "\x8a\xd5\x35\x18\x36\x23\x4e\xd7"
  2247. "\x76\xd1\xda\x0c\x94\x67\xbb\x04"
  2248. "\x8b\xf2\x03\x6c\xa8\xcf\xb6\xea"
  2249. "\x22\x64\x47\xaa\x8f\x75\x13\xbf"
  2250. "\x9f\xc2\xc3\xf0\xc9\x56\xc5\x7a"
  2251. "\x71\x63\x2e\x89\x7b\x1e\x12\xca"
  2252. "\xe2\x5f\xaf\xd8\xa4\xf8\xc9\x7a"
  2253. "\xd6\xf9\x21\x31\x62\x44\x45\xa6"
  2254. "\xd6\xbc\x5a\xd3\x2d\x54\x43\xcc"
  2255. "\x9d\xde\xa5\x70\xe9\x42\x45\x8a"
  2256. "\x6b\xfa\xb1\x91\x13\xb0\xd9\x19",
  2257. .rlen = 128,
  2258. },
  2259. };
  2260. static struct cipher_testvec des3_ede_cbc_dec_tv_template[] = {
  2261. { /* Generated from openssl */
  2262. .key = "\xE9\xC0\xFF\x2E\x76\x0B\x64\x24"
  2263. "\x44\x4D\x99\x5A\x12\xD6\x40\xC0"
  2264. "\xEA\xC2\x84\xE8\x14\x95\xDB\xE8",
  2265. .klen = 24,
  2266. .iv = "\x7D\x33\x88\x93\x0F\x93\xB2\x42",
  2267. .input = "\x0e\x2d\xb6\x97\x3c\x56\x33\xf4"
  2268. "\x67\x17\x21\xc7\x6e\x8a\xd5\x49"
  2269. "\x74\xb3\x49\x05\xc5\x1c\xd0\xed"
  2270. "\x12\x56\x5c\x53\x96\xb6\x00\x7d"
  2271. "\x90\x48\xfc\xf5\x8d\x29\x39\xcc"
  2272. "\x8a\xd5\x35\x18\x36\x23\x4e\xd7"
  2273. "\x76\xd1\xda\x0c\x94\x67\xbb\x04"
  2274. "\x8b\xf2\x03\x6c\xa8\xcf\xb6\xea"
  2275. "\x22\x64\x47\xaa\x8f\x75\x13\xbf"
  2276. "\x9f\xc2\xc3\xf0\xc9\x56\xc5\x7a"
  2277. "\x71\x63\x2e\x89\x7b\x1e\x12\xca"
  2278. "\xe2\x5f\xaf\xd8\xa4\xf8\xc9\x7a"
  2279. "\xd6\xf9\x21\x31\x62\x44\x45\xa6"
  2280. "\xd6\xbc\x5a\xd3\x2d\x54\x43\xcc"
  2281. "\x9d\xde\xa5\x70\xe9\x42\x45\x8a"
  2282. "\x6b\xfa\xb1\x91\x13\xb0\xd9\x19",
  2283. .ilen = 128,
  2284. .result = "\x6f\x54\x20\x6f\x61\x4d\x79\x6e"
  2285. "\x53\x20\x63\x65\x65\x72\x73\x74"
  2286. "\x54\x20\x6f\x6f\x4d\x20\x6e\x61"
  2287. "\x20\x79\x65\x53\x72\x63\x74\x65"
  2288. "\x20\x73\x6f\x54\x20\x6f\x61\x4d"
  2289. "\x79\x6e\x53\x20\x63\x65\x65\x72"
  2290. "\x73\x74\x54\x20\x6f\x6f\x4d\x20"
  2291. "\x6e\x61\x20\x79\x65\x53\x72\x63"
  2292. "\x74\x65\x20\x73\x6f\x54\x20\x6f"
  2293. "\x61\x4d\x79\x6e\x53\x20\x63\x65"
  2294. "\x65\x72\x73\x74\x54\x20\x6f\x6f"
  2295. "\x4d\x20\x6e\x61\x20\x79\x65\x53"
  2296. "\x72\x63\x74\x65\x20\x73\x6f\x54"
  2297. "\x20\x6f\x61\x4d\x79\x6e\x53\x20"
  2298. "\x63\x65\x65\x72\x73\x74\x54\x20"
  2299. "\x6f\x6f\x4d\x20\x6e\x61\x0a\x79",
  2300. .rlen = 128,
  2301. },
  2302. };
  2303. /*
  2304. * Blowfish test vectors.
  2305. */
  2306. #define BF_ENC_TEST_VECTORS 7
  2307. #define BF_DEC_TEST_VECTORS 7
  2308. #define BF_CBC_ENC_TEST_VECTORS 2
  2309. #define BF_CBC_DEC_TEST_VECTORS 2
  2310. #define BF_CTR_ENC_TEST_VECTORS 2
  2311. #define BF_CTR_DEC_TEST_VECTORS 2
  2312. static struct cipher_testvec bf_enc_tv_template[] = {
  2313. { /* DES test vectors from OpenSSL */
  2314. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2315. .klen = 8,
  2316. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2317. .ilen = 8,
  2318. .result = "\x4e\xf9\x97\x45\x61\x98\xdd\x78",
  2319. .rlen = 8,
  2320. }, {
  2321. .key = "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e",
  2322. .klen = 8,
  2323. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2324. .ilen = 8,
  2325. .result = "\xa7\x90\x79\x51\x08\xea\x3c\xae",
  2326. .rlen = 8,
  2327. }, {
  2328. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  2329. .klen = 8,
  2330. .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2331. .ilen = 8,
  2332. .result = "\xe8\x7a\x24\x4e\x2c\xc8\x5e\x82",
  2333. .rlen = 8,
  2334. }, { /* Vary the keylength... */
  2335. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2336. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f",
  2337. .klen = 16,
  2338. .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2339. .ilen = 8,
  2340. .result = "\x93\x14\x28\x87\xee\x3b\xe1\x5c",
  2341. .rlen = 8,
  2342. }, {
  2343. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2344. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
  2345. "\x00\x11\x22\x33\x44",
  2346. .klen = 21,
  2347. .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2348. .ilen = 8,
  2349. .result = "\xe6\xf5\x1e\xd7\x9b\x9d\xb2\x1f",
  2350. .rlen = 8,
  2351. }, { /* Generated with bf488 */
  2352. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2353. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
  2354. "\x00\x11\x22\x33\x44\x55\x66\x77"
  2355. "\x04\x68\x91\x04\xc2\xfd\x3b\x2f"
  2356. "\x58\x40\x23\x64\x1a\xba\x61\x76"
  2357. "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e"
  2358. "\xff\xff\xff\xff\xff\xff\xff\xff",
  2359. .klen = 56,
  2360. .input = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2361. .ilen = 8,
  2362. .result = "\xc0\x45\x04\x01\x2e\x4e\x1f\x53",
  2363. .rlen = 8,
  2364. }, { /* Generated with Crypto++ */
  2365. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2366. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2367. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2368. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2369. .klen = 32,
  2370. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2371. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2372. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2373. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2374. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2375. .ilen = 40,
  2376. .result = "\x96\x87\x3D\x0C\x7B\xFB\xBD\x1F"
  2377. "\xE3\xC1\x99\x6D\x39\xD4\xC2\x7D"
  2378. "\xD7\x87\xA1\xF2\xDF\x51\x71\x26"
  2379. "\xC2\xF4\x6D\xFF\xF6\xCD\x6B\x40"
  2380. "\xE1\xB3\xBF\xD4\x38\x2B\xC8\x3B",
  2381. .rlen = 40,
  2382. },
  2383. };
  2384. static struct cipher_testvec bf_dec_tv_template[] = {
  2385. { /* DES test vectors from OpenSSL */
  2386. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2387. .klen = 8,
  2388. .input = "\x4e\xf9\x97\x45\x61\x98\xdd\x78",
  2389. .ilen = 8,
  2390. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  2391. .rlen = 8,
  2392. }, {
  2393. .key = "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e",
  2394. .klen = 8,
  2395. .input = "\xa7\x90\x79\x51\x08\xea\x3c\xae",
  2396. .ilen = 8,
  2397. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  2398. .rlen = 8,
  2399. }, {
  2400. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  2401. .klen = 8,
  2402. .input = "\xe8\x7a\x24\x4e\x2c\xc8\x5e\x82",
  2403. .ilen = 8,
  2404. .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2405. .rlen = 8,
  2406. }, { /* Vary the keylength... */
  2407. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2408. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f",
  2409. .klen = 16,
  2410. .input = "\x93\x14\x28\x87\xee\x3b\xe1\x5c",
  2411. .ilen = 8,
  2412. .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2413. .rlen = 8,
  2414. }, {
  2415. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2416. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
  2417. "\x00\x11\x22\x33\x44",
  2418. .klen = 21,
  2419. .input = "\xe6\xf5\x1e\xd7\x9b\x9d\xb2\x1f",
  2420. .ilen = 8,
  2421. .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2422. .rlen = 8,
  2423. }, { /* Generated with bf488, using OpenSSL, Libgcrypt and Nettle */
  2424. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87"
  2425. "\x78\x69\x5a\x4b\x3c\x2d\x1e\x0f"
  2426. "\x00\x11\x22\x33\x44\x55\x66\x77"
  2427. "\x04\x68\x91\x04\xc2\xfd\x3b\x2f"
  2428. "\x58\x40\x23\x64\x1a\xba\x61\x76"
  2429. "\x1f\x1f\x1f\x1f\x0e\x0e\x0e\x0e"
  2430. "\xff\xff\xff\xff\xff\xff\xff\xff",
  2431. .klen = 56,
  2432. .input = "\xc0\x45\x04\x01\x2e\x4e\x1f\x53",
  2433. .ilen = 8,
  2434. .result = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2435. .rlen = 8,
  2436. }, { /* Generated with Crypto++ */
  2437. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2438. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2439. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2440. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2441. .klen = 32,
  2442. .input = "\x96\x87\x3D\x0C\x7B\xFB\xBD\x1F"
  2443. "\xE3\xC1\x99\x6D\x39\xD4\xC2\x7D"
  2444. "\xD7\x87\xA1\xF2\xDF\x51\x71\x26"
  2445. "\xC2\xF4\x6D\xFF\xF6\xCD\x6B\x40"
  2446. "\xE1\xB3\xBF\xD4\x38\x2B\xC8\x3B",
  2447. .ilen = 40,
  2448. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2449. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2450. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2451. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2452. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2453. .rlen = 40,
  2454. },
  2455. };
  2456. static struct cipher_testvec bf_cbc_enc_tv_template[] = {
  2457. { /* From OpenSSL */
  2458. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2459. "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  2460. .klen = 16,
  2461. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2462. .input = "\x37\x36\x35\x34\x33\x32\x31\x20"
  2463. "\x4e\x6f\x77\x20\x69\x73\x20\x74"
  2464. "\x68\x65\x20\x74\x69\x6d\x65\x20"
  2465. "\x66\x6f\x72\x20\x00\x00\x00\x00",
  2466. .ilen = 32,
  2467. .result = "\x6b\x77\xb4\xd6\x30\x06\xde\xe6"
  2468. "\x05\xb1\x56\xe2\x74\x03\x97\x93"
  2469. "\x58\xde\xb9\xe7\x15\x46\x16\xd9"
  2470. "\x59\xf1\x65\x2b\xd5\xff\x92\xcc",
  2471. .rlen = 32,
  2472. }, { /* Generated with Crypto++ */
  2473. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2474. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2475. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2476. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2477. .klen = 32,
  2478. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2479. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2480. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2481. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2482. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2483. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2484. .ilen = 40,
  2485. .result = "\xB4\xFE\xA5\xBB\x3D\x2C\x27\x06"
  2486. "\x06\x2B\x3A\x92\xB2\xF5\x5E\x62"
  2487. "\x84\xCD\xF7\x66\x7E\x41\x6C\x8E"
  2488. "\x1B\xD9\x02\xB6\x48\xB0\x87\x25"
  2489. "\x01\x9C\x93\x63\x51\x60\x82\xD2",
  2490. .rlen = 40,
  2491. },
  2492. };
  2493. static struct cipher_testvec bf_cbc_dec_tv_template[] = {
  2494. { /* From OpenSSL */
  2495. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2496. "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  2497. .klen = 16,
  2498. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  2499. .input = "\x6b\x77\xb4\xd6\x30\x06\xde\xe6"
  2500. "\x05\xb1\x56\xe2\x74\x03\x97\x93"
  2501. "\x58\xde\xb9\xe7\x15\x46\x16\xd9"
  2502. "\x59\xf1\x65\x2b\xd5\xff\x92\xcc",
  2503. .ilen = 32,
  2504. .result = "\x37\x36\x35\x34\x33\x32\x31\x20"
  2505. "\x4e\x6f\x77\x20\x69\x73\x20\x74"
  2506. "\x68\x65\x20\x74\x69\x6d\x65\x20"
  2507. "\x66\x6f\x72\x20\x00\x00\x00\x00",
  2508. .rlen = 32,
  2509. }, { /* Generated with Crypto++ */
  2510. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2511. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2512. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2513. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2514. .klen = 32,
  2515. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2516. .input = "\xB4\xFE\xA5\xBB\x3D\x2C\x27\x06"
  2517. "\x06\x2B\x3A\x92\xB2\xF5\x5E\x62"
  2518. "\x84\xCD\xF7\x66\x7E\x41\x6C\x8E"
  2519. "\x1B\xD9\x02\xB6\x48\xB0\x87\x25"
  2520. "\x01\x9C\x93\x63\x51\x60\x82\xD2",
  2521. .ilen = 40,
  2522. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2523. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2524. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2525. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2526. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2527. .rlen = 40,
  2528. },
  2529. };
  2530. static struct cipher_testvec bf_ctr_enc_tv_template[] = {
  2531. { /* Generated with Crypto++ */
  2532. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2533. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2534. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2535. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2536. .klen = 32,
  2537. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2538. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2539. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2540. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2541. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2542. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2543. .ilen = 40,
  2544. .result = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
  2545. "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
  2546. "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
  2547. "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
  2548. "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC",
  2549. .rlen = 40,
  2550. }, { /* Generated with Crypto++ */
  2551. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2552. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2553. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2554. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2555. .klen = 32,
  2556. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2557. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2558. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2559. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2560. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2561. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2562. "\x6D\x04\x9B",
  2563. .ilen = 43,
  2564. .result = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
  2565. "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
  2566. "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
  2567. "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
  2568. "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC"
  2569. "\x3D\xA7\xE9",
  2570. .rlen = 43,
  2571. },
  2572. };
  2573. static struct cipher_testvec bf_ctr_dec_tv_template[] = {
  2574. { /* Generated with Crypto++ */
  2575. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2576. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2577. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2578. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2579. .klen = 32,
  2580. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2581. .input = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
  2582. "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
  2583. "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
  2584. "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
  2585. "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC",
  2586. .ilen = 40,
  2587. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2588. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2589. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2590. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2591. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9",
  2592. .rlen = 40,
  2593. }, { /* Generated with Crypto++ */
  2594. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2595. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2596. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2597. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2598. .klen = 32,
  2599. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F",
  2600. .input = "\xC7\xA3\xDF\xB9\x05\xF4\x9E\x8D"
  2601. "\x9E\xDF\x38\x18\x83\x07\xEF\xC1"
  2602. "\x93\x3C\xAA\xAA\xFE\x06\x42\xCC"
  2603. "\x0D\x70\x86\x5A\x44\xAD\x85\x17"
  2604. "\xE4\x1F\x5E\xA5\x89\xAC\x32\xBC"
  2605. "\x3D\xA7\xE9",
  2606. .ilen = 43,
  2607. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2608. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2609. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2610. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2611. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2612. "\x6D\x04\x9B",
  2613. .rlen = 43,
  2614. },
  2615. };
  2616. /*
  2617. * Twofish test vectors.
  2618. */
  2619. #define TF_ENC_TEST_VECTORS 4
  2620. #define TF_DEC_TEST_VECTORS 4
  2621. #define TF_CBC_ENC_TEST_VECTORS 5
  2622. #define TF_CBC_DEC_TEST_VECTORS 5
  2623. #define TF_CTR_ENC_TEST_VECTORS 2
  2624. #define TF_CTR_DEC_TEST_VECTORS 2
  2625. #define TF_LRW_ENC_TEST_VECTORS 8
  2626. #define TF_LRW_DEC_TEST_VECTORS 8
  2627. #define TF_XTS_ENC_TEST_VECTORS 5
  2628. #define TF_XTS_DEC_TEST_VECTORS 5
  2629. static struct cipher_testvec tf_enc_tv_template[] = {
  2630. {
  2631. .key = zeroed_string,
  2632. .klen = 16,
  2633. .input = zeroed_string,
  2634. .ilen = 16,
  2635. .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2636. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2637. .rlen = 16,
  2638. }, {
  2639. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2640. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  2641. "\x00\x11\x22\x33\x44\x55\x66\x77",
  2642. .klen = 24,
  2643. .input = zeroed_string,
  2644. .ilen = 16,
  2645. .result = "\xcf\xd1\xd2\xe5\xa9\xbe\x9c\xdf"
  2646. "\x50\x1f\x13\xb8\x92\xbd\x22\x48",
  2647. .rlen = 16,
  2648. }, {
  2649. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2650. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  2651. "\x00\x11\x22\x33\x44\x55\x66\x77"
  2652. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  2653. .klen = 32,
  2654. .input = zeroed_string,
  2655. .ilen = 16,
  2656. .result = "\x37\x52\x7b\xe0\x05\x23\x34\xb8"
  2657. "\x9f\x0c\xfc\xca\xe8\x7c\xfa\x20",
  2658. .rlen = 16,
  2659. }, { /* Generated with Crypto++ */
  2660. .key = "\x3F\x85\x62\x3F\x1C\xF9\xD6\x1C"
  2661. "\xF9\xD6\xB3\x90\x6D\x4A\x90\x6D"
  2662. "\x4A\x27\x04\xE1\x27\x04\xE1\xBE"
  2663. "\x9B\x78\xBE\x9B\x78\x55\x32\x0F",
  2664. .klen = 32,
  2665. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2666. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2667. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2668. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2669. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2670. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2671. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2672. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2673. .ilen = 64,
  2674. .result = "\x88\xCB\x1E\xC2\xAF\x8A\x97\xFF"
  2675. "\xF6\x90\x46\x9C\x4A\x0F\x08\xDC"
  2676. "\xDE\xAB\xAD\xFA\xFC\xA8\xC2\x3D"
  2677. "\xE0\xE4\x8B\x3F\xD5\xA3\xF7\x14"
  2678. "\x34\x9E\xB6\x08\xB2\xDD\xA8\xF5"
  2679. "\xDF\xFA\xC7\xE8\x09\x50\x76\x08"
  2680. "\xA2\xB6\x6A\x59\xC0\x2B\x6D\x05"
  2681. "\x89\xF6\x82\xF0\xD3\xDB\x06\x02",
  2682. .rlen = 64,
  2683. },
  2684. };
  2685. static struct cipher_testvec tf_dec_tv_template[] = {
  2686. {
  2687. .key = zeroed_string,
  2688. .klen = 16,
  2689. .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2690. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2691. .ilen = 16,
  2692. .result = zeroed_string,
  2693. .rlen = 16,
  2694. }, {
  2695. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2696. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  2697. "\x00\x11\x22\x33\x44\x55\x66\x77",
  2698. .klen = 24,
  2699. .input = "\xcf\xd1\xd2\xe5\xa9\xbe\x9c\xdf"
  2700. "\x50\x1f\x13\xb8\x92\xbd\x22\x48",
  2701. .ilen = 16,
  2702. .result = zeroed_string,
  2703. .rlen = 16,
  2704. }, {
  2705. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  2706. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  2707. "\x00\x11\x22\x33\x44\x55\x66\x77"
  2708. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  2709. .klen = 32,
  2710. .input = "\x37\x52\x7b\xe0\x05\x23\x34\xb8"
  2711. "\x9f\x0c\xfc\xca\xe8\x7c\xfa\x20",
  2712. .ilen = 16,
  2713. .result = zeroed_string,
  2714. .rlen = 16,
  2715. }, { /* Generated with Crypto++ */
  2716. .key = "\x3F\x85\x62\x3F\x1C\xF9\xD6\x1C"
  2717. "\xF9\xD6\xB3\x90\x6D\x4A\x90\x6D"
  2718. "\x4A\x27\x04\xE1\x27\x04\xE1\xBE"
  2719. "\x9B\x78\xBE\x9B\x78\x55\x32\x0F",
  2720. .klen = 32,
  2721. .input = "\x88\xCB\x1E\xC2\xAF\x8A\x97\xFF"
  2722. "\xF6\x90\x46\x9C\x4A\x0F\x08\xDC"
  2723. "\xDE\xAB\xAD\xFA\xFC\xA8\xC2\x3D"
  2724. "\xE0\xE4\x8B\x3F\xD5\xA3\xF7\x14"
  2725. "\x34\x9E\xB6\x08\xB2\xDD\xA8\xF5"
  2726. "\xDF\xFA\xC7\xE8\x09\x50\x76\x08"
  2727. "\xA2\xB6\x6A\x59\xC0\x2B\x6D\x05"
  2728. "\x89\xF6\x82\xF0\xD3\xDB\x06\x02",
  2729. .ilen = 64,
  2730. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2731. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2732. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2733. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2734. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2735. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2736. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2737. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2738. .rlen = 64,
  2739. },
  2740. };
  2741. static struct cipher_testvec tf_cbc_enc_tv_template[] = {
  2742. { /* Generated with Nettle */
  2743. .key = zeroed_string,
  2744. .klen = 16,
  2745. .iv = zeroed_string,
  2746. .input = zeroed_string,
  2747. .ilen = 16,
  2748. .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2749. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2750. .rlen = 16,
  2751. }, {
  2752. .key = zeroed_string,
  2753. .klen = 16,
  2754. .iv = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2755. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2756. .input = zeroed_string,
  2757. .ilen = 16,
  2758. .result = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2759. "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
  2760. .rlen = 16,
  2761. }, {
  2762. .key = zeroed_string,
  2763. .klen = 16,
  2764. .iv = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2765. "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
  2766. .input = zeroed_string,
  2767. .ilen = 16,
  2768. .result = "\x05\xef\x8c\x61\xa8\x11\x58\x26"
  2769. "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
  2770. .rlen = 16,
  2771. }, {
  2772. .key = zeroed_string,
  2773. .klen = 16,
  2774. .iv = zeroed_string,
  2775. .input = zeroed_string,
  2776. .ilen = 48,
  2777. .result = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2778. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a"
  2779. "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2780. "\x86\xcb\x08\x6b\x78\x9f\x54\x19"
  2781. "\x05\xef\x8c\x61\xa8\x11\x58\x26"
  2782. "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
  2783. .rlen = 48,
  2784. }, { /* Generated with Crypto++ */
  2785. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2786. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2787. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2788. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2789. .klen = 32,
  2790. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2791. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2792. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2793. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2794. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2795. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2796. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2797. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2798. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2799. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2800. .ilen = 64,
  2801. .result = "\xC8\xFF\xF2\x53\xA6\x27\x09\xD1"
  2802. "\x33\x38\xC2\xC0\x0C\x14\x7E\xB5"
  2803. "\x26\x1B\x05\x0C\x05\x12\x3F\xC0"
  2804. "\xF9\x1C\x02\x28\x40\x96\x6F\xD0"
  2805. "\x3D\x32\xDF\xDA\x56\x00\x6E\xEE"
  2806. "\x5B\x2A\x72\x9D\xC2\x4D\x19\xBC"
  2807. "\x8C\x53\xFA\x87\x6F\xDD\x81\xA3"
  2808. "\xB1\xD3\x44\x65\xDF\xE7\x63\x38",
  2809. .rlen = 64,
  2810. },
  2811. };
  2812. static struct cipher_testvec tf_cbc_dec_tv_template[] = {
  2813. { /* Reverse of the first four above */
  2814. .key = zeroed_string,
  2815. .klen = 16,
  2816. .iv = zeroed_string,
  2817. .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2818. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2819. .ilen = 16,
  2820. .result = zeroed_string,
  2821. .rlen = 16,
  2822. }, {
  2823. .key = zeroed_string,
  2824. .klen = 16,
  2825. .iv = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2826. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a",
  2827. .input = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2828. "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
  2829. .ilen = 16,
  2830. .result = zeroed_string,
  2831. .rlen = 16,
  2832. }, {
  2833. .key = zeroed_string,
  2834. .klen = 16,
  2835. .iv = "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2836. "\x86\xcb\x08\x6b\x78\x9f\x54\x19",
  2837. .input = "\x05\xef\x8c\x61\xa8\x11\x58\x26"
  2838. "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
  2839. .ilen = 16,
  2840. .result = zeroed_string,
  2841. .rlen = 16,
  2842. }, {
  2843. .key = zeroed_string,
  2844. .klen = 16,
  2845. .iv = zeroed_string,
  2846. .input = "\x9f\x58\x9f\x5c\xf6\x12\x2c\x32"
  2847. "\xb6\xbf\xec\x2f\x2a\xe8\xc3\x5a"
  2848. "\xd4\x91\xdb\x16\xe7\xb1\xc3\x9e"
  2849. "\x86\xcb\x08\x6b\x78\x9f\x54\x19"
  2850. "\x05\xef\x8c\x61\xa8\x11\x58\x26"
  2851. "\x34\xba\x5c\xb7\x10\x6a\xa6\x41",
  2852. .ilen = 48,
  2853. .result = zeroed_string,
  2854. .rlen = 48,
  2855. }, { /* Generated with Crypto++ */
  2856. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2857. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2858. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2859. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2860. .klen = 32,
  2861. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2862. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2863. .input = "\xC8\xFF\xF2\x53\xA6\x27\x09\xD1"
  2864. "\x33\x38\xC2\xC0\x0C\x14\x7E\xB5"
  2865. "\x26\x1B\x05\x0C\x05\x12\x3F\xC0"
  2866. "\xF9\x1C\x02\x28\x40\x96\x6F\xD0"
  2867. "\x3D\x32\xDF\xDA\x56\x00\x6E\xEE"
  2868. "\x5B\x2A\x72\x9D\xC2\x4D\x19\xBC"
  2869. "\x8C\x53\xFA\x87\x6F\xDD\x81\xA3"
  2870. "\xB1\xD3\x44\x65\xDF\xE7\x63\x38",
  2871. .ilen = 64,
  2872. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2873. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2874. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2875. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2876. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2877. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2878. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2879. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2880. .rlen = 64,
  2881. },
  2882. };
  2883. static struct cipher_testvec tf_ctr_enc_tv_template[] = {
  2884. { /* Generated with Crypto++ */
  2885. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2886. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2887. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2888. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2889. .klen = 32,
  2890. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2891. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2892. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2893. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2894. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2895. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2896. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2897. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2898. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2899. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2900. .ilen = 64,
  2901. .result = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
  2902. "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
  2903. "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
  2904. "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
  2905. "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
  2906. "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
  2907. "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
  2908. "\x01\x41\x21\x12\x38\xAB\x52\x4F",
  2909. .rlen = 64,
  2910. }, { /* Generated with Crypto++ */
  2911. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2912. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2913. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2914. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2915. .klen = 32,
  2916. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2917. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2918. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2919. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2920. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2921. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2922. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2923. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2924. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2925. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  2926. "\xC3\x37\xCE",
  2927. .ilen = 67,
  2928. .result = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
  2929. "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
  2930. "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
  2931. "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
  2932. "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
  2933. "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
  2934. "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
  2935. "\x01\x41\x21\x12\x38\xAB\x52\x4F"
  2936. "\xA8\x57\x20",
  2937. .rlen = 67,
  2938. },
  2939. };
  2940. static struct cipher_testvec tf_ctr_dec_tv_template[] = {
  2941. { /* Generated with Crypto++ */
  2942. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2943. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2944. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2945. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2946. .klen = 32,
  2947. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2948. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2949. .input = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
  2950. "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
  2951. "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
  2952. "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
  2953. "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
  2954. "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
  2955. "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
  2956. "\x01\x41\x21\x12\x38\xAB\x52\x4F",
  2957. .ilen = 64,
  2958. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2959. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2960. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2961. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2962. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2963. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2964. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2965. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C",
  2966. .rlen = 64,
  2967. }, { /* Generated with Crypto++ */
  2968. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  2969. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  2970. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  2971. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  2972. .klen = 32,
  2973. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  2974. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  2975. .input = "\xDF\xDD\x69\xFA\xB0\x2E\xFD\xFE"
  2976. "\x70\x9E\xC5\x4B\xC9\xD4\xA1\x30"
  2977. "\x26\x9B\x89\xA1\xEE\x43\xE0\x52"
  2978. "\x55\x17\x4E\xC7\x0E\x33\x1F\xF1"
  2979. "\x9F\x8D\x40\x9F\x24\xFD\x92\xA0"
  2980. "\xBC\x8F\x35\xDD\x67\x38\xD8\xAA"
  2981. "\xCF\xF8\x48\xCA\xFB\xE4\x5C\x60"
  2982. "\x01\x41\x21\x12\x38\xAB\x52\x4F"
  2983. "\xA8\x57\x20",
  2984. .ilen = 67,
  2985. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  2986. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  2987. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  2988. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  2989. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  2990. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  2991. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  2992. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  2993. "\xC3\x37\xCE",
  2994. .rlen = 67,
  2995. },
  2996. };
  2997. static struct cipher_testvec tf_lrw_enc_tv_template[] = {
  2998. /* Generated from AES-LRW test vectors */
  2999. {
  3000. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  3001. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  3002. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  3003. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  3004. .klen = 32,
  3005. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3006. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3007. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3008. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3009. .ilen = 16,
  3010. .result = "\xa1\x6c\x50\x69\x26\xa4\xef\x7b"
  3011. "\x7c\xc6\x91\xeb\x72\xdd\x9b\xee",
  3012. .rlen = 16,
  3013. }, {
  3014. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  3015. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  3016. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  3017. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  3018. .klen = 32,
  3019. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3020. "\x00\x00\x00\x00\x00\x00\x00\x02",
  3021. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3022. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3023. .ilen = 16,
  3024. .result = "\xab\x72\x0a\xad\x3b\x0c\xf0\xc9"
  3025. "\x42\x2f\xf1\xae\xf1\x3c\xb1\xbd",
  3026. .rlen = 16,
  3027. }, {
  3028. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  3029. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  3030. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  3031. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  3032. .klen = 32,
  3033. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3034. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3035. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3036. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3037. .ilen = 16,
  3038. .result = "\x85\xa7\x56\x67\x08\xfa\x42\xe1"
  3039. "\x22\xe6\x82\xfc\xd9\xb4\xd7\xd4",
  3040. .rlen = 16,
  3041. }, {
  3042. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  3043. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  3044. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  3045. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  3046. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  3047. .klen = 40,
  3048. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3049. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3050. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3051. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3052. .ilen = 16,
  3053. .result = "\xd2\xaf\x69\x35\x24\x1d\x0e\x1c"
  3054. "\x84\x8b\x05\xe4\xa2\x2f\x16\xf5",
  3055. .rlen = 16,
  3056. }, {
  3057. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  3058. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  3059. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  3060. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  3061. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  3062. .klen = 40,
  3063. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3064. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3065. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3066. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3067. .ilen = 16,
  3068. .result = "\x4a\x23\x56\xd7\xff\x90\xd0\x9a"
  3069. "\x0d\x7c\x26\xfc\xf0\xf0\xf6\xe4",
  3070. .rlen = 16,
  3071. }, {
  3072. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  3073. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  3074. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  3075. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  3076. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  3077. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  3078. .klen = 48,
  3079. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3080. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3081. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3082. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3083. .ilen = 16,
  3084. .result = "\x30\xaf\x26\x05\x9d\x5d\x0a\x58"
  3085. "\xe2\xe7\xce\x8a\xb2\x56\x6d\x76",
  3086. .rlen = 16,
  3087. }, {
  3088. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  3089. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  3090. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  3091. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  3092. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  3093. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  3094. .klen = 48,
  3095. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3096. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3097. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3098. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3099. .ilen = 16,
  3100. .result = "\xdf\xcf\xdc\xd2\xe1\xcf\x86\x75"
  3101. "\x17\x66\x5e\x0c\x14\xa1\x3d\x40",
  3102. .rlen = 16,
  3103. }, {
  3104. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  3105. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  3106. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  3107. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  3108. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  3109. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  3110. .klen = 48,
  3111. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3112. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3113. .input = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  3114. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  3115. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  3116. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  3117. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  3118. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  3119. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  3120. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  3121. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  3122. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  3123. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  3124. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  3125. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  3126. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  3127. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  3128. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  3129. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  3130. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  3131. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  3132. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  3133. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  3134. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  3135. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  3136. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  3137. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  3138. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  3139. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  3140. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  3141. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  3142. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  3143. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  3144. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  3145. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  3146. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  3147. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  3148. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  3149. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  3150. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  3151. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  3152. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  3153. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  3154. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  3155. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  3156. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  3157. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  3158. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  3159. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  3160. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  3161. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  3162. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  3163. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  3164. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  3165. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  3166. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  3167. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  3168. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  3169. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  3170. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  3171. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  3172. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  3173. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  3174. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  3175. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  3176. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  3177. .ilen = 512,
  3178. .result = "\x30\x38\xeb\xaf\x12\x43\x1a\x89"
  3179. "\x62\xa2\x36\xe5\xcf\x77\x1e\xd9"
  3180. "\x08\xc3\x0d\xdd\x95\xab\x19\x96"
  3181. "\x27\x52\x41\xc3\xca\xfb\xf6\xee"
  3182. "\x40\x2d\xdf\xdd\x00\x0c\xb9\x0a"
  3183. "\x3a\xf0\xc0\xd1\xda\x63\x9e\x45"
  3184. "\x42\xe9\x29\xc0\xb4\x07\xb4\x31"
  3185. "\x66\x77\x72\xb5\xb6\xb3\x57\x46"
  3186. "\x34\x9a\xfe\x03\xaf\x6b\x36\x07"
  3187. "\x63\x8e\xc2\x5d\xa6\x0f\xb6\x7d"
  3188. "\xfb\x6d\x82\x51\xb6\x98\xd0\x71"
  3189. "\xe7\x10\x7a\xdf\xb2\xbd\xf1\x1d"
  3190. "\x72\x2b\x54\x13\xe3\x6d\x79\x37"
  3191. "\xa9\x39\x2c\xdf\x21\xab\x87\xd5"
  3192. "\xee\xef\x9a\x12\x50\x39\x2e\x1b"
  3193. "\x7d\xe6\x6a\x27\x48\xb9\xe7\xac"
  3194. "\xaa\xcd\x79\x5f\xf2\xf3\xa0\x08"
  3195. "\x6f\x2c\xf4\x0e\xd1\xb8\x89\x25"
  3196. "\x31\x9d\xef\xb1\x1d\x27\x55\x04"
  3197. "\xc9\x8c\xb7\x68\xdc\xb6\x67\x8a"
  3198. "\xdb\xcf\x22\xf2\x3b\x6f\xce\xbb"
  3199. "\x26\xbe\x4f\x27\x04\x42\xd1\x44"
  3200. "\x4c\x08\xa3\x95\x4c\x7f\x1a\xaf"
  3201. "\x1d\x28\x14\xfd\xb1\x1a\x34\x18"
  3202. "\xf5\x1e\x28\x69\x95\x6a\x5a\xba"
  3203. "\x8e\xb2\x58\x1d\x28\x17\x13\x3d"
  3204. "\x38\x7d\x14\x8d\xab\x5d\xf9\xe8"
  3205. "\x3c\x0f\x2b\x0d\x2b\x08\xb4\x4b"
  3206. "\x6b\x0d\xc8\xa7\x84\xc2\x3a\x1a"
  3207. "\xb7\xbd\xda\x92\x29\xb8\x5b\x5a"
  3208. "\x63\xa5\x99\x82\x09\x72\x8f\xc6"
  3209. "\xa4\x62\x24\x69\x8c\x2d\x26\x00"
  3210. "\x99\x83\x91\xd6\xc6\xcf\x57\x67"
  3211. "\x38\xea\xf2\xfc\x29\xe0\x73\x39"
  3212. "\xf9\x13\x94\x6d\xe2\x58\x28\x75"
  3213. "\x3e\xae\x71\x90\x07\x70\x1c\x38"
  3214. "\x5b\x4c\x1e\xb5\xa5\x3b\x20\xef"
  3215. "\xb1\x4c\x3e\x1a\x72\x62\xbb\x22"
  3216. "\x82\x09\xe3\x18\x3f\x4f\x48\xfc"
  3217. "\xdd\xac\xfc\xb6\x09\xdb\xd2\x7b"
  3218. "\xd6\xb7\x7e\x41\x2f\x14\xf5\x0e"
  3219. "\xc3\xac\x4a\xed\xe7\x82\xef\x31"
  3220. "\x1f\x1a\x51\x1e\x29\x60\xc8\x98"
  3221. "\x93\x51\x1d\x3d\x62\x59\x83\x82"
  3222. "\x0c\xf1\xd7\x8d\xac\x33\x44\x81"
  3223. "\x3c\x59\xb7\xd4\x5b\x65\x82\xc4"
  3224. "\xec\xdc\x24\xfd\x0e\x1a\x79\x94"
  3225. "\x34\xb0\x62\xfa\x98\x49\x26\x1f"
  3226. "\xf4\x9e\x40\x44\x5b\x1f\xf8\xbe"
  3227. "\x36\xff\xc6\xc6\x9d\xf2\xd6\xcc"
  3228. "\x63\x93\x29\xb9\x0b\x6d\xd7\x6c"
  3229. "\xdb\xf6\x21\x80\xf7\x5a\x37\x15"
  3230. "\x0c\xe3\x36\xc8\x74\x75\x20\x91"
  3231. "\xdf\x52\x2d\x0c\xe7\x45\xff\x46"
  3232. "\xb3\xf4\xec\xc2\xbd\xd3\x37\xb6"
  3233. "\x26\xa2\x5d\x7d\x61\xbf\x10\x46"
  3234. "\x57\x8d\x05\x96\x70\x0b\xd6\x41"
  3235. "\x5c\xe9\xd3\x54\x81\x39\x3a\xdd"
  3236. "\x5f\x92\x81\x6e\x35\x03\xd4\x72"
  3237. "\x3d\x5a\xe7\xb9\x3b\x0c\x84\x23"
  3238. "\x45\x5d\xec\x72\xc1\x52\xef\x2e"
  3239. "\x81\x00\xd3\xfe\x4c\x3c\x05\x61"
  3240. "\x80\x18\xc4\x6c\x03\xd3\xb7\xba"
  3241. "\x11\xd7\xb8\x6e\xea\xe1\x80\x30",
  3242. .rlen = 512,
  3243. },
  3244. };
  3245. static struct cipher_testvec tf_lrw_dec_tv_template[] = {
  3246. /* Generated from AES-LRW test vectors */
  3247. /* same as enc vectors with input and result reversed */
  3248. {
  3249. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  3250. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  3251. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  3252. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  3253. .klen = 32,
  3254. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3255. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3256. .input = "\xa1\x6c\x50\x69\x26\xa4\xef\x7b"
  3257. "\x7c\xc6\x91\xeb\x72\xdd\x9b\xee",
  3258. .ilen = 16,
  3259. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3260. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3261. .rlen = 16,
  3262. }, {
  3263. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  3264. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  3265. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  3266. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  3267. .klen = 32,
  3268. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3269. "\x00\x00\x00\x00\x00\x00\x00\x02",
  3270. .input = "\xab\x72\x0a\xad\x3b\x0c\xf0\xc9"
  3271. "\x42\x2f\xf1\xae\xf1\x3c\xb1\xbd",
  3272. .ilen = 16,
  3273. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3274. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3275. .rlen = 16,
  3276. }, {
  3277. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  3278. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  3279. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  3280. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  3281. .klen = 32,
  3282. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3283. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3284. .input = "\x85\xa7\x56\x67\x08\xfa\x42\xe1"
  3285. "\x22\xe6\x82\xfc\xd9\xb4\xd7\xd4",
  3286. .ilen = 16,
  3287. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3288. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3289. .rlen = 16,
  3290. }, {
  3291. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  3292. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  3293. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  3294. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  3295. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  3296. .klen = 40,
  3297. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3298. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3299. .input = "\xd2\xaf\x69\x35\x24\x1d\x0e\x1c"
  3300. "\x84\x8b\x05\xe4\xa2\x2f\x16\xf5",
  3301. .ilen = 16,
  3302. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3303. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3304. .rlen = 16,
  3305. }, {
  3306. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  3307. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  3308. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  3309. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  3310. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  3311. .klen = 40,
  3312. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3313. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3314. .input = "\x4a\x23\x56\xd7\xff\x90\xd0\x9a"
  3315. "\x0d\x7c\x26\xfc\xf0\xf0\xf6\xe4",
  3316. .ilen = 16,
  3317. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3318. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3319. .rlen = 16,
  3320. }, {
  3321. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  3322. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  3323. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  3324. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  3325. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  3326. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  3327. .klen = 48,
  3328. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3329. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3330. .input = "\x30\xaf\x26\x05\x9d\x5d\x0a\x58"
  3331. "\xe2\xe7\xce\x8a\xb2\x56\x6d\x76",
  3332. .ilen = 16,
  3333. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3334. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3335. .rlen = 16,
  3336. }, {
  3337. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  3338. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  3339. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  3340. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  3341. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  3342. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  3343. .klen = 48,
  3344. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3345. "\x00\x00\x00\x02\x00\x00\x00\x00",
  3346. .input = "\xdf\xcf\xdc\xd2\xe1\xcf\x86\x75"
  3347. "\x17\x66\x5e\x0c\x14\xa1\x3d\x40",
  3348. .ilen = 16,
  3349. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  3350. "\x38\x39\x41\x42\x43\x44\x45\x46",
  3351. .rlen = 16,
  3352. }, {
  3353. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  3354. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  3355. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  3356. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  3357. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  3358. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  3359. .klen = 48,
  3360. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3361. "\x00\x00\x00\x00\x00\x00\x00\x01",
  3362. .input = "\x30\x38\xeb\xaf\x12\x43\x1a\x89"
  3363. "\x62\xa2\x36\xe5\xcf\x77\x1e\xd9"
  3364. "\x08\xc3\x0d\xdd\x95\xab\x19\x96"
  3365. "\x27\x52\x41\xc3\xca\xfb\xf6\xee"
  3366. "\x40\x2d\xdf\xdd\x00\x0c\xb9\x0a"
  3367. "\x3a\xf0\xc0\xd1\xda\x63\x9e\x45"
  3368. "\x42\xe9\x29\xc0\xb4\x07\xb4\x31"
  3369. "\x66\x77\x72\xb5\xb6\xb3\x57\x46"
  3370. "\x34\x9a\xfe\x03\xaf\x6b\x36\x07"
  3371. "\x63\x8e\xc2\x5d\xa6\x0f\xb6\x7d"
  3372. "\xfb\x6d\x82\x51\xb6\x98\xd0\x71"
  3373. "\xe7\x10\x7a\xdf\xb2\xbd\xf1\x1d"
  3374. "\x72\x2b\x54\x13\xe3\x6d\x79\x37"
  3375. "\xa9\x39\x2c\xdf\x21\xab\x87\xd5"
  3376. "\xee\xef\x9a\x12\x50\x39\x2e\x1b"
  3377. "\x7d\xe6\x6a\x27\x48\xb9\xe7\xac"
  3378. "\xaa\xcd\x79\x5f\xf2\xf3\xa0\x08"
  3379. "\x6f\x2c\xf4\x0e\xd1\xb8\x89\x25"
  3380. "\x31\x9d\xef\xb1\x1d\x27\x55\x04"
  3381. "\xc9\x8c\xb7\x68\xdc\xb6\x67\x8a"
  3382. "\xdb\xcf\x22\xf2\x3b\x6f\xce\xbb"
  3383. "\x26\xbe\x4f\x27\x04\x42\xd1\x44"
  3384. "\x4c\x08\xa3\x95\x4c\x7f\x1a\xaf"
  3385. "\x1d\x28\x14\xfd\xb1\x1a\x34\x18"
  3386. "\xf5\x1e\x28\x69\x95\x6a\x5a\xba"
  3387. "\x8e\xb2\x58\x1d\x28\x17\x13\x3d"
  3388. "\x38\x7d\x14\x8d\xab\x5d\xf9\xe8"
  3389. "\x3c\x0f\x2b\x0d\x2b\x08\xb4\x4b"
  3390. "\x6b\x0d\xc8\xa7\x84\xc2\x3a\x1a"
  3391. "\xb7\xbd\xda\x92\x29\xb8\x5b\x5a"
  3392. "\x63\xa5\x99\x82\x09\x72\x8f\xc6"
  3393. "\xa4\x62\x24\x69\x8c\x2d\x26\x00"
  3394. "\x99\x83\x91\xd6\xc6\xcf\x57\x67"
  3395. "\x38\xea\xf2\xfc\x29\xe0\x73\x39"
  3396. "\xf9\x13\x94\x6d\xe2\x58\x28\x75"
  3397. "\x3e\xae\x71\x90\x07\x70\x1c\x38"
  3398. "\x5b\x4c\x1e\xb5\xa5\x3b\x20\xef"
  3399. "\xb1\x4c\x3e\x1a\x72\x62\xbb\x22"
  3400. "\x82\x09\xe3\x18\x3f\x4f\x48\xfc"
  3401. "\xdd\xac\xfc\xb6\x09\xdb\xd2\x7b"
  3402. "\xd6\xb7\x7e\x41\x2f\x14\xf5\x0e"
  3403. "\xc3\xac\x4a\xed\xe7\x82\xef\x31"
  3404. "\x1f\x1a\x51\x1e\x29\x60\xc8\x98"
  3405. "\x93\x51\x1d\x3d\x62\x59\x83\x82"
  3406. "\x0c\xf1\xd7\x8d\xac\x33\x44\x81"
  3407. "\x3c\x59\xb7\xd4\x5b\x65\x82\xc4"
  3408. "\xec\xdc\x24\xfd\x0e\x1a\x79\x94"
  3409. "\x34\xb0\x62\xfa\x98\x49\x26\x1f"
  3410. "\xf4\x9e\x40\x44\x5b\x1f\xf8\xbe"
  3411. "\x36\xff\xc6\xc6\x9d\xf2\xd6\xcc"
  3412. "\x63\x93\x29\xb9\x0b\x6d\xd7\x6c"
  3413. "\xdb\xf6\x21\x80\xf7\x5a\x37\x15"
  3414. "\x0c\xe3\x36\xc8\x74\x75\x20\x91"
  3415. "\xdf\x52\x2d\x0c\xe7\x45\xff\x46"
  3416. "\xb3\xf4\xec\xc2\xbd\xd3\x37\xb6"
  3417. "\x26\xa2\x5d\x7d\x61\xbf\x10\x46"
  3418. "\x57\x8d\x05\x96\x70\x0b\xd6\x41"
  3419. "\x5c\xe9\xd3\x54\x81\x39\x3a\xdd"
  3420. "\x5f\x92\x81\x6e\x35\x03\xd4\x72"
  3421. "\x3d\x5a\xe7\xb9\x3b\x0c\x84\x23"
  3422. "\x45\x5d\xec\x72\xc1\x52\xef\x2e"
  3423. "\x81\x00\xd3\xfe\x4c\x3c\x05\x61"
  3424. "\x80\x18\xc4\x6c\x03\xd3\xb7\xba"
  3425. "\x11\xd7\xb8\x6e\xea\xe1\x80\x30",
  3426. .ilen = 512,
  3427. .result = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  3428. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  3429. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  3430. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  3431. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  3432. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  3433. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  3434. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  3435. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  3436. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  3437. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  3438. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  3439. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  3440. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  3441. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  3442. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  3443. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  3444. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  3445. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  3446. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  3447. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  3448. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  3449. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  3450. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  3451. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  3452. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  3453. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  3454. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  3455. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  3456. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  3457. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  3458. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  3459. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  3460. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  3461. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  3462. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  3463. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  3464. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  3465. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  3466. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  3467. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  3468. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  3469. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  3470. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  3471. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  3472. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  3473. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  3474. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  3475. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  3476. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  3477. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  3478. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  3479. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  3480. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  3481. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  3482. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  3483. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  3484. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  3485. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  3486. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  3487. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  3488. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  3489. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  3490. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  3491. .rlen = 512,
  3492. },
  3493. };
  3494. static struct cipher_testvec tf_xts_enc_tv_template[] = {
  3495. /* Generated from AES-XTS test vectors */
  3496. {
  3497. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3498. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3499. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3500. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3501. .klen = 32,
  3502. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3503. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3504. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3505. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3506. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3507. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3508. .ilen = 32,
  3509. .result = "\x4b\xc9\x44\x4a\x11\xa3\xef\xac"
  3510. "\x30\x74\xe4\x44\x52\x77\x97\x43"
  3511. "\xa7\x60\xb2\x45\x2e\xf9\x00\x90"
  3512. "\x9f\xaa\xfd\x89\x6e\x9d\x4a\xe0",
  3513. .rlen = 32,
  3514. }, {
  3515. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  3516. "\x11\x11\x11\x11\x11\x11\x11\x11"
  3517. "\x22\x22\x22\x22\x22\x22\x22\x22"
  3518. "\x22\x22\x22\x22\x22\x22\x22\x22",
  3519. .klen = 32,
  3520. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  3521. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3522. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  3523. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3524. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3525. "\x44\x44\x44\x44\x44\x44\x44\x44",
  3526. .ilen = 32,
  3527. .result = "\x57\x0e\x8f\xe5\x2a\x35\x61\x4f"
  3528. "\x32\xd3\xbd\x36\x05\x15\x44\x2c"
  3529. "\x58\x06\xf7\xf8\x00\xa8\xb6\xd5"
  3530. "\xc6\x28\x92\xdb\xd8\x34\xa2\xe9",
  3531. .rlen = 32,
  3532. }, {
  3533. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  3534. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  3535. "\x22\x22\x22\x22\x22\x22\x22\x22"
  3536. "\x22\x22\x22\x22\x22\x22\x22\x22",
  3537. .klen = 32,
  3538. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  3539. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3540. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  3541. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3542. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3543. "\x44\x44\x44\x44\x44\x44\x44\x44",
  3544. .ilen = 32,
  3545. .result = "\x96\x45\x8f\x8d\x7a\x75\xb1\xde"
  3546. "\x40\x0c\x89\x56\xf6\x4d\xa7\x07"
  3547. "\x38\xbb\x5b\xe9\xcd\x84\xae\xb2"
  3548. "\x7b\x6a\x62\xf4\x8c\xb5\x37\xea",
  3549. .rlen = 32,
  3550. }, {
  3551. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  3552. "\x23\x53\x60\x28\x74\x71\x35\x26"
  3553. "\x31\x41\x59\x26\x53\x58\x97\x93"
  3554. "\x23\x84\x62\x64\x33\x83\x27\x95",
  3555. .klen = 32,
  3556. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3557. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3558. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  3559. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3560. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3561. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3562. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3563. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  3564. "\x30\x31\x32\x33\x34\x35\x36\x37"
  3565. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  3566. "\x40\x41\x42\x43\x44\x45\x46\x47"
  3567. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  3568. "\x50\x51\x52\x53\x54\x55\x56\x57"
  3569. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  3570. "\x60\x61\x62\x63\x64\x65\x66\x67"
  3571. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  3572. "\x70\x71\x72\x73\x74\x75\x76\x77"
  3573. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  3574. "\x80\x81\x82\x83\x84\x85\x86\x87"
  3575. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  3576. "\x90\x91\x92\x93\x94\x95\x96\x97"
  3577. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  3578. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  3579. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  3580. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  3581. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  3582. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  3583. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  3584. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  3585. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  3586. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  3587. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  3588. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  3589. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  3590. "\x00\x01\x02\x03\x04\x05\x06\x07"
  3591. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3592. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3593. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3594. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3595. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  3596. "\x30\x31\x32\x33\x34\x35\x36\x37"
  3597. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  3598. "\x40\x41\x42\x43\x44\x45\x46\x47"
  3599. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  3600. "\x50\x51\x52\x53\x54\x55\x56\x57"
  3601. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  3602. "\x60\x61\x62\x63\x64\x65\x66\x67"
  3603. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  3604. "\x70\x71\x72\x73\x74\x75\x76\x77"
  3605. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  3606. "\x80\x81\x82\x83\x84\x85\x86\x87"
  3607. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  3608. "\x90\x91\x92\x93\x94\x95\x96\x97"
  3609. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  3610. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  3611. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  3612. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  3613. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  3614. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  3615. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  3616. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  3617. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  3618. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  3619. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  3620. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  3621. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  3622. .ilen = 512,
  3623. .result = "\xa9\x78\xae\x1e\xea\xa2\x44\x4c"
  3624. "\xa2\x7a\x64\x1f\xaf\x46\xc1\xe0"
  3625. "\x6c\xb2\xf3\x92\x9a\xd6\x7d\x58"
  3626. "\xb8\x2d\xb9\x5d\x58\x07\x66\x50"
  3627. "\xea\x35\x35\x8c\xb2\x46\x61\x06"
  3628. "\x5d\x65\xfc\x57\x8f\x69\x74\xab"
  3629. "\x8a\x06\x69\xb5\x6c\xda\x66\xc7"
  3630. "\x52\x90\xbb\x8e\x6d\x8b\xb5\xa2"
  3631. "\x78\x1d\xc2\xa9\xc2\x73\x00\xc3"
  3632. "\x32\x36\x7c\x97\x6b\x4e\x8a\x50"
  3633. "\xe4\x91\x83\x96\x8f\xf4\x94\x1a"
  3634. "\xa6\x27\xe1\x33\xcb\x91\xc6\x5f"
  3635. "\x94\x75\xbc\xd7\x3e\x3e\x6f\x9e"
  3636. "\xa9\x31\x80\x5e\xe5\xdb\xc8\x53"
  3637. "\x01\x73\x68\x32\x25\x19\xfa\xfb"
  3638. "\xe4\xcf\xb9\x3e\xa2\xa0\x8f\x31"
  3639. "\xbf\x54\x06\x93\xa8\xb1\x0f\xb6"
  3640. "\x7c\x3c\xde\x6f\x0f\xfb\x0c\x11"
  3641. "\x39\x80\x39\x09\x97\x65\xf2\x83"
  3642. "\xae\xe6\xa1\x6f\x47\xb8\x49\xde"
  3643. "\x99\x36\x20\x7d\x97\x3b\xec\xfa"
  3644. "\xb4\x33\x6e\x7a\xc7\x46\x84\x49"
  3645. "\x91\xcd\xe1\x57\x0d\xed\x40\x08"
  3646. "\x13\xf1\x4e\x3e\xa4\xa4\x5c\xe6"
  3647. "\xd2\x0c\x20\x8f\x3e\xdf\x3f\x47"
  3648. "\x9a\x2f\xde\x6d\x66\xc9\x99\x4a"
  3649. "\x2d\x9e\x9d\x4b\x1a\x27\xa2\x12"
  3650. "\x99\xf0\xf8\xb1\xb6\xf6\x57\xc3"
  3651. "\xca\x1c\xa3\x8e\xed\x39\x28\xb5"
  3652. "\x10\x1b\x4b\x08\x42\x00\x4a\xd3"
  3653. "\xad\x5a\xc6\x8e\xc8\xbb\x95\xc4"
  3654. "\x4b\xaa\xfe\xd5\x42\xa8\xa3\x6d"
  3655. "\x3c\xf3\x34\x91\x2d\xb4\xdd\x20"
  3656. "\x0c\x90\x6d\xa3\x9b\x66\x9d\x24"
  3657. "\x02\xa6\xa9\x3f\x3f\x58\x5d\x47"
  3658. "\x24\x65\x63\x7e\xbd\x8c\xe6\x52"
  3659. "\x7d\xef\x33\x53\x63\xec\xaa\x0b"
  3660. "\x64\x15\xa9\xa6\x1f\x10\x00\x38"
  3661. "\x35\xa8\xe7\xbe\x23\x70\x22\xe0"
  3662. "\xd3\xb9\xe6\xfd\xe6\xaa\x03\x50"
  3663. "\xf3\x3c\x27\x36\x8b\xcc\xfe\x9c"
  3664. "\x9c\xa3\xb3\xe7\x68\x9b\xa2\x71"
  3665. "\xe0\x07\xd9\x1f\x68\x1f\xac\x5e"
  3666. "\x7a\x74\x85\xa9\x6a\x90\xab\x2c"
  3667. "\x38\x51\xbc\x1f\x43\x4a\x56\x1c"
  3668. "\xf8\x47\x03\x4e\x67\xa8\x1f\x99"
  3669. "\x04\x39\x73\x32\xb2\x86\x79\xe7"
  3670. "\x14\x28\x70\xb8\xe2\x7d\x69\x85"
  3671. "\xb6\x0f\xc5\xd0\xd0\x01\x5c\xe6"
  3672. "\x09\x0f\x75\xf7\xb6\x81\xd2\x11"
  3673. "\x20\x9c\xa1\xee\x11\x44\x79\xd0"
  3674. "\xb2\x34\x77\xda\x10\x9a\x6f\x6f"
  3675. "\xef\x7c\xd9\xdc\x35\xb7\x61\xdd"
  3676. "\xf1\xa4\xc6\x1c\xbf\x05\x22\xac"
  3677. "\xfe\x2f\x85\x00\x44\xdf\x33\x16"
  3678. "\x35\xb6\xa3\xd3\x70\xdf\x69\x35"
  3679. "\x6a\xc7\xb4\x99\x45\x27\xc8\x8e"
  3680. "\x5a\x14\x30\xd0\x55\x3e\x4f\x64"
  3681. "\x0d\x38\xe3\xdf\x8b\xa8\x93\x26"
  3682. "\x75\xae\xf6\xb5\x23\x0b\x17\x31"
  3683. "\xbf\x27\xb8\xb5\x94\x31\xa7\x8f"
  3684. "\x43\xc4\x46\x24\x22\x4f\x8f\x7e"
  3685. "\xe5\xf4\x6d\x1e\x0e\x18\x7a\xbb"
  3686. "\xa6\x8f\xfb\x49\x49\xd8\x7e\x5a",
  3687. .rlen = 512,
  3688. }, {
  3689. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  3690. "\x23\x53\x60\x28\x74\x71\x35\x26"
  3691. "\x62\x49\x77\x57\x24\x70\x93\x69"
  3692. "\x99\x59\x57\x49\x66\x96\x76\x27"
  3693. "\x31\x41\x59\x26\x53\x58\x97\x93"
  3694. "\x23\x84\x62\x64\x33\x83\x27\x95"
  3695. "\x02\x88\x41\x97\x16\x93\x99\x37"
  3696. "\x51\x05\x82\x09\x74\x94\x45\x92",
  3697. .klen = 64,
  3698. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  3699. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3700. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  3701. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3702. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3703. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3704. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3705. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  3706. "\x30\x31\x32\x33\x34\x35\x36\x37"
  3707. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  3708. "\x40\x41\x42\x43\x44\x45\x46\x47"
  3709. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  3710. "\x50\x51\x52\x53\x54\x55\x56\x57"
  3711. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  3712. "\x60\x61\x62\x63\x64\x65\x66\x67"
  3713. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  3714. "\x70\x71\x72\x73\x74\x75\x76\x77"
  3715. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  3716. "\x80\x81\x82\x83\x84\x85\x86\x87"
  3717. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  3718. "\x90\x91\x92\x93\x94\x95\x96\x97"
  3719. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  3720. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  3721. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  3722. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  3723. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  3724. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  3725. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  3726. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  3727. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  3728. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  3729. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  3730. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  3731. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  3732. "\x00\x01\x02\x03\x04\x05\x06\x07"
  3733. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3734. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3735. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3736. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3737. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  3738. "\x30\x31\x32\x33\x34\x35\x36\x37"
  3739. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  3740. "\x40\x41\x42\x43\x44\x45\x46\x47"
  3741. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  3742. "\x50\x51\x52\x53\x54\x55\x56\x57"
  3743. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  3744. "\x60\x61\x62\x63\x64\x65\x66\x67"
  3745. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  3746. "\x70\x71\x72\x73\x74\x75\x76\x77"
  3747. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  3748. "\x80\x81\x82\x83\x84\x85\x86\x87"
  3749. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  3750. "\x90\x91\x92\x93\x94\x95\x96\x97"
  3751. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  3752. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  3753. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  3754. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  3755. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  3756. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  3757. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  3758. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  3759. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  3760. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  3761. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  3762. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  3763. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  3764. .ilen = 512,
  3765. .result = "\xd7\x4b\x93\x7d\x13\xa2\xa2\xe1"
  3766. "\x35\x39\x71\x88\x76\x1e\xc9\xea"
  3767. "\x86\xad\xf3\x14\x48\x3d\x5e\xe9"
  3768. "\xe9\x2d\xb2\x56\x59\x35\x9d\xec"
  3769. "\x84\xfa\x7e\x9d\x6d\x33\x36\x8f"
  3770. "\xce\xf4\xa9\x21\x0b\x5f\x96\xec"
  3771. "\xcb\xf9\x57\x68\x33\x88\x39\xbf"
  3772. "\x2f\xbb\x59\x03\xbd\x66\x8b\x11"
  3773. "\x11\x65\x51\x2e\xb8\x67\x05\xd1"
  3774. "\x27\x11\x5c\xd4\xcc\x97\xc2\xb3"
  3775. "\xa9\x55\xaf\x07\x56\xd1\xdc\xf5"
  3776. "\x85\xdc\x46\xe6\xf0\x24\xeb\x93"
  3777. "\x4d\xf0\x9b\xf5\x73\x1c\xda\x03"
  3778. "\x22\xc8\x3a\x4f\xb4\x19\x91\x09"
  3779. "\x54\x0b\xf6\xfe\x17\x3d\x1a\x53"
  3780. "\x72\x60\x79\xcb\x0e\x32\x8a\x77"
  3781. "\xd5\xed\xdb\x33\xd7\x62\x16\x69"
  3782. "\x63\xe0\xab\xb5\xf6\x9c\x5f\x3d"
  3783. "\x69\x35\x61\x86\xf8\x86\xb9\x89"
  3784. "\x6e\x59\x35\xac\xf6\x6b\x33\xa0"
  3785. "\xea\xef\x96\x62\xd8\xa9\xcf\x56"
  3786. "\xbf\xdb\x8a\xfd\xa1\x82\x77\x73"
  3787. "\x3d\x94\x4a\x49\x42\x6d\x08\x60"
  3788. "\xa1\xea\xab\xb6\x88\x13\x94\xb8"
  3789. "\x51\x98\xdb\x35\x85\xdf\xf6\xb9"
  3790. "\x8f\xcd\xdf\x80\xd3\x40\x2d\x72"
  3791. "\xb8\xb2\x6c\x02\x43\x35\x22\x2a"
  3792. "\x31\xed\xcd\x16\x19\xdf\x62\x0f"
  3793. "\x29\xcf\x87\x04\xec\x02\x4f\xe4"
  3794. "\xa2\xed\x73\xc6\x69\xd3\x7e\x89"
  3795. "\x0b\x76\x10\x7c\xd6\xf9\x6a\x25"
  3796. "\xed\xcc\x60\x5d\x61\x20\xc1\x97"
  3797. "\x56\x91\x57\x28\xbe\x71\x0d\xcd"
  3798. "\xde\xc4\x9e\x55\x91\xbe\xd1\x28"
  3799. "\x9b\x90\xeb\x73\xf3\x68\x51\xc6"
  3800. "\xdf\x82\xcc\xd8\x1f\xce\x5b\x27"
  3801. "\xc0\x60\x5e\x33\xd6\xa7\x20\xea"
  3802. "\xb2\x54\xc7\x5d\x6a\x3b\x67\x47"
  3803. "\xcf\xa0\xe3\xab\x86\xaf\xc1\x42"
  3804. "\xe6\xb0\x23\x4a\xaf\x53\xdf\xa0"
  3805. "\xad\x12\x32\x31\x03\xf7\x21\xbe"
  3806. "\x2d\xd5\x82\x42\xb6\x4a\x3d\xcd"
  3807. "\xd8\x81\x77\xa9\x49\x98\x6c\x09"
  3808. "\xc5\xa3\x61\x12\x62\x85\x6b\xcd"
  3809. "\xb3\xf4\x20\x0c\x41\xc4\x05\x37"
  3810. "\x46\x5f\xeb\x71\x8b\xf1\xaf\x6e"
  3811. "\xba\xf3\x50\x2e\xfe\xa8\x37\xeb"
  3812. "\xe8\x8c\x4f\xa4\x0c\xf1\x31\xc8"
  3813. "\x6e\x71\x4f\xa5\xd7\x97\x73\xe0"
  3814. "\x93\x4a\x2f\xda\x7b\xe0\x20\x54"
  3815. "\x1f\x8d\x85\x79\x0b\x7b\x5e\x75"
  3816. "\xb9\x07\x67\xcc\xc8\xe7\x21\x15"
  3817. "\xa7\xc8\x98\xff\x4b\x80\x1c\x12"
  3818. "\xa8\x54\xe1\x38\x52\xe6\x74\x81"
  3819. "\x97\x47\xa1\x41\x0e\xc0\x50\xe3"
  3820. "\x55\x0e\xc3\xa7\x70\x77\xce\x07"
  3821. "\xed\x8c\x88\xe6\xa1\x5b\x14\xec"
  3822. "\xe6\xde\x06\x6d\x74\xc5\xd9\xfa"
  3823. "\xe5\x2f\x5a\xff\xc8\x05\xee\x27"
  3824. "\x35\x61\xbf\x0b\x19\x78\x9b\xd2"
  3825. "\x04\xc7\x05\xb1\x79\xb4\xff\x5f"
  3826. "\xf3\xea\x67\x52\x78\xc2\xce\x70"
  3827. "\xa4\x05\x0b\xb2\xb3\xa8\x30\x97"
  3828. "\x37\x30\xe1\x91\x8d\xb3\x2a\xff",
  3829. .rlen = 512,
  3830. },
  3831. };
  3832. static struct cipher_testvec tf_xts_dec_tv_template[] = {
  3833. /* Generated from AES-XTS test vectors */
  3834. /* same as enc vectors with input and result reversed */
  3835. {
  3836. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3837. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3838. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3839. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3840. .klen = 32,
  3841. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3842. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3843. .input = "\x4b\xc9\x44\x4a\x11\xa3\xef\xac"
  3844. "\x30\x74\xe4\x44\x52\x77\x97\x43"
  3845. "\xa7\x60\xb2\x45\x2e\xf9\x00\x90"
  3846. "\x9f\xaa\xfd\x89\x6e\x9d\x4a\xe0",
  3847. .ilen = 32,
  3848. .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3849. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3850. "\x00\x00\x00\x00\x00\x00\x00\x00"
  3851. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3852. .rlen = 32,
  3853. }, {
  3854. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  3855. "\x11\x11\x11\x11\x11\x11\x11\x11"
  3856. "\x22\x22\x22\x22\x22\x22\x22\x22"
  3857. "\x22\x22\x22\x22\x22\x22\x22\x22",
  3858. .klen = 32,
  3859. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  3860. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3861. .input = "\x57\x0e\x8f\xe5\x2a\x35\x61\x4f"
  3862. "\x32\xd3\xbd\x36\x05\x15\x44\x2c"
  3863. "\x58\x06\xf7\xf8\x00\xa8\xb6\xd5"
  3864. "\xc6\x28\x92\xdb\xd8\x34\xa2\xe9",
  3865. .ilen = 32,
  3866. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  3867. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3868. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3869. "\x44\x44\x44\x44\x44\x44\x44\x44",
  3870. .rlen = 32,
  3871. }, {
  3872. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  3873. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  3874. "\x22\x22\x22\x22\x22\x22\x22\x22"
  3875. "\x22\x22\x22\x22\x22\x22\x22\x22",
  3876. .klen = 32,
  3877. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  3878. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3879. .input = "\x96\x45\x8f\x8d\x7a\x75\xb1\xde"
  3880. "\x40\x0c\x89\x56\xf6\x4d\xa7\x07"
  3881. "\x38\xbb\x5b\xe9\xcd\x84\xae\xb2"
  3882. "\x7b\x6a\x62\xf4\x8c\xb5\x37\xea",
  3883. .ilen = 32,
  3884. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  3885. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3886. "\x44\x44\x44\x44\x44\x44\x44\x44"
  3887. "\x44\x44\x44\x44\x44\x44\x44\x44",
  3888. .rlen = 32,
  3889. }, {
  3890. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  3891. "\x23\x53\x60\x28\x74\x71\x35\x26"
  3892. "\x31\x41\x59\x26\x53\x58\x97\x93"
  3893. "\x23\x84\x62\x64\x33\x83\x27\x95",
  3894. .klen = 32,
  3895. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  3896. "\x00\x00\x00\x00\x00\x00\x00\x00",
  3897. .input = "\xa9\x78\xae\x1e\xea\xa2\x44\x4c"
  3898. "\xa2\x7a\x64\x1f\xaf\x46\xc1\xe0"
  3899. "\x6c\xb2\xf3\x92\x9a\xd6\x7d\x58"
  3900. "\xb8\x2d\xb9\x5d\x58\x07\x66\x50"
  3901. "\xea\x35\x35\x8c\xb2\x46\x61\x06"
  3902. "\x5d\x65\xfc\x57\x8f\x69\x74\xab"
  3903. "\x8a\x06\x69\xb5\x6c\xda\x66\xc7"
  3904. "\x52\x90\xbb\x8e\x6d\x8b\xb5\xa2"
  3905. "\x78\x1d\xc2\xa9\xc2\x73\x00\xc3"
  3906. "\x32\x36\x7c\x97\x6b\x4e\x8a\x50"
  3907. "\xe4\x91\x83\x96\x8f\xf4\x94\x1a"
  3908. "\xa6\x27\xe1\x33\xcb\x91\xc6\x5f"
  3909. "\x94\x75\xbc\xd7\x3e\x3e\x6f\x9e"
  3910. "\xa9\x31\x80\x5e\xe5\xdb\xc8\x53"
  3911. "\x01\x73\x68\x32\x25\x19\xfa\xfb"
  3912. "\xe4\xcf\xb9\x3e\xa2\xa0\x8f\x31"
  3913. "\xbf\x54\x06\x93\xa8\xb1\x0f\xb6"
  3914. "\x7c\x3c\xde\x6f\x0f\xfb\x0c\x11"
  3915. "\x39\x80\x39\x09\x97\x65\xf2\x83"
  3916. "\xae\xe6\xa1\x6f\x47\xb8\x49\xde"
  3917. "\x99\x36\x20\x7d\x97\x3b\xec\xfa"
  3918. "\xb4\x33\x6e\x7a\xc7\x46\x84\x49"
  3919. "\x91\xcd\xe1\x57\x0d\xed\x40\x08"
  3920. "\x13\xf1\x4e\x3e\xa4\xa4\x5c\xe6"
  3921. "\xd2\x0c\x20\x8f\x3e\xdf\x3f\x47"
  3922. "\x9a\x2f\xde\x6d\x66\xc9\x99\x4a"
  3923. "\x2d\x9e\x9d\x4b\x1a\x27\xa2\x12"
  3924. "\x99\xf0\xf8\xb1\xb6\xf6\x57\xc3"
  3925. "\xca\x1c\xa3\x8e\xed\x39\x28\xb5"
  3926. "\x10\x1b\x4b\x08\x42\x00\x4a\xd3"
  3927. "\xad\x5a\xc6\x8e\xc8\xbb\x95\xc4"
  3928. "\x4b\xaa\xfe\xd5\x42\xa8\xa3\x6d"
  3929. "\x3c\xf3\x34\x91\x2d\xb4\xdd\x20"
  3930. "\x0c\x90\x6d\xa3\x9b\x66\x9d\x24"
  3931. "\x02\xa6\xa9\x3f\x3f\x58\x5d\x47"
  3932. "\x24\x65\x63\x7e\xbd\x8c\xe6\x52"
  3933. "\x7d\xef\x33\x53\x63\xec\xaa\x0b"
  3934. "\x64\x15\xa9\xa6\x1f\x10\x00\x38"
  3935. "\x35\xa8\xe7\xbe\x23\x70\x22\xe0"
  3936. "\xd3\xb9\xe6\xfd\xe6\xaa\x03\x50"
  3937. "\xf3\x3c\x27\x36\x8b\xcc\xfe\x9c"
  3938. "\x9c\xa3\xb3\xe7\x68\x9b\xa2\x71"
  3939. "\xe0\x07\xd9\x1f\x68\x1f\xac\x5e"
  3940. "\x7a\x74\x85\xa9\x6a\x90\xab\x2c"
  3941. "\x38\x51\xbc\x1f\x43\x4a\x56\x1c"
  3942. "\xf8\x47\x03\x4e\x67\xa8\x1f\x99"
  3943. "\x04\x39\x73\x32\xb2\x86\x79\xe7"
  3944. "\x14\x28\x70\xb8\xe2\x7d\x69\x85"
  3945. "\xb6\x0f\xc5\xd0\xd0\x01\x5c\xe6"
  3946. "\x09\x0f\x75\xf7\xb6\x81\xd2\x11"
  3947. "\x20\x9c\xa1\xee\x11\x44\x79\xd0"
  3948. "\xb2\x34\x77\xda\x10\x9a\x6f\x6f"
  3949. "\xef\x7c\xd9\xdc\x35\xb7\x61\xdd"
  3950. "\xf1\xa4\xc6\x1c\xbf\x05\x22\xac"
  3951. "\xfe\x2f\x85\x00\x44\xdf\x33\x16"
  3952. "\x35\xb6\xa3\xd3\x70\xdf\x69\x35"
  3953. "\x6a\xc7\xb4\x99\x45\x27\xc8\x8e"
  3954. "\x5a\x14\x30\xd0\x55\x3e\x4f\x64"
  3955. "\x0d\x38\xe3\xdf\x8b\xa8\x93\x26"
  3956. "\x75\xae\xf6\xb5\x23\x0b\x17\x31"
  3957. "\xbf\x27\xb8\xb5\x94\x31\xa7\x8f"
  3958. "\x43\xc4\x46\x24\x22\x4f\x8f\x7e"
  3959. "\xe5\xf4\x6d\x1e\x0e\x18\x7a\xbb"
  3960. "\xa6\x8f\xfb\x49\x49\xd8\x7e\x5a",
  3961. .ilen = 512,
  3962. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  3963. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3964. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3965. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3966. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3967. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  3968. "\x30\x31\x32\x33\x34\x35\x36\x37"
  3969. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  3970. "\x40\x41\x42\x43\x44\x45\x46\x47"
  3971. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  3972. "\x50\x51\x52\x53\x54\x55\x56\x57"
  3973. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  3974. "\x60\x61\x62\x63\x64\x65\x66\x67"
  3975. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  3976. "\x70\x71\x72\x73\x74\x75\x76\x77"
  3977. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  3978. "\x80\x81\x82\x83\x84\x85\x86\x87"
  3979. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  3980. "\x90\x91\x92\x93\x94\x95\x96\x97"
  3981. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  3982. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  3983. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  3984. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  3985. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  3986. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  3987. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  3988. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  3989. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  3990. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  3991. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  3992. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  3993. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  3994. "\x00\x01\x02\x03\x04\x05\x06\x07"
  3995. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  3996. "\x10\x11\x12\x13\x14\x15\x16\x17"
  3997. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  3998. "\x20\x21\x22\x23\x24\x25\x26\x27"
  3999. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  4000. "\x30\x31\x32\x33\x34\x35\x36\x37"
  4001. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  4002. "\x40\x41\x42\x43\x44\x45\x46\x47"
  4003. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  4004. "\x50\x51\x52\x53\x54\x55\x56\x57"
  4005. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  4006. "\x60\x61\x62\x63\x64\x65\x66\x67"
  4007. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  4008. "\x70\x71\x72\x73\x74\x75\x76\x77"
  4009. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  4010. "\x80\x81\x82\x83\x84\x85\x86\x87"
  4011. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  4012. "\x90\x91\x92\x93\x94\x95\x96\x97"
  4013. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  4014. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  4015. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  4016. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  4017. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  4018. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  4019. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  4020. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  4021. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  4022. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  4023. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  4024. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  4025. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  4026. .rlen = 512,
  4027. }, {
  4028. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  4029. "\x23\x53\x60\x28\x74\x71\x35\x26"
  4030. "\x62\x49\x77\x57\x24\x70\x93\x69"
  4031. "\x99\x59\x57\x49\x66\x96\x76\x27"
  4032. "\x31\x41\x59\x26\x53\x58\x97\x93"
  4033. "\x23\x84\x62\x64\x33\x83\x27\x95"
  4034. "\x02\x88\x41\x97\x16\x93\x99\x37"
  4035. "\x51\x05\x82\x09\x74\x94\x45\x92",
  4036. .klen = 64,
  4037. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  4038. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4039. .input = "\xd7\x4b\x93\x7d\x13\xa2\xa2\xe1"
  4040. "\x35\x39\x71\x88\x76\x1e\xc9\xea"
  4041. "\x86\xad\xf3\x14\x48\x3d\x5e\xe9"
  4042. "\xe9\x2d\xb2\x56\x59\x35\x9d\xec"
  4043. "\x84\xfa\x7e\x9d\x6d\x33\x36\x8f"
  4044. "\xce\xf4\xa9\x21\x0b\x5f\x96\xec"
  4045. "\xcb\xf9\x57\x68\x33\x88\x39\xbf"
  4046. "\x2f\xbb\x59\x03\xbd\x66\x8b\x11"
  4047. "\x11\x65\x51\x2e\xb8\x67\x05\xd1"
  4048. "\x27\x11\x5c\xd4\xcc\x97\xc2\xb3"
  4049. "\xa9\x55\xaf\x07\x56\xd1\xdc\xf5"
  4050. "\x85\xdc\x46\xe6\xf0\x24\xeb\x93"
  4051. "\x4d\xf0\x9b\xf5\x73\x1c\xda\x03"
  4052. "\x22\xc8\x3a\x4f\xb4\x19\x91\x09"
  4053. "\x54\x0b\xf6\xfe\x17\x3d\x1a\x53"
  4054. "\x72\x60\x79\xcb\x0e\x32\x8a\x77"
  4055. "\xd5\xed\xdb\x33\xd7\x62\x16\x69"
  4056. "\x63\xe0\xab\xb5\xf6\x9c\x5f\x3d"
  4057. "\x69\x35\x61\x86\xf8\x86\xb9\x89"
  4058. "\x6e\x59\x35\xac\xf6\x6b\x33\xa0"
  4059. "\xea\xef\x96\x62\xd8\xa9\xcf\x56"
  4060. "\xbf\xdb\x8a\xfd\xa1\x82\x77\x73"
  4061. "\x3d\x94\x4a\x49\x42\x6d\x08\x60"
  4062. "\xa1\xea\xab\xb6\x88\x13\x94\xb8"
  4063. "\x51\x98\xdb\x35\x85\xdf\xf6\xb9"
  4064. "\x8f\xcd\xdf\x80\xd3\x40\x2d\x72"
  4065. "\xb8\xb2\x6c\x02\x43\x35\x22\x2a"
  4066. "\x31\xed\xcd\x16\x19\xdf\x62\x0f"
  4067. "\x29\xcf\x87\x04\xec\x02\x4f\xe4"
  4068. "\xa2\xed\x73\xc6\x69\xd3\x7e\x89"
  4069. "\x0b\x76\x10\x7c\xd6\xf9\x6a\x25"
  4070. "\xed\xcc\x60\x5d\x61\x20\xc1\x97"
  4071. "\x56\x91\x57\x28\xbe\x71\x0d\xcd"
  4072. "\xde\xc4\x9e\x55\x91\xbe\xd1\x28"
  4073. "\x9b\x90\xeb\x73\xf3\x68\x51\xc6"
  4074. "\xdf\x82\xcc\xd8\x1f\xce\x5b\x27"
  4075. "\xc0\x60\x5e\x33\xd6\xa7\x20\xea"
  4076. "\xb2\x54\xc7\x5d\x6a\x3b\x67\x47"
  4077. "\xcf\xa0\xe3\xab\x86\xaf\xc1\x42"
  4078. "\xe6\xb0\x23\x4a\xaf\x53\xdf\xa0"
  4079. "\xad\x12\x32\x31\x03\xf7\x21\xbe"
  4080. "\x2d\xd5\x82\x42\xb6\x4a\x3d\xcd"
  4081. "\xd8\x81\x77\xa9\x49\x98\x6c\x09"
  4082. "\xc5\xa3\x61\x12\x62\x85\x6b\xcd"
  4083. "\xb3\xf4\x20\x0c\x41\xc4\x05\x37"
  4084. "\x46\x5f\xeb\x71\x8b\xf1\xaf\x6e"
  4085. "\xba\xf3\x50\x2e\xfe\xa8\x37\xeb"
  4086. "\xe8\x8c\x4f\xa4\x0c\xf1\x31\xc8"
  4087. "\x6e\x71\x4f\xa5\xd7\x97\x73\xe0"
  4088. "\x93\x4a\x2f\xda\x7b\xe0\x20\x54"
  4089. "\x1f\x8d\x85\x79\x0b\x7b\x5e\x75"
  4090. "\xb9\x07\x67\xcc\xc8\xe7\x21\x15"
  4091. "\xa7\xc8\x98\xff\x4b\x80\x1c\x12"
  4092. "\xa8\x54\xe1\x38\x52\xe6\x74\x81"
  4093. "\x97\x47\xa1\x41\x0e\xc0\x50\xe3"
  4094. "\x55\x0e\xc3\xa7\x70\x77\xce\x07"
  4095. "\xed\x8c\x88\xe6\xa1\x5b\x14\xec"
  4096. "\xe6\xde\x06\x6d\x74\xc5\xd9\xfa"
  4097. "\xe5\x2f\x5a\xff\xc8\x05\xee\x27"
  4098. "\x35\x61\xbf\x0b\x19\x78\x9b\xd2"
  4099. "\x04\xc7\x05\xb1\x79\xb4\xff\x5f"
  4100. "\xf3\xea\x67\x52\x78\xc2\xce\x70"
  4101. "\xa4\x05\x0b\xb2\xb3\xa8\x30\x97"
  4102. "\x37\x30\xe1\x91\x8d\xb3\x2a\xff",
  4103. .ilen = 512,
  4104. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4105. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  4106. "\x10\x11\x12\x13\x14\x15\x16\x17"
  4107. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  4108. "\x20\x21\x22\x23\x24\x25\x26\x27"
  4109. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  4110. "\x30\x31\x32\x33\x34\x35\x36\x37"
  4111. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  4112. "\x40\x41\x42\x43\x44\x45\x46\x47"
  4113. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  4114. "\x50\x51\x52\x53\x54\x55\x56\x57"
  4115. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  4116. "\x60\x61\x62\x63\x64\x65\x66\x67"
  4117. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  4118. "\x70\x71\x72\x73\x74\x75\x76\x77"
  4119. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  4120. "\x80\x81\x82\x83\x84\x85\x86\x87"
  4121. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  4122. "\x90\x91\x92\x93\x94\x95\x96\x97"
  4123. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  4124. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  4125. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  4126. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  4127. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  4128. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  4129. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  4130. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  4131. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  4132. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  4133. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  4134. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  4135. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  4136. "\x00\x01\x02\x03\x04\x05\x06\x07"
  4137. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  4138. "\x10\x11\x12\x13\x14\x15\x16\x17"
  4139. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  4140. "\x20\x21\x22\x23\x24\x25\x26\x27"
  4141. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  4142. "\x30\x31\x32\x33\x34\x35\x36\x37"
  4143. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  4144. "\x40\x41\x42\x43\x44\x45\x46\x47"
  4145. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  4146. "\x50\x51\x52\x53\x54\x55\x56\x57"
  4147. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  4148. "\x60\x61\x62\x63\x64\x65\x66\x67"
  4149. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  4150. "\x70\x71\x72\x73\x74\x75\x76\x77"
  4151. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  4152. "\x80\x81\x82\x83\x84\x85\x86\x87"
  4153. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  4154. "\x90\x91\x92\x93\x94\x95\x96\x97"
  4155. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  4156. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  4157. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  4158. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  4159. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  4160. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  4161. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  4162. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  4163. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  4164. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  4165. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  4166. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  4167. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  4168. .rlen = 512,
  4169. },
  4170. };
  4171. /*
  4172. * Serpent test vectors. These are backwards because Serpent writes
  4173. * octet sequences in right-to-left mode.
  4174. */
  4175. #define SERPENT_ENC_TEST_VECTORS 5
  4176. #define SERPENT_DEC_TEST_VECTORS 5
  4177. #define TNEPRES_ENC_TEST_VECTORS 4
  4178. #define TNEPRES_DEC_TEST_VECTORS 4
  4179. #define SERPENT_CBC_ENC_TEST_VECTORS 1
  4180. #define SERPENT_CBC_DEC_TEST_VECTORS 1
  4181. #define SERPENT_CTR_ENC_TEST_VECTORS 2
  4182. #define SERPENT_CTR_DEC_TEST_VECTORS 2
  4183. #define SERPENT_LRW_ENC_TEST_VECTORS 8
  4184. #define SERPENT_LRW_DEC_TEST_VECTORS 8
  4185. #define SERPENT_XTS_ENC_TEST_VECTORS 5
  4186. #define SERPENT_XTS_DEC_TEST_VECTORS 5
  4187. static struct cipher_testvec serpent_enc_tv_template[] = {
  4188. {
  4189. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4190. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4191. .ilen = 16,
  4192. .result = "\x12\x07\xfc\xce\x9b\xd0\xd6\x47"
  4193. "\x6a\xe9\x8f\xbe\xd1\x43\xa0\xe2",
  4194. .rlen = 16,
  4195. }, {
  4196. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4197. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4198. .klen = 16,
  4199. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4200. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4201. .ilen = 16,
  4202. .result = "\x4c\x7d\x8a\x32\x80\x72\xa2\x2c"
  4203. "\x82\x3e\x4a\x1f\x3a\xcd\xa1\x6d",
  4204. .rlen = 16,
  4205. }, {
  4206. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4207. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  4208. "\x10\x11\x12\x13\x14\x15\x16\x17"
  4209. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  4210. .klen = 32,
  4211. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4212. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4213. .ilen = 16,
  4214. .result = "\xde\x26\x9f\xf8\x33\xe4\x32\xb8"
  4215. "\x5b\x2e\x88\xd2\x70\x1c\xe7\x5c",
  4216. .rlen = 16,
  4217. }, {
  4218. .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
  4219. .klen = 16,
  4220. .input = zeroed_string,
  4221. .ilen = 16,
  4222. .result = "\xdd\xd2\x6b\x98\xa5\xff\xd8\x2c"
  4223. "\x05\x34\x5a\x9d\xad\xbf\xaf\x49",
  4224. .rlen = 16,
  4225. }, { /* Generated with Crypto++ */
  4226. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4227. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4228. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4229. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4230. .klen = 32,
  4231. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4232. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4233. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4234. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4235. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4236. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4237. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4238. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4239. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4240. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4241. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4242. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4243. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4244. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4245. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4246. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4247. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4248. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4249. .ilen = 144,
  4250. .result = "\xFB\xB0\x5D\xDE\xC0\xFE\xFC\xEB"
  4251. "\xB1\x80\x10\x43\xDE\x62\x70\xBD"
  4252. "\xFA\x8A\x93\xEA\x6B\xF7\xC5\xD7"
  4253. "\x0C\xD1\xBB\x29\x25\x14\x4C\x22"
  4254. "\x77\xA6\x38\x00\xDB\xB9\xE2\x07"
  4255. "\xD1\xAC\x82\xBA\xEA\x67\xAA\x39"
  4256. "\x99\x34\x89\x5B\x54\xE9\x12\x13"
  4257. "\x3B\x04\xE5\x12\x42\xC5\x79\xAB"
  4258. "\x0D\xC7\x3C\x58\x2D\xA3\x98\xF6"
  4259. "\xE4\x61\x9E\x17\x0B\xCE\xE8\xAA"
  4260. "\xB5\x6C\x1A\x3A\x67\x52\x81\x6A"
  4261. "\x04\xFF\x8A\x1B\x96\xFE\xE6\x87"
  4262. "\x3C\xD4\x39\x7D\x36\x9B\x03\xD5"
  4263. "\xB6\xA0\x75\x3C\x83\xE6\x1C\x73"
  4264. "\x9D\x74\x2B\x77\x53\x2D\xE5\xBD"
  4265. "\x69\xDA\x7A\x01\xF5\x6A\x70\x39"
  4266. "\x30\xD4\x2C\xF2\x8E\x06\x4B\x39"
  4267. "\xB3\x12\x1D\xB3\x17\x46\xE6\xD6",
  4268. .rlen = 144,
  4269. },
  4270. };
  4271. static struct cipher_testvec tnepres_enc_tv_template[] = {
  4272. { /* KeySize=128, PT=0, I=1 */
  4273. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4274. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4275. .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
  4276. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4277. .klen = 16,
  4278. .ilen = 16,
  4279. .result = "\x49\xaf\xbf\xad\x9d\x5a\x34\x05"
  4280. "\x2c\xd8\xff\xa5\x98\x6b\xd2\xdd",
  4281. .rlen = 16,
  4282. }, { /* KeySize=192, PT=0, I=1 */
  4283. .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
  4284. "\x00\x00\x00\x00\x00\x00\x00\x00"
  4285. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4286. .klen = 24,
  4287. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4288. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4289. .ilen = 16,
  4290. .result = "\xe7\x8e\x54\x02\xc7\x19\x55\x68"
  4291. "\xac\x36\x78\xf7\xa3\xf6\x0c\x66",
  4292. .rlen = 16,
  4293. }, { /* KeySize=256, PT=0, I=1 */
  4294. .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
  4295. "\x00\x00\x00\x00\x00\x00\x00\x00"
  4296. "\x00\x00\x00\x00\x00\x00\x00\x00"
  4297. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4298. .klen = 32,
  4299. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4300. "\x00\x00\x00\x00\x00\x00\x00\x00",
  4301. .ilen = 16,
  4302. .result = "\xab\xed\x96\xe7\x66\xbf\x28\xcb"
  4303. "\xc0\xeb\xd2\x1a\x82\xef\x08\x19",
  4304. .rlen = 16,
  4305. }, { /* KeySize=256, I=257 */
  4306. .key = "\x1f\x1e\x1d\x1c\x1b\x1a\x19\x18"
  4307. "\x17\x16\x15\x14\x13\x12\x11\x10"
  4308. "\x0f\x0e\x0d\x0c\x0b\x0a\x09\x08"
  4309. "\x07\x06\x05\x04\x03\x02\x01\x00",
  4310. .klen = 32,
  4311. .input = "\x0f\x0e\x0d\x0c\x0b\x0a\x09\x08"
  4312. "\x07\x06\x05\x04\x03\x02\x01\x00",
  4313. .ilen = 16,
  4314. .result = "\x5c\xe7\x1c\x70\xd2\x88\x2e\x5b"
  4315. "\xb8\x32\xe4\x33\xf8\x9f\x26\xde",
  4316. .rlen = 16,
  4317. },
  4318. };
  4319. static struct cipher_testvec serpent_dec_tv_template[] = {
  4320. {
  4321. .input = "\x12\x07\xfc\xce\x9b\xd0\xd6\x47"
  4322. "\x6a\xe9\x8f\xbe\xd1\x43\xa0\xe2",
  4323. .ilen = 16,
  4324. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4325. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4326. .rlen = 16,
  4327. }, {
  4328. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4329. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4330. .klen = 16,
  4331. .input = "\x4c\x7d\x8a\x32\x80\x72\xa2\x2c"
  4332. "\x82\x3e\x4a\x1f\x3a\xcd\xa1\x6d",
  4333. .ilen = 16,
  4334. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4335. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4336. .rlen = 16,
  4337. }, {
  4338. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4339. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  4340. "\x10\x11\x12\x13\x14\x15\x16\x17"
  4341. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  4342. .klen = 32,
  4343. .input = "\xde\x26\x9f\xf8\x33\xe4\x32\xb8"
  4344. "\x5b\x2e\x88\xd2\x70\x1c\xe7\x5c",
  4345. .ilen = 16,
  4346. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4347. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4348. .rlen = 16,
  4349. }, {
  4350. .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
  4351. .klen = 16,
  4352. .input = "\xdd\xd2\x6b\x98\xa5\xff\xd8\x2c"
  4353. "\x05\x34\x5a\x9d\xad\xbf\xaf\x49",
  4354. .ilen = 16,
  4355. .result = zeroed_string,
  4356. .rlen = 16,
  4357. }, { /* Generated with Crypto++ */
  4358. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4359. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4360. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4361. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4362. .klen = 32,
  4363. .input = "\xFB\xB0\x5D\xDE\xC0\xFE\xFC\xEB"
  4364. "\xB1\x80\x10\x43\xDE\x62\x70\xBD"
  4365. "\xFA\x8A\x93\xEA\x6B\xF7\xC5\xD7"
  4366. "\x0C\xD1\xBB\x29\x25\x14\x4C\x22"
  4367. "\x77\xA6\x38\x00\xDB\xB9\xE2\x07"
  4368. "\xD1\xAC\x82\xBA\xEA\x67\xAA\x39"
  4369. "\x99\x34\x89\x5B\x54\xE9\x12\x13"
  4370. "\x3B\x04\xE5\x12\x42\xC5\x79\xAB"
  4371. "\x0D\xC7\x3C\x58\x2D\xA3\x98\xF6"
  4372. "\xE4\x61\x9E\x17\x0B\xCE\xE8\xAA"
  4373. "\xB5\x6C\x1A\x3A\x67\x52\x81\x6A"
  4374. "\x04\xFF\x8A\x1B\x96\xFE\xE6\x87"
  4375. "\x3C\xD4\x39\x7D\x36\x9B\x03\xD5"
  4376. "\xB6\xA0\x75\x3C\x83\xE6\x1C\x73"
  4377. "\x9D\x74\x2B\x77\x53\x2D\xE5\xBD"
  4378. "\x69\xDA\x7A\x01\xF5\x6A\x70\x39"
  4379. "\x30\xD4\x2C\xF2\x8E\x06\x4B\x39"
  4380. "\xB3\x12\x1D\xB3\x17\x46\xE6\xD6",
  4381. .ilen = 144,
  4382. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4383. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4384. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4385. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4386. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4387. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4388. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4389. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4390. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4391. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4392. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4393. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4394. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4395. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4396. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4397. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4398. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4399. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4400. .rlen = 144,
  4401. },
  4402. };
  4403. static struct cipher_testvec tnepres_dec_tv_template[] = {
  4404. {
  4405. .input = "\x41\xcc\x6b\x31\x59\x31\x45\x97"
  4406. "\x6d\x6f\xbb\x38\x4b\x37\x21\x28",
  4407. .ilen = 16,
  4408. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4409. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4410. .rlen = 16,
  4411. }, {
  4412. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4413. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4414. .klen = 16,
  4415. .input = "\xea\xf4\xd7\xfc\xd8\x01\x34\x47"
  4416. "\x81\x45\x0b\xfa\x0c\xd6\xad\x6e",
  4417. .ilen = 16,
  4418. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4419. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4420. .rlen = 16,
  4421. }, {
  4422. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4423. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  4424. "\x10\x11\x12\x13\x14\x15\x16\x17"
  4425. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  4426. .klen = 32,
  4427. .input = "\x64\xa9\x1a\x37\xed\x9f\xe7\x49"
  4428. "\xa8\x4e\x76\xd6\xf5\x0d\x78\xee",
  4429. .ilen = 16,
  4430. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  4431. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  4432. .rlen = 16,
  4433. }, { /* KeySize=128, I=121 */
  4434. .key = "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x80",
  4435. .klen = 16,
  4436. .input = "\x3d\xda\xbf\xc0\x06\xda\xab\x06"
  4437. "\x46\x2a\xf4\xef\x81\x54\x4e\x26",
  4438. .ilen = 16,
  4439. .result = zeroed_string,
  4440. .rlen = 16,
  4441. },
  4442. };
  4443. static struct cipher_testvec serpent_cbc_enc_tv_template[] = {
  4444. { /* Generated with Crypto++ */
  4445. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4446. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4447. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4448. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4449. .klen = 32,
  4450. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4451. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4452. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4453. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4454. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4455. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4456. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4457. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4458. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4459. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4460. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4461. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4462. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4463. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4464. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4465. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4466. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4467. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4468. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4469. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4470. .ilen = 144,
  4471. .result = "\x80\xCF\x11\x41\x1A\xB9\x4B\x9C"
  4472. "\xFF\xB7\x6C\xEA\xF0\xAF\x77\x6E"
  4473. "\x71\x75\x95\x9D\x4E\x1C\xCF\xAD"
  4474. "\x81\x34\xE9\x8F\xAE\x5A\x91\x1C"
  4475. "\x38\x63\x35\x7E\x79\x18\x0A\xE8"
  4476. "\x67\x06\x76\xD5\xFF\x22\x2F\xDA"
  4477. "\xB6\x2D\x57\x13\xB6\x3C\xBC\x97"
  4478. "\xFE\x53\x75\x35\x97\x7F\x51\xEA"
  4479. "\xDF\x5D\xE8\x9D\xCC\xD9\xAE\xE7"
  4480. "\x62\x67\xFF\x04\xC2\x18\x22\x5F"
  4481. "\x2E\x06\xC1\xE2\x26\xCD\xC6\x1E"
  4482. "\xE5\x2C\x4E\x87\x23\xDD\xF0\x41"
  4483. "\x08\xA5\xB4\x3E\x07\x1E\x0B\xBB"
  4484. "\x72\x84\xF8\x0A\x3F\x38\x5E\x91"
  4485. "\x15\x26\xE1\xDB\xA4\x3D\x74\xD2"
  4486. "\x41\x1E\x3F\xA9\xC6\x7D\x2A\xAB"
  4487. "\x27\xDF\x89\x1D\x86\x3E\xF7\x5A"
  4488. "\xF6\xE3\x0F\xC7\x6B\x4C\x96\x7C",
  4489. .rlen = 144,
  4490. },
  4491. };
  4492. static struct cipher_testvec serpent_cbc_dec_tv_template[] = {
  4493. { /* Generated with Crypto++ */
  4494. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4495. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4496. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4497. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4498. .klen = 32,
  4499. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4500. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4501. .input = "\x80\xCF\x11\x41\x1A\xB9\x4B\x9C"
  4502. "\xFF\xB7\x6C\xEA\xF0\xAF\x77\x6E"
  4503. "\x71\x75\x95\x9D\x4E\x1C\xCF\xAD"
  4504. "\x81\x34\xE9\x8F\xAE\x5A\x91\x1C"
  4505. "\x38\x63\x35\x7E\x79\x18\x0A\xE8"
  4506. "\x67\x06\x76\xD5\xFF\x22\x2F\xDA"
  4507. "\xB6\x2D\x57\x13\xB6\x3C\xBC\x97"
  4508. "\xFE\x53\x75\x35\x97\x7F\x51\xEA"
  4509. "\xDF\x5D\xE8\x9D\xCC\xD9\xAE\xE7"
  4510. "\x62\x67\xFF\x04\xC2\x18\x22\x5F"
  4511. "\x2E\x06\xC1\xE2\x26\xCD\xC6\x1E"
  4512. "\xE5\x2C\x4E\x87\x23\xDD\xF0\x41"
  4513. "\x08\xA5\xB4\x3E\x07\x1E\x0B\xBB"
  4514. "\x72\x84\xF8\x0A\x3F\x38\x5E\x91"
  4515. "\x15\x26\xE1\xDB\xA4\x3D\x74\xD2"
  4516. "\x41\x1E\x3F\xA9\xC6\x7D\x2A\xAB"
  4517. "\x27\xDF\x89\x1D\x86\x3E\xF7\x5A"
  4518. "\xF6\xE3\x0F\xC7\x6B\x4C\x96\x7C",
  4519. .ilen = 144,
  4520. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4521. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4522. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4523. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4524. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4525. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4526. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4527. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4528. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4529. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4530. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4531. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4532. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4533. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4534. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4535. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4536. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4537. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4538. .rlen = 144,
  4539. },
  4540. };
  4541. static struct cipher_testvec serpent_ctr_enc_tv_template[] = {
  4542. { /* Generated with Crypto++ */
  4543. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4544. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4545. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4546. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4547. .klen = 32,
  4548. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4549. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4550. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4551. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4552. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4553. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4554. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4555. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4556. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4557. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4558. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4559. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4560. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4561. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4562. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4563. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4564. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4565. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4566. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4567. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4568. .ilen = 144,
  4569. .result = "\x84\x68\xEC\xF2\x1C\x88\x20\xCA"
  4570. "\x37\x69\xE3\x3A\x22\x85\x48\x46"
  4571. "\x70\xAA\x25\xB4\xCD\x8B\x04\x4E"
  4572. "\x8D\x15\x2B\x98\xDF\x7B\x6D\xB9"
  4573. "\xE0\x4A\x73\x00\x65\xB6\x1A\x0D"
  4574. "\x5C\x60\xDF\x34\xDC\x60\x4C\xDF"
  4575. "\xB5\x1F\x26\x8C\xDA\xC1\x11\xA8"
  4576. "\x80\xFA\x37\x7A\x89\xAA\xAE\x7B"
  4577. "\x92\x6E\xB9\xDC\xC9\x62\x4F\x88"
  4578. "\x0A\x5D\x97\x2F\x6B\xAC\x03\x7C"
  4579. "\x22\xF6\x55\x5A\xFA\x35\xA5\x17"
  4580. "\xA1\x5C\x5E\x2B\x63\x2D\xB9\x91"
  4581. "\x3E\x83\x26\x00\x4E\xD5\xBE\xCE"
  4582. "\x79\xC4\x3D\xFC\x70\xA0\xAD\x96"
  4583. "\xBA\x58\x2A\x1C\xDF\xC2\x3A\xA5"
  4584. "\x7C\xB5\x12\x89\xED\xBF\xB6\x09"
  4585. "\x13\x4F\x7D\x61\x3C\x5C\x27\xFC"
  4586. "\x5D\xE1\x4F\xA1\xEA\xB3\xCA\xB9",
  4587. .rlen = 144,
  4588. }, { /* Generated with Crypto++ */
  4589. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4590. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4591. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4592. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4593. .klen = 32,
  4594. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4595. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4596. .input = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4597. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4598. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4599. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4600. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4601. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4602. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4603. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4604. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4605. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4606. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4607. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4608. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4609. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4610. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4611. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4612. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4613. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A"
  4614. "\xF1\x65\xFC",
  4615. .ilen = 147,
  4616. .result = "\x84\x68\xEC\xF2\x1C\x88\x20\xCA"
  4617. "\x37\x69\xE3\x3A\x22\x85\x48\x46"
  4618. "\x70\xAA\x25\xB4\xCD\x8B\x04\x4E"
  4619. "\x8D\x15\x2B\x98\xDF\x7B\x6D\xB9"
  4620. "\xE0\x4A\x73\x00\x65\xB6\x1A\x0D"
  4621. "\x5C\x60\xDF\x34\xDC\x60\x4C\xDF"
  4622. "\xB5\x1F\x26\x8C\xDA\xC1\x11\xA8"
  4623. "\x80\xFA\x37\x7A\x89\xAA\xAE\x7B"
  4624. "\x92\x6E\xB9\xDC\xC9\x62\x4F\x88"
  4625. "\x0A\x5D\x97\x2F\x6B\xAC\x03\x7C"
  4626. "\x22\xF6\x55\x5A\xFA\x35\xA5\x17"
  4627. "\xA1\x5C\x5E\x2B\x63\x2D\xB9\x91"
  4628. "\x3E\x83\x26\x00\x4E\xD5\xBE\xCE"
  4629. "\x79\xC4\x3D\xFC\x70\xA0\xAD\x96"
  4630. "\xBA\x58\x2A\x1C\xDF\xC2\x3A\xA5"
  4631. "\x7C\xB5\x12\x89\xED\xBF\xB6\x09"
  4632. "\x13\x4F\x7D\x61\x3C\x5C\x27\xFC"
  4633. "\x5D\xE1\x4F\xA1\xEA\xB3\xCA\xB9"
  4634. "\xE6\xD0\x97",
  4635. .rlen = 147,
  4636. },
  4637. };
  4638. static struct cipher_testvec serpent_ctr_dec_tv_template[] = {
  4639. { /* Generated with Crypto++ */
  4640. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4641. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4642. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4643. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4644. .klen = 32,
  4645. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4646. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4647. .input = "\x84\x68\xEC\xF2\x1C\x88\x20\xCA"
  4648. "\x37\x69\xE3\x3A\x22\x85\x48\x46"
  4649. "\x70\xAA\x25\xB4\xCD\x8B\x04\x4E"
  4650. "\x8D\x15\x2B\x98\xDF\x7B\x6D\xB9"
  4651. "\xE0\x4A\x73\x00\x65\xB6\x1A\x0D"
  4652. "\x5C\x60\xDF\x34\xDC\x60\x4C\xDF"
  4653. "\xB5\x1F\x26\x8C\xDA\xC1\x11\xA8"
  4654. "\x80\xFA\x37\x7A\x89\xAA\xAE\x7B"
  4655. "\x92\x6E\xB9\xDC\xC9\x62\x4F\x88"
  4656. "\x0A\x5D\x97\x2F\x6B\xAC\x03\x7C"
  4657. "\x22\xF6\x55\x5A\xFA\x35\xA5\x17"
  4658. "\xA1\x5C\x5E\x2B\x63\x2D\xB9\x91"
  4659. "\x3E\x83\x26\x00\x4E\xD5\xBE\xCE"
  4660. "\x79\xC4\x3D\xFC\x70\xA0\xAD\x96"
  4661. "\xBA\x58\x2A\x1C\xDF\xC2\x3A\xA5"
  4662. "\x7C\xB5\x12\x89\xED\xBF\xB6\x09"
  4663. "\x13\x4F\x7D\x61\x3C\x5C\x27\xFC"
  4664. "\x5D\xE1\x4F\xA1\xEA\xB3\xCA\xB9",
  4665. .ilen = 144,
  4666. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4667. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4668. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4669. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4670. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4671. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4672. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4673. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4674. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4675. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4676. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4677. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4678. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4679. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4680. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4681. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4682. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4683. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A",
  4684. .rlen = 144,
  4685. }, { /* Generated with Crypto++ */
  4686. .key = "\x85\x62\x3F\x1C\xF9\xD6\x1C\xF9"
  4687. "\xD6\xB3\x90\x6D\x4A\x90\x6D\x4A"
  4688. "\x27\x04\xE1\x27\x04\xE1\xBE\x9B"
  4689. "\x78\xBE\x9B\x78\x55\x32\x0F\x55",
  4690. .klen = 32,
  4691. .iv = "\xE2\x24\x89\xEE\x53\xB8\x1D\x5F"
  4692. "\xC4\x29\x8E\xF3\x35\x9A\xFF\x64",
  4693. .input = "\x84\x68\xEC\xF2\x1C\x88\x20\xCA"
  4694. "\x37\x69\xE3\x3A\x22\x85\x48\x46"
  4695. "\x70\xAA\x25\xB4\xCD\x8B\x04\x4E"
  4696. "\x8D\x15\x2B\x98\xDF\x7B\x6D\xB9"
  4697. "\xE0\x4A\x73\x00\x65\xB6\x1A\x0D"
  4698. "\x5C\x60\xDF\x34\xDC\x60\x4C\xDF"
  4699. "\xB5\x1F\x26\x8C\xDA\xC1\x11\xA8"
  4700. "\x80\xFA\x37\x7A\x89\xAA\xAE\x7B"
  4701. "\x92\x6E\xB9\xDC\xC9\x62\x4F\x88"
  4702. "\x0A\x5D\x97\x2F\x6B\xAC\x03\x7C"
  4703. "\x22\xF6\x55\x5A\xFA\x35\xA5\x17"
  4704. "\xA1\x5C\x5E\x2B\x63\x2D\xB9\x91"
  4705. "\x3E\x83\x26\x00\x4E\xD5\xBE\xCE"
  4706. "\x79\xC4\x3D\xFC\x70\xA0\xAD\x96"
  4707. "\xBA\x58\x2A\x1C\xDF\xC2\x3A\xA5"
  4708. "\x7C\xB5\x12\x89\xED\xBF\xB6\x09"
  4709. "\x13\x4F\x7D\x61\x3C\x5C\x27\xFC"
  4710. "\x5D\xE1\x4F\xA1\xEA\xB3\xCA\xB9"
  4711. "\xE6\xD0\x97",
  4712. .ilen = 147,
  4713. .result = "\x56\xED\x84\x1B\x8F\x26\xBD\x31"
  4714. "\xC8\x5F\xF6\x6A\x01\x98\x0C\xA3"
  4715. "\x3A\xD1\x45\xDC\x73\x0A\x7E\x15"
  4716. "\xAC\x20\xB7\x4E\xE5\x59\xF0\x87"
  4717. "\x1E\x92\x29\xC0\x34\xCB\x62\xF9"
  4718. "\x6D\x04\x9B\x0F\xA6\x3D\xD4\x48"
  4719. "\xDF\x76\x0D\x81\x18\xAF\x23\xBA"
  4720. "\x51\xE8\x5C\xF3\x8A\x21\x95\x2C"
  4721. "\xC3\x37\xCE\x65\xFC\x70\x07\x9E"
  4722. "\x12\xA9\x40\xD7\x4B\xE2\x79\x10"
  4723. "\x84\x1B\xB2\x26\xBD\x54\xEB\x5F"
  4724. "\xF6\x8D\x01\x98\x2F\xC6\x3A\xD1"
  4725. "\x68\xFF\x73\x0A\xA1\x15\xAC\x43"
  4726. "\xDA\x4E\xE5\x7C\x13\x87\x1E\xB5"
  4727. "\x29\xC0\x57\xEE\x62\xF9\x90\x04"
  4728. "\x9B\x32\xC9\x3D\xD4\x6B\x02\x76"
  4729. "\x0D\xA4\x18\xAF\x46\xDD\x51\xE8"
  4730. "\x7F\x16\x8A\x21\xB8\x2C\xC3\x5A"
  4731. "\xF1\x65\xFC",
  4732. .rlen = 147,
  4733. },
  4734. };
  4735. static struct cipher_testvec serpent_lrw_enc_tv_template[] = {
  4736. /* Generated from AES-LRW test vectors */
  4737. {
  4738. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  4739. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  4740. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  4741. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  4742. .klen = 32,
  4743. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4744. "\x00\x00\x00\x00\x00\x00\x00\x01",
  4745. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4746. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4747. .ilen = 16,
  4748. .result = "\x6f\xbf\xd4\xa4\x5d\x71\x16\x79"
  4749. "\x63\x9c\xa6\x8e\x40\xbe\x0d\x8a",
  4750. .rlen = 16,
  4751. }, {
  4752. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  4753. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  4754. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  4755. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  4756. .klen = 32,
  4757. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4758. "\x00\x00\x00\x00\x00\x00\x00\x02",
  4759. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4760. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4761. .ilen = 16,
  4762. .result = "\xfd\xb2\x66\x98\x80\x96\x55\xad"
  4763. "\x08\x94\x54\x9c\x21\x7c\x69\xe3",
  4764. .rlen = 16,
  4765. }, {
  4766. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  4767. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  4768. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  4769. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  4770. .klen = 32,
  4771. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4772. "\x00\x00\x00\x02\x00\x00\x00\x00",
  4773. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4774. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4775. .ilen = 16,
  4776. .result = "\x14\x5e\x3d\x70\xc0\x6e\x9c\x34"
  4777. "\x5b\x5e\xcf\x0f\xe4\x8c\x21\x5c",
  4778. .rlen = 16,
  4779. }, {
  4780. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  4781. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  4782. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  4783. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  4784. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  4785. .klen = 40,
  4786. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4787. "\x00\x00\x00\x00\x00\x00\x00\x01",
  4788. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4789. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4790. .ilen = 16,
  4791. .result = "\x25\x39\xaa\xa5\xf0\x65\xc8\xdc"
  4792. "\x5d\x45\x95\x30\x8f\xff\x2f\x1b",
  4793. .rlen = 16,
  4794. }, {
  4795. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  4796. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  4797. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  4798. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  4799. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  4800. .klen = 40,
  4801. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4802. "\x00\x00\x00\x02\x00\x00\x00\x00",
  4803. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4804. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4805. .ilen = 16,
  4806. .result = "\x0c\x20\x20\x63\xd6\x8b\xfc\x8f"
  4807. "\xc0\xe2\x17\xbb\xd2\x59\x6f\x26",
  4808. .rlen = 16,
  4809. }, {
  4810. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  4811. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  4812. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  4813. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  4814. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  4815. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  4816. .klen = 48,
  4817. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4818. "\x00\x00\x00\x00\x00\x00\x00\x01",
  4819. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4820. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4821. .ilen = 16,
  4822. .result = "\xc1\x35\x2e\x53\xf0\x96\x4d\x9c"
  4823. "\x2e\x18\xe6\x99\xcd\xd3\x15\x68",
  4824. .rlen = 16,
  4825. }, {
  4826. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  4827. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  4828. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  4829. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  4830. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  4831. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  4832. .klen = 48,
  4833. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4834. "\x00\x00\x00\x02\x00\x00\x00\x00",
  4835. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4836. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4837. .ilen = 16,
  4838. .result = "\x86\x0a\xc6\xa9\x1a\x9f\xe7\xe6"
  4839. "\x64\x3b\x33\xd6\xd5\x84\xd6\xdf",
  4840. .rlen = 16,
  4841. }, {
  4842. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  4843. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  4844. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  4845. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  4846. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  4847. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  4848. .klen = 48,
  4849. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4850. "\x00\x00\x00\x00\x00\x00\x00\x01",
  4851. .input = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  4852. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  4853. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  4854. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  4855. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  4856. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  4857. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  4858. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  4859. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  4860. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  4861. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  4862. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  4863. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  4864. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  4865. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  4866. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  4867. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  4868. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  4869. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  4870. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  4871. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  4872. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  4873. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  4874. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  4875. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  4876. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  4877. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  4878. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  4879. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  4880. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  4881. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  4882. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  4883. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  4884. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  4885. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  4886. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  4887. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  4888. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  4889. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  4890. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  4891. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  4892. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  4893. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  4894. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  4895. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  4896. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  4897. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  4898. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  4899. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  4900. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  4901. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  4902. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  4903. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  4904. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  4905. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  4906. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  4907. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  4908. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  4909. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  4910. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  4911. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  4912. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  4913. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  4914. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  4915. .ilen = 512,
  4916. .result = "\xe3\x5a\x38\x0f\x4d\x92\x3a\x74"
  4917. "\x15\xb1\x50\x8c\x9a\xd8\x99\x1d"
  4918. "\x82\xec\xf1\x5f\x03\x6d\x02\x58"
  4919. "\x90\x67\xfc\xdd\x8d\xe1\x38\x08"
  4920. "\x7b\xc9\x9b\x4b\x04\x09\x50\x15"
  4921. "\xce\xab\xda\x33\x30\x20\x12\xfa"
  4922. "\x83\xc4\xa6\x9a\x2e\x7d\x90\xd9"
  4923. "\xa6\xa6\x67\x43\xb4\xa7\xa8\x5c"
  4924. "\xbb\x6a\x49\x2b\x8b\xf8\xd0\x22"
  4925. "\xe5\x9e\xba\xe8\x8c\x67\xb8\x5b"
  4926. "\x60\xbc\xf5\xa4\x95\x4e\x66\xe5"
  4927. "\x6d\x8e\xa9\xf6\x65\x2e\x04\xf5"
  4928. "\xba\xb5\xdb\x88\xc2\xf6\x7a\x4b"
  4929. "\x89\x58\x7c\x9a\xae\x26\xe8\xb7"
  4930. "\xb7\x28\xcc\xd6\xcc\xa5\x98\x4d"
  4931. "\xb9\x91\xcb\xb4\xe4\x8b\x96\x47"
  4932. "\x5f\x03\x8b\xdd\x94\xd1\xee\x12"
  4933. "\xa7\x83\x80\xf2\xc1\x15\x74\x4f"
  4934. "\x49\xf9\xb0\x7e\x6f\xdc\x73\x2f"
  4935. "\xe2\xcf\xe0\x1b\x34\xa5\xa0\x52"
  4936. "\xfb\x3c\x5d\x85\x91\xe6\x6d\x98"
  4937. "\x04\xd6\xdd\x4c\x00\x64\xd9\x54"
  4938. "\x5c\x3c\x08\x1d\x4c\x06\x9f\xb8"
  4939. "\x1c\x4d\x8d\xdc\xa4\x3c\xb9\x3b"
  4940. "\x9e\x85\xce\xc3\xa8\x4a\x0c\xd9"
  4941. "\x04\xc3\x6f\x17\x66\xa9\x1f\x59"
  4942. "\xd9\xe2\x19\x36\xa3\x88\xb8\x0b"
  4943. "\x0f\x4a\x4d\xf8\xc8\x6f\xd5\x43"
  4944. "\xeb\xa0\xab\x1f\x61\xc0\x06\xeb"
  4945. "\x93\xb7\xb8\x6f\x0d\xbd\x07\x49"
  4946. "\xb3\xac\x5d\xcf\x31\xa0\x27\x26"
  4947. "\x21\xbe\x94\x2e\x19\xea\xf4\xee"
  4948. "\xb5\x13\x89\xf7\x94\x0b\xef\x59"
  4949. "\x44\xc5\x78\x8b\x3c\x3b\x71\x20"
  4950. "\xf9\x35\x0c\x70\x74\xdc\x5b\xc2"
  4951. "\xb4\x11\x0e\x2c\x61\xa1\x52\x46"
  4952. "\x18\x11\x16\xc6\x86\x44\xa7\xaf"
  4953. "\xd5\x0c\x7d\xa6\x9e\x25\x2d\x1b"
  4954. "\x9a\x8f\x0f\xf8\x6a\x61\xa0\xea"
  4955. "\x3f\x0e\x90\xd6\x8f\x83\x30\x64"
  4956. "\xb5\x51\x2d\x08\x3c\xcd\x99\x36"
  4957. "\x96\xd4\xb1\xb5\x48\x30\xca\x48"
  4958. "\xf7\x11\xa8\xf5\x97\x8a\x6a\x6d"
  4959. "\x12\x33\x2f\xc0\xe8\xda\xec\x8a"
  4960. "\xe1\x88\x72\x63\xde\x20\xa3\xe1"
  4961. "\x8e\xac\x84\x37\x35\xf5\xf7\x3f"
  4962. "\x00\x02\x0e\xe4\xc1\x53\x68\x3f"
  4963. "\xaa\xd5\xac\x52\x3d\x20\x2f\x4d"
  4964. "\x7c\x83\xd0\xbd\xaa\x97\x35\x36"
  4965. "\x98\x88\x59\x5d\xe7\x24\xe3\x90"
  4966. "\x9d\x30\x47\xa7\xc3\x60\x35\xf4"
  4967. "\xd5\xdb\x0e\x4d\x44\xc1\x81\x8b"
  4968. "\xfd\xbd\xc3\x2b\xba\x68\xfe\x8d"
  4969. "\x49\x5a\x3c\x8a\xa3\x01\xae\x25"
  4970. "\x42\xab\xd2\x87\x1b\x35\xd6\xd2"
  4971. "\xd7\x70\x1c\x1f\x72\xd1\xe1\x39"
  4972. "\x1c\x58\xa2\xb4\xd0\x78\x55\x72"
  4973. "\x76\x59\xea\xd9\xd7\x6e\x63\x8b"
  4974. "\xcc\x9b\xa7\x74\x89\xfc\xa3\x68"
  4975. "\x86\x28\xd1\xbb\x54\x8d\x66\xad"
  4976. "\x2a\x92\xf9\x4e\x04\x3d\xae\xfd"
  4977. "\x1b\x2b\x7f\xc3\x2f\x1a\x78\x0a"
  4978. "\x5c\xc6\x84\xfe\x7c\xcb\x26\xfd"
  4979. "\xd9\x51\x0f\xd7\x94\x2f\xc5\xa7",
  4980. .rlen = 512,
  4981. },
  4982. };
  4983. static struct cipher_testvec serpent_lrw_dec_tv_template[] = {
  4984. /* Generated from AES-LRW test vectors */
  4985. /* same as enc vectors with input and result reversed */
  4986. {
  4987. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  4988. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  4989. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  4990. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  4991. .klen = 32,
  4992. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  4993. "\x00\x00\x00\x00\x00\x00\x00\x01",
  4994. .input = "\x6f\xbf\xd4\xa4\x5d\x71\x16\x79"
  4995. "\x63\x9c\xa6\x8e\x40\xbe\x0d\x8a",
  4996. .ilen = 16,
  4997. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  4998. "\x38\x39\x41\x42\x43\x44\x45\x46",
  4999. .rlen = 16,
  5000. }, {
  5001. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  5002. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  5003. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  5004. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  5005. .klen = 32,
  5006. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5007. "\x00\x00\x00\x00\x00\x00\x00\x02",
  5008. .input = "\xfd\xb2\x66\x98\x80\x96\x55\xad"
  5009. "\x08\x94\x54\x9c\x21\x7c\x69\xe3",
  5010. .ilen = 16,
  5011. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5012. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5013. .rlen = 16,
  5014. }, {
  5015. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  5016. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  5017. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  5018. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  5019. .klen = 32,
  5020. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5021. "\x00\x00\x00\x02\x00\x00\x00\x00",
  5022. .input = "\x14\x5e\x3d\x70\xc0\x6e\x9c\x34"
  5023. "\x5b\x5e\xcf\x0f\xe4\x8c\x21\x5c",
  5024. .ilen = 16,
  5025. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5026. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5027. .rlen = 16,
  5028. }, {
  5029. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  5030. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  5031. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  5032. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  5033. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  5034. .klen = 40,
  5035. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5036. "\x00\x00\x00\x00\x00\x00\x00\x01",
  5037. .input = "\x25\x39\xaa\xa5\xf0\x65\xc8\xdc"
  5038. "\x5d\x45\x95\x30\x8f\xff\x2f\x1b",
  5039. .ilen = 16,
  5040. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5041. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5042. .rlen = 16,
  5043. }, {
  5044. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  5045. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  5046. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  5047. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  5048. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  5049. .klen = 40,
  5050. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5051. "\x00\x00\x00\x02\x00\x00\x00\x00",
  5052. .input = "\x0c\x20\x20\x63\xd6\x8b\xfc\x8f"
  5053. "\xc0\xe2\x17\xbb\xd2\x59\x6f\x26",
  5054. .ilen = 16,
  5055. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5056. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5057. .rlen = 16,
  5058. }, {
  5059. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  5060. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  5061. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  5062. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  5063. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  5064. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  5065. .klen = 48,
  5066. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5067. "\x00\x00\x00\x00\x00\x00\x00\x01",
  5068. .input = "\xc1\x35\x2e\x53\xf0\x96\x4d\x9c"
  5069. "\x2e\x18\xe6\x99\xcd\xd3\x15\x68",
  5070. .ilen = 16,
  5071. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5072. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5073. .rlen = 16,
  5074. }, {
  5075. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  5076. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  5077. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  5078. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  5079. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  5080. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  5081. .klen = 48,
  5082. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5083. "\x00\x00\x00\x02\x00\x00\x00\x00",
  5084. .input = "\x86\x0a\xc6\xa9\x1a\x9f\xe7\xe6"
  5085. "\x64\x3b\x33\xd6\xd5\x84\xd6\xdf",
  5086. .ilen = 16,
  5087. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  5088. "\x38\x39\x41\x42\x43\x44\x45\x46",
  5089. .rlen = 16,
  5090. }, {
  5091. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  5092. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  5093. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  5094. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  5095. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  5096. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  5097. .klen = 48,
  5098. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5099. "\x00\x00\x00\x00\x00\x00\x00\x01",
  5100. .input = "\xe3\x5a\x38\x0f\x4d\x92\x3a\x74"
  5101. "\x15\xb1\x50\x8c\x9a\xd8\x99\x1d"
  5102. "\x82\xec\xf1\x5f\x03\x6d\x02\x58"
  5103. "\x90\x67\xfc\xdd\x8d\xe1\x38\x08"
  5104. "\x7b\xc9\x9b\x4b\x04\x09\x50\x15"
  5105. "\xce\xab\xda\x33\x30\x20\x12\xfa"
  5106. "\x83\xc4\xa6\x9a\x2e\x7d\x90\xd9"
  5107. "\xa6\xa6\x67\x43\xb4\xa7\xa8\x5c"
  5108. "\xbb\x6a\x49\x2b\x8b\xf8\xd0\x22"
  5109. "\xe5\x9e\xba\xe8\x8c\x67\xb8\x5b"
  5110. "\x60\xbc\xf5\xa4\x95\x4e\x66\xe5"
  5111. "\x6d\x8e\xa9\xf6\x65\x2e\x04\xf5"
  5112. "\xba\xb5\xdb\x88\xc2\xf6\x7a\x4b"
  5113. "\x89\x58\x7c\x9a\xae\x26\xe8\xb7"
  5114. "\xb7\x28\xcc\xd6\xcc\xa5\x98\x4d"
  5115. "\xb9\x91\xcb\xb4\xe4\x8b\x96\x47"
  5116. "\x5f\x03\x8b\xdd\x94\xd1\xee\x12"
  5117. "\xa7\x83\x80\xf2\xc1\x15\x74\x4f"
  5118. "\x49\xf9\xb0\x7e\x6f\xdc\x73\x2f"
  5119. "\xe2\xcf\xe0\x1b\x34\xa5\xa0\x52"
  5120. "\xfb\x3c\x5d\x85\x91\xe6\x6d\x98"
  5121. "\x04\xd6\xdd\x4c\x00\x64\xd9\x54"
  5122. "\x5c\x3c\x08\x1d\x4c\x06\x9f\xb8"
  5123. "\x1c\x4d\x8d\xdc\xa4\x3c\xb9\x3b"
  5124. "\x9e\x85\xce\xc3\xa8\x4a\x0c\xd9"
  5125. "\x04\xc3\x6f\x17\x66\xa9\x1f\x59"
  5126. "\xd9\xe2\x19\x36\xa3\x88\xb8\x0b"
  5127. "\x0f\x4a\x4d\xf8\xc8\x6f\xd5\x43"
  5128. "\xeb\xa0\xab\x1f\x61\xc0\x06\xeb"
  5129. "\x93\xb7\xb8\x6f\x0d\xbd\x07\x49"
  5130. "\xb3\xac\x5d\xcf\x31\xa0\x27\x26"
  5131. "\x21\xbe\x94\x2e\x19\xea\xf4\xee"
  5132. "\xb5\x13\x89\xf7\x94\x0b\xef\x59"
  5133. "\x44\xc5\x78\x8b\x3c\x3b\x71\x20"
  5134. "\xf9\x35\x0c\x70\x74\xdc\x5b\xc2"
  5135. "\xb4\x11\x0e\x2c\x61\xa1\x52\x46"
  5136. "\x18\x11\x16\xc6\x86\x44\xa7\xaf"
  5137. "\xd5\x0c\x7d\xa6\x9e\x25\x2d\x1b"
  5138. "\x9a\x8f\x0f\xf8\x6a\x61\xa0\xea"
  5139. "\x3f\x0e\x90\xd6\x8f\x83\x30\x64"
  5140. "\xb5\x51\x2d\x08\x3c\xcd\x99\x36"
  5141. "\x96\xd4\xb1\xb5\x48\x30\xca\x48"
  5142. "\xf7\x11\xa8\xf5\x97\x8a\x6a\x6d"
  5143. "\x12\x33\x2f\xc0\xe8\xda\xec\x8a"
  5144. "\xe1\x88\x72\x63\xde\x20\xa3\xe1"
  5145. "\x8e\xac\x84\x37\x35\xf5\xf7\x3f"
  5146. "\x00\x02\x0e\xe4\xc1\x53\x68\x3f"
  5147. "\xaa\xd5\xac\x52\x3d\x20\x2f\x4d"
  5148. "\x7c\x83\xd0\xbd\xaa\x97\x35\x36"
  5149. "\x98\x88\x59\x5d\xe7\x24\xe3\x90"
  5150. "\x9d\x30\x47\xa7\xc3\x60\x35\xf4"
  5151. "\xd5\xdb\x0e\x4d\x44\xc1\x81\x8b"
  5152. "\xfd\xbd\xc3\x2b\xba\x68\xfe\x8d"
  5153. "\x49\x5a\x3c\x8a\xa3\x01\xae\x25"
  5154. "\x42\xab\xd2\x87\x1b\x35\xd6\xd2"
  5155. "\xd7\x70\x1c\x1f\x72\xd1\xe1\x39"
  5156. "\x1c\x58\xa2\xb4\xd0\x78\x55\x72"
  5157. "\x76\x59\xea\xd9\xd7\x6e\x63\x8b"
  5158. "\xcc\x9b\xa7\x74\x89\xfc\xa3\x68"
  5159. "\x86\x28\xd1\xbb\x54\x8d\x66\xad"
  5160. "\x2a\x92\xf9\x4e\x04\x3d\xae\xfd"
  5161. "\x1b\x2b\x7f\xc3\x2f\x1a\x78\x0a"
  5162. "\x5c\xc6\x84\xfe\x7c\xcb\x26\xfd"
  5163. "\xd9\x51\x0f\xd7\x94\x2f\xc5\xa7",
  5164. .ilen = 512,
  5165. .result = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  5166. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  5167. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  5168. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  5169. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  5170. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  5171. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  5172. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  5173. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  5174. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  5175. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  5176. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  5177. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  5178. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  5179. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  5180. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  5181. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  5182. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  5183. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  5184. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  5185. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  5186. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  5187. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  5188. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  5189. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  5190. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  5191. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  5192. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  5193. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  5194. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  5195. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  5196. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  5197. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  5198. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  5199. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  5200. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  5201. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  5202. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  5203. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  5204. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  5205. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  5206. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  5207. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  5208. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  5209. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  5210. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  5211. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  5212. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  5213. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  5214. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  5215. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  5216. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  5217. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  5218. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  5219. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  5220. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  5221. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  5222. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  5223. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  5224. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  5225. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  5226. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  5227. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  5228. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  5229. .rlen = 512,
  5230. },
  5231. };
  5232. static struct cipher_testvec serpent_xts_enc_tv_template[] = {
  5233. /* Generated from AES-XTS test vectors */
  5234. {
  5235. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5236. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5237. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5238. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5239. .klen = 32,
  5240. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5241. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5242. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5243. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5244. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5245. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5246. .ilen = 32,
  5247. .result = "\xe1\x08\xb8\x1d\x2c\xf5\x33\x64"
  5248. "\xc8\x12\x04\xc7\xb3\x70\xe8\xc4"
  5249. "\x6a\x31\xc5\xf3\x00\xca\xb9\x16"
  5250. "\xde\xe2\x77\x66\xf7\xfe\x62\x08",
  5251. .rlen = 32,
  5252. }, {
  5253. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  5254. "\x11\x11\x11\x11\x11\x11\x11\x11"
  5255. "\x22\x22\x22\x22\x22\x22\x22\x22"
  5256. "\x22\x22\x22\x22\x22\x22\x22\x22",
  5257. .klen = 32,
  5258. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  5259. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5260. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  5261. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5262. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5263. "\x44\x44\x44\x44\x44\x44\x44\x44",
  5264. .ilen = 32,
  5265. .result = "\x1a\x0a\x09\x5f\xcd\x07\x07\x98"
  5266. "\x41\x86\x12\xaf\xb3\xd7\x68\x13"
  5267. "\xed\x81\xcd\x06\x87\x43\x1a\xbb"
  5268. "\x13\x3d\xd6\x1e\x2b\xe1\x77\xbe",
  5269. .rlen = 32,
  5270. }, {
  5271. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  5272. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  5273. "\x22\x22\x22\x22\x22\x22\x22\x22"
  5274. "\x22\x22\x22\x22\x22\x22\x22\x22",
  5275. .klen = 32,
  5276. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  5277. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5278. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  5279. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5280. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5281. "\x44\x44\x44\x44\x44\x44\x44\x44",
  5282. .ilen = 32,
  5283. .result = "\xf9\x9b\x28\xb8\x5c\xaf\x8c\x61"
  5284. "\xb6\x1c\x81\x8f\x2c\x87\x60\x89"
  5285. "\x0d\x8d\x7a\xe8\x60\x48\xcc\x86"
  5286. "\xc1\x68\x45\xaa\x00\xe9\x24\xc5",
  5287. .rlen = 32,
  5288. }, {
  5289. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  5290. "\x23\x53\x60\x28\x74\x71\x35\x26"
  5291. "\x31\x41\x59\x26\x53\x58\x97\x93"
  5292. "\x23\x84\x62\x64\x33\x83\x27\x95",
  5293. .klen = 32,
  5294. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5295. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5296. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  5297. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5298. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5299. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5300. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5301. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5302. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5303. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5304. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5305. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5306. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5307. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5308. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5309. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5310. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5311. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5312. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5313. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5314. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5315. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5316. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5317. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5318. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5319. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5320. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5321. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5322. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5323. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5324. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5325. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5326. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5327. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  5328. "\x00\x01\x02\x03\x04\x05\x06\x07"
  5329. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5330. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5331. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5332. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5333. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5334. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5335. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5336. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5337. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5338. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5339. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5340. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5341. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5342. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5343. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5344. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5345. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5346. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5347. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5348. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5349. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5350. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5351. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5352. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5353. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5354. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5355. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5356. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5357. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5358. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5359. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  5360. .ilen = 512,
  5361. .result = "\xfe\x47\x4a\xc8\x60\x7e\xb4\x8b"
  5362. "\x0d\x10\xf4\xb0\x0d\xba\xf8\x53"
  5363. "\x65\x6e\x38\x4b\xdb\xaa\xb1\x9e"
  5364. "\x28\xca\xb0\x22\xb3\x85\x75\xf4"
  5365. "\x00\x5c\x75\x14\x06\xd6\x25\x82"
  5366. "\xe6\xcb\x08\xf7\x29\x90\x23\x8e"
  5367. "\xa4\x68\x57\xe4\xf0\xd8\x32\xf3"
  5368. "\x80\x51\x67\xb5\x0b\x85\x69\xe8"
  5369. "\x19\xfe\xc4\xc7\x3e\xea\x90\xd3"
  5370. "\x8f\xa3\xf2\x0a\xac\x17\x4b\xa0"
  5371. "\x63\x5a\x16\x0f\xf0\xce\x66\x1f"
  5372. "\x2c\x21\x07\xf1\xa4\x03\xa3\x44"
  5373. "\x41\x61\x87\x5d\x6b\xb3\xef\xd4"
  5374. "\xfc\xaa\x32\x7e\x55\x58\x04\x41"
  5375. "\xc9\x07\x33\xc6\xa2\x68\xd6\x5a"
  5376. "\x55\x79\x4b\x6f\xcf\x89\xb9\x19"
  5377. "\xe5\x54\x13\x15\xb2\x1a\xfa\x15"
  5378. "\xc2\xf0\x06\x59\xfa\xa0\x25\x05"
  5379. "\x58\xfa\x43\x91\x16\x85\x40\xbb"
  5380. "\x0d\x34\x4d\xc5\x1e\x20\xd5\x08"
  5381. "\xcd\x22\x22\x41\x11\x9f\x6c\x7c"
  5382. "\x8d\x57\xc9\xba\x57\xe8\x2c\xf7"
  5383. "\xa0\x42\xa8\xde\xfc\xa3\xca\x98"
  5384. "\x4b\x43\xb1\xce\x4b\xbf\x01\x67"
  5385. "\x6e\x29\x60\xbd\x10\x14\x84\x82"
  5386. "\x83\x82\x0c\x63\x73\x92\x02\x7c"
  5387. "\x55\x37\x20\x80\x17\x51\xc8\xbc"
  5388. "\x46\x02\xcb\x38\x07\x6d\xe2\x85"
  5389. "\xaa\x29\xaf\x24\x58\x0d\xf0\x75"
  5390. "\x08\x0a\xa5\x34\x25\x16\xf3\x74"
  5391. "\xa7\x0b\x97\xbe\xc1\xa9\xdc\x29"
  5392. "\x1a\x0a\x56\xc1\x1a\x91\x97\x8c"
  5393. "\x0b\xc7\x16\xed\x5a\x22\xa6\x2e"
  5394. "\x8c\x2b\x4f\x54\x76\x47\x53\x8e"
  5395. "\xe8\x00\xec\x92\xb9\x55\xe6\xa2"
  5396. "\xf3\xe2\x4f\x6a\x66\x60\xd0\x87"
  5397. "\xe6\xd1\xcc\xe3\x6a\xc5\x2d\x21"
  5398. "\xcc\x9d\x6a\xb6\x75\xaa\xe2\x19"
  5399. "\x21\x9f\xa1\x5e\x4c\xfd\x72\xf9"
  5400. "\x94\x4e\x63\xc7\xae\xfc\xed\x47"
  5401. "\xe2\xfe\x7a\x63\x77\xfe\x97\x82"
  5402. "\xb1\x10\x6e\x36\x1d\xe1\xc4\x80"
  5403. "\xec\x69\x41\xec\xa7\x8a\xe0\x2f"
  5404. "\xe3\x49\x26\xa2\x41\xb2\x08\x0f"
  5405. "\x28\xb4\xa7\x39\xa1\x99\x2d\x1e"
  5406. "\x43\x42\x35\xd0\xcf\xec\x77\x67"
  5407. "\xb2\x3b\x9e\x1c\x35\xde\x4f\x5e"
  5408. "\x73\x3f\x5d\x6f\x07\x4b\x2e\x50"
  5409. "\xab\x6c\x6b\xff\xea\x00\x67\xaa"
  5410. "\x0e\x82\x32\xdd\x3d\xb5\xe5\x76"
  5411. "\x2b\x77\x3f\xbe\x12\x75\xfb\x92"
  5412. "\xc6\x89\x67\x4d\xca\xf7\xd4\x50"
  5413. "\xc0\x74\x47\xcc\xd9\x0a\xd4\xc6"
  5414. "\x3b\x17\x2e\xe3\x35\xbb\x53\xb5"
  5415. "\x86\xad\x51\xcc\xd5\x96\xb8\xdc"
  5416. "\x03\x57\xe6\x98\x52\x2f\x61\x62"
  5417. "\xc4\x5c\x9c\x36\x71\x07\xfb\x94"
  5418. "\xe3\x02\xc4\x2b\x08\x75\xc7\x35"
  5419. "\xfb\x2e\x88\x7b\xbb\x67\x00\xe1"
  5420. "\xc9\xdd\x99\xb2\x13\x53\x1a\x4e"
  5421. "\x76\x87\x19\x04\x1a\x2f\x38\x3e"
  5422. "\xef\x91\x64\x1d\x18\x07\x4e\x31"
  5423. "\x88\x21\x7c\xb0\xa5\x12\x4c\x3c"
  5424. "\xb0\x20\xbd\xda\xdf\xf9\x7c\xdd",
  5425. .rlen = 512,
  5426. }, {
  5427. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  5428. "\x23\x53\x60\x28\x74\x71\x35\x26"
  5429. "\x62\x49\x77\x57\x24\x70\x93\x69"
  5430. "\x99\x59\x57\x49\x66\x96\x76\x27"
  5431. "\x31\x41\x59\x26\x53\x58\x97\x93"
  5432. "\x23\x84\x62\x64\x33\x83\x27\x95"
  5433. "\x02\x88\x41\x97\x16\x93\x99\x37"
  5434. "\x51\x05\x82\x09\x74\x94\x45\x92",
  5435. .klen = 64,
  5436. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  5437. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5438. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  5439. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5440. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5441. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5442. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5443. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5444. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5445. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5446. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5447. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5448. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5449. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5450. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5451. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5452. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5453. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5454. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5455. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5456. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5457. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5458. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5459. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5460. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5461. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5462. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5463. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5464. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5465. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5466. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5467. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5468. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5469. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  5470. "\x00\x01\x02\x03\x04\x05\x06\x07"
  5471. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5472. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5473. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5474. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5475. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5476. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5477. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5478. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5479. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5480. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5481. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5482. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5483. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5484. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5485. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5486. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5487. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5488. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5489. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5490. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5491. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5492. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5493. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5494. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5495. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5496. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5497. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5498. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5499. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5500. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5501. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  5502. .ilen = 512,
  5503. .result = "\x2b\xc9\xb4\x6b\x10\x94\xa9\x32"
  5504. "\xaa\xb0\x20\xc6\x44\x3d\x74\x1f"
  5505. "\x75\x01\xa7\xf6\xf5\xf7\x62\x1b"
  5506. "\x80\x1b\x82\xcb\x01\x59\x91\x7f"
  5507. "\x80\x3a\x98\xf0\xd2\xca\xc4\xc3"
  5508. "\x34\xfd\xe6\x11\xf9\x33\x45\x12"
  5509. "\x48\xc5\x8c\x25\xf1\xc5\xc5\x23"
  5510. "\xd3\x44\xb4\x73\xd5\x04\xc0\xb7"
  5511. "\xca\x2f\xf5\xcd\xc5\xb4\xdd\xb0"
  5512. "\xf4\x60\xe8\xfb\xc6\x9c\xc5\x78"
  5513. "\xcd\xec\x7d\xdc\x19\x9c\x72\x64"
  5514. "\x63\x0b\x38\x2e\x76\xdd\x2d\x36"
  5515. "\x49\xb0\x1d\xea\x78\x9e\x00\xca"
  5516. "\x20\xcc\x1b\x1e\x98\x74\xab\xed"
  5517. "\x79\xf7\xd0\x6c\xd8\x93\x80\x29"
  5518. "\xac\xa5\x5e\x34\xa9\xab\xa0\x55"
  5519. "\x9a\xea\xaa\x95\x4d\x7b\xfe\x46"
  5520. "\x26\x8a\xfd\x88\xa2\xa8\xa6\xae"
  5521. "\x25\x42\x17\xbf\x76\x8f\x1c\x3d"
  5522. "\xec\x9a\xda\x64\x96\xb5\x61\xff"
  5523. "\x99\xeb\x12\x96\x85\x82\x9d\xd5"
  5524. "\x81\x85\x14\xa8\x59\xac\x8c\x94"
  5525. "\xbb\x3b\x85\x2b\xdf\xb3\x0c\xba"
  5526. "\x82\xc6\x4d\xca\x86\xea\x53\x28"
  5527. "\x4c\xe0\x4e\x31\xe3\x73\x2f\x79"
  5528. "\x9d\x42\xe1\x03\xe3\x8b\xc4\xff"
  5529. "\x05\xca\x81\x7b\xda\xa2\xde\x63"
  5530. "\x3a\x10\xbe\xc2\xac\x32\xc4\x05"
  5531. "\x47\x7e\xef\x67\xe2\x5f\x5b\xae"
  5532. "\xed\xf1\x70\x34\x16\x9a\x07\x7b"
  5533. "\xf2\x25\x2b\xb0\xf8\x3c\x15\x9a"
  5534. "\xa6\x59\x55\x5f\xc1\xf4\x1e\xcd"
  5535. "\x93\x1f\x06\xba\xd4\x9a\x22\x69"
  5536. "\xfa\x8e\x95\x0d\xf3\x23\x59\x2c"
  5537. "\xfe\x00\xba\xf0\x0e\xbc\x6d\xd6"
  5538. "\x62\xf0\x7a\x0e\x83\x3e\xdb\x32"
  5539. "\xfd\x43\x7d\xda\x42\x51\x87\x43"
  5540. "\x9d\xf9\xef\xf4\x30\x97\xf8\x09"
  5541. "\x88\xfc\x3f\x93\x70\xc1\x4a\xec"
  5542. "\x27\x5f\x11\xac\x71\xc7\x48\x46"
  5543. "\x2f\xf9\xdf\x8d\x9f\xf7\x2e\x56"
  5544. "\x0d\x4e\xb0\x32\x76\xce\x86\x81"
  5545. "\xcd\xdf\xe4\x00\xbf\xfd\x5f\x24"
  5546. "\xaf\xf7\x9a\xde\xff\x18\xac\x14"
  5547. "\x90\xc5\x01\x39\x34\x0f\x24\xf3"
  5548. "\x13\x2f\x5e\x4f\x30\x9a\x36\x40"
  5549. "\xec\xea\xbc\xcd\x9e\x0e\x5b\x23"
  5550. "\x50\x88\x97\x40\x69\xb1\x37\xf5"
  5551. "\xc3\x15\xf9\x3f\xb7\x79\x64\xe8"
  5552. "\x7b\x10\x20\xb9\x2b\x46\x83\x5b"
  5553. "\xd8\x39\xfc\xe4\xfa\x88\x52\xf2"
  5554. "\x72\xb0\x97\x4e\x89\xb3\x48\x00"
  5555. "\xc1\x16\x73\x50\x77\xba\xa6\x65"
  5556. "\x20\x2d\xb0\x02\x27\x89\xda\x99"
  5557. "\x45\xfb\xe9\xd3\x1d\x39\x2f\xd6"
  5558. "\x2a\xda\x09\x12\x11\xaf\xe6\x57"
  5559. "\x01\x04\x8a\xff\x86\x8b\xac\xf8"
  5560. "\xee\xe4\x1c\x98\x5b\xcf\x6b\x76"
  5561. "\xa3\x0e\x33\x74\x40\x18\x39\x72"
  5562. "\x66\x50\x31\xfd\x70\xdf\xe8\x51"
  5563. "\x96\x21\x36\xb2\x9b\xfa\x85\xd1"
  5564. "\x30\x05\xc8\x92\x98\x80\xff\x7a"
  5565. "\xaf\x43\x0b\xc5\x20\x41\x92\x20"
  5566. "\xd4\xa0\x91\x98\x11\x5f\x4d\xb1",
  5567. .rlen = 512,
  5568. },
  5569. };
  5570. static struct cipher_testvec serpent_xts_dec_tv_template[] = {
  5571. /* Generated from AES-XTS test vectors */
  5572. /* same as enc vectors with input and result reversed */
  5573. {
  5574. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5575. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5576. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5577. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5578. .klen = 32,
  5579. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5580. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5581. .input = "\xe1\x08\xb8\x1d\x2c\xf5\x33\x64"
  5582. "\xc8\x12\x04\xc7\xb3\x70\xe8\xc4"
  5583. "\x6a\x31\xc5\xf3\x00\xca\xb9\x16"
  5584. "\xde\xe2\x77\x66\xf7\xfe\x62\x08",
  5585. .ilen = 32,
  5586. .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5587. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5588. "\x00\x00\x00\x00\x00\x00\x00\x00"
  5589. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5590. .rlen = 32,
  5591. }, {
  5592. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  5593. "\x11\x11\x11\x11\x11\x11\x11\x11"
  5594. "\x22\x22\x22\x22\x22\x22\x22\x22"
  5595. "\x22\x22\x22\x22\x22\x22\x22\x22",
  5596. .klen = 32,
  5597. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  5598. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5599. .input = "\x1a\x0a\x09\x5f\xcd\x07\x07\x98"
  5600. "\x41\x86\x12\xaf\xb3\xd7\x68\x13"
  5601. "\xed\x81\xcd\x06\x87\x43\x1a\xbb"
  5602. "\x13\x3d\xd6\x1e\x2b\xe1\x77\xbe",
  5603. .ilen = 32,
  5604. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  5605. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5606. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5607. "\x44\x44\x44\x44\x44\x44\x44\x44",
  5608. .rlen = 32,
  5609. }, {
  5610. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  5611. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  5612. "\x22\x22\x22\x22\x22\x22\x22\x22"
  5613. "\x22\x22\x22\x22\x22\x22\x22\x22",
  5614. .klen = 32,
  5615. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  5616. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5617. .input = "\xf9\x9b\x28\xb8\x5c\xaf\x8c\x61"
  5618. "\xb6\x1c\x81\x8f\x2c\x87\x60\x89"
  5619. "\x0d\x8d\x7a\xe8\x60\x48\xcc\x86"
  5620. "\xc1\x68\x45\xaa\x00\xe9\x24\xc5",
  5621. .ilen = 32,
  5622. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  5623. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5624. "\x44\x44\x44\x44\x44\x44\x44\x44"
  5625. "\x44\x44\x44\x44\x44\x44\x44\x44",
  5626. .rlen = 32,
  5627. }, {
  5628. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  5629. "\x23\x53\x60\x28\x74\x71\x35\x26"
  5630. "\x31\x41\x59\x26\x53\x58\x97\x93"
  5631. "\x23\x84\x62\x64\x33\x83\x27\x95",
  5632. .klen = 32,
  5633. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  5634. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5635. .input = "\xfe\x47\x4a\xc8\x60\x7e\xb4\x8b"
  5636. "\x0d\x10\xf4\xb0\x0d\xba\xf8\x53"
  5637. "\x65\x6e\x38\x4b\xdb\xaa\xb1\x9e"
  5638. "\x28\xca\xb0\x22\xb3\x85\x75\xf4"
  5639. "\x00\x5c\x75\x14\x06\xd6\x25\x82"
  5640. "\xe6\xcb\x08\xf7\x29\x90\x23\x8e"
  5641. "\xa4\x68\x57\xe4\xf0\xd8\x32\xf3"
  5642. "\x80\x51\x67\xb5\x0b\x85\x69\xe8"
  5643. "\x19\xfe\xc4\xc7\x3e\xea\x90\xd3"
  5644. "\x8f\xa3\xf2\x0a\xac\x17\x4b\xa0"
  5645. "\x63\x5a\x16\x0f\xf0\xce\x66\x1f"
  5646. "\x2c\x21\x07\xf1\xa4\x03\xa3\x44"
  5647. "\x41\x61\x87\x5d\x6b\xb3\xef\xd4"
  5648. "\xfc\xaa\x32\x7e\x55\x58\x04\x41"
  5649. "\xc9\x07\x33\xc6\xa2\x68\xd6\x5a"
  5650. "\x55\x79\x4b\x6f\xcf\x89\xb9\x19"
  5651. "\xe5\x54\x13\x15\xb2\x1a\xfa\x15"
  5652. "\xc2\xf0\x06\x59\xfa\xa0\x25\x05"
  5653. "\x58\xfa\x43\x91\x16\x85\x40\xbb"
  5654. "\x0d\x34\x4d\xc5\x1e\x20\xd5\x08"
  5655. "\xcd\x22\x22\x41\x11\x9f\x6c\x7c"
  5656. "\x8d\x57\xc9\xba\x57\xe8\x2c\xf7"
  5657. "\xa0\x42\xa8\xde\xfc\xa3\xca\x98"
  5658. "\x4b\x43\xb1\xce\x4b\xbf\x01\x67"
  5659. "\x6e\x29\x60\xbd\x10\x14\x84\x82"
  5660. "\x83\x82\x0c\x63\x73\x92\x02\x7c"
  5661. "\x55\x37\x20\x80\x17\x51\xc8\xbc"
  5662. "\x46\x02\xcb\x38\x07\x6d\xe2\x85"
  5663. "\xaa\x29\xaf\x24\x58\x0d\xf0\x75"
  5664. "\x08\x0a\xa5\x34\x25\x16\xf3\x74"
  5665. "\xa7\x0b\x97\xbe\xc1\xa9\xdc\x29"
  5666. "\x1a\x0a\x56\xc1\x1a\x91\x97\x8c"
  5667. "\x0b\xc7\x16\xed\x5a\x22\xa6\x2e"
  5668. "\x8c\x2b\x4f\x54\x76\x47\x53\x8e"
  5669. "\xe8\x00\xec\x92\xb9\x55\xe6\xa2"
  5670. "\xf3\xe2\x4f\x6a\x66\x60\xd0\x87"
  5671. "\xe6\xd1\xcc\xe3\x6a\xc5\x2d\x21"
  5672. "\xcc\x9d\x6a\xb6\x75\xaa\xe2\x19"
  5673. "\x21\x9f\xa1\x5e\x4c\xfd\x72\xf9"
  5674. "\x94\x4e\x63\xc7\xae\xfc\xed\x47"
  5675. "\xe2\xfe\x7a\x63\x77\xfe\x97\x82"
  5676. "\xb1\x10\x6e\x36\x1d\xe1\xc4\x80"
  5677. "\xec\x69\x41\xec\xa7\x8a\xe0\x2f"
  5678. "\xe3\x49\x26\xa2\x41\xb2\x08\x0f"
  5679. "\x28\xb4\xa7\x39\xa1\x99\x2d\x1e"
  5680. "\x43\x42\x35\xd0\xcf\xec\x77\x67"
  5681. "\xb2\x3b\x9e\x1c\x35\xde\x4f\x5e"
  5682. "\x73\x3f\x5d\x6f\x07\x4b\x2e\x50"
  5683. "\xab\x6c\x6b\xff\xea\x00\x67\xaa"
  5684. "\x0e\x82\x32\xdd\x3d\xb5\xe5\x76"
  5685. "\x2b\x77\x3f\xbe\x12\x75\xfb\x92"
  5686. "\xc6\x89\x67\x4d\xca\xf7\xd4\x50"
  5687. "\xc0\x74\x47\xcc\xd9\x0a\xd4\xc6"
  5688. "\x3b\x17\x2e\xe3\x35\xbb\x53\xb5"
  5689. "\x86\xad\x51\xcc\xd5\x96\xb8\xdc"
  5690. "\x03\x57\xe6\x98\x52\x2f\x61\x62"
  5691. "\xc4\x5c\x9c\x36\x71\x07\xfb\x94"
  5692. "\xe3\x02\xc4\x2b\x08\x75\xc7\x35"
  5693. "\xfb\x2e\x88\x7b\xbb\x67\x00\xe1"
  5694. "\xc9\xdd\x99\xb2\x13\x53\x1a\x4e"
  5695. "\x76\x87\x19\x04\x1a\x2f\x38\x3e"
  5696. "\xef\x91\x64\x1d\x18\x07\x4e\x31"
  5697. "\x88\x21\x7c\xb0\xa5\x12\x4c\x3c"
  5698. "\xb0\x20\xbd\xda\xdf\xf9\x7c\xdd",
  5699. .ilen = 512,
  5700. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  5701. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5702. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5703. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5704. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5705. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5706. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5707. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5708. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5709. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5710. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5711. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5712. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5713. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5714. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5715. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5716. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5717. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5718. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5719. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5720. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5721. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5722. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5723. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5724. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5725. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5726. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5727. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5728. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5729. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5730. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5731. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  5732. "\x00\x01\x02\x03\x04\x05\x06\x07"
  5733. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5734. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5735. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5736. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5737. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5738. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5739. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5740. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5741. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5742. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5743. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5744. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5745. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5746. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5747. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5748. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5749. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5750. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5751. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5752. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5753. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5754. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5755. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5756. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5757. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5758. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5759. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5760. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5761. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5762. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5763. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  5764. .rlen = 512,
  5765. }, {
  5766. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  5767. "\x23\x53\x60\x28\x74\x71\x35\x26"
  5768. "\x62\x49\x77\x57\x24\x70\x93\x69"
  5769. "\x99\x59\x57\x49\x66\x96\x76\x27"
  5770. "\x31\x41\x59\x26\x53\x58\x97\x93"
  5771. "\x23\x84\x62\x64\x33\x83\x27\x95"
  5772. "\x02\x88\x41\x97\x16\x93\x99\x37"
  5773. "\x51\x05\x82\x09\x74\x94\x45\x92",
  5774. .klen = 64,
  5775. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  5776. "\x00\x00\x00\x00\x00\x00\x00\x00",
  5777. .input = "\x2b\xc9\xb4\x6b\x10\x94\xa9\x32"
  5778. "\xaa\xb0\x20\xc6\x44\x3d\x74\x1f"
  5779. "\x75\x01\xa7\xf6\xf5\xf7\x62\x1b"
  5780. "\x80\x1b\x82\xcb\x01\x59\x91\x7f"
  5781. "\x80\x3a\x98\xf0\xd2\xca\xc4\xc3"
  5782. "\x34\xfd\xe6\x11\xf9\x33\x45\x12"
  5783. "\x48\xc5\x8c\x25\xf1\xc5\xc5\x23"
  5784. "\xd3\x44\xb4\x73\xd5\x04\xc0\xb7"
  5785. "\xca\x2f\xf5\xcd\xc5\xb4\xdd\xb0"
  5786. "\xf4\x60\xe8\xfb\xc6\x9c\xc5\x78"
  5787. "\xcd\xec\x7d\xdc\x19\x9c\x72\x64"
  5788. "\x63\x0b\x38\x2e\x76\xdd\x2d\x36"
  5789. "\x49\xb0\x1d\xea\x78\x9e\x00\xca"
  5790. "\x20\xcc\x1b\x1e\x98\x74\xab\xed"
  5791. "\x79\xf7\xd0\x6c\xd8\x93\x80\x29"
  5792. "\xac\xa5\x5e\x34\xa9\xab\xa0\x55"
  5793. "\x9a\xea\xaa\x95\x4d\x7b\xfe\x46"
  5794. "\x26\x8a\xfd\x88\xa2\xa8\xa6\xae"
  5795. "\x25\x42\x17\xbf\x76\x8f\x1c\x3d"
  5796. "\xec\x9a\xda\x64\x96\xb5\x61\xff"
  5797. "\x99\xeb\x12\x96\x85\x82\x9d\xd5"
  5798. "\x81\x85\x14\xa8\x59\xac\x8c\x94"
  5799. "\xbb\x3b\x85\x2b\xdf\xb3\x0c\xba"
  5800. "\x82\xc6\x4d\xca\x86\xea\x53\x28"
  5801. "\x4c\xe0\x4e\x31\xe3\x73\x2f\x79"
  5802. "\x9d\x42\xe1\x03\xe3\x8b\xc4\xff"
  5803. "\x05\xca\x81\x7b\xda\xa2\xde\x63"
  5804. "\x3a\x10\xbe\xc2\xac\x32\xc4\x05"
  5805. "\x47\x7e\xef\x67\xe2\x5f\x5b\xae"
  5806. "\xed\xf1\x70\x34\x16\x9a\x07\x7b"
  5807. "\xf2\x25\x2b\xb0\xf8\x3c\x15\x9a"
  5808. "\xa6\x59\x55\x5f\xc1\xf4\x1e\xcd"
  5809. "\x93\x1f\x06\xba\xd4\x9a\x22\x69"
  5810. "\xfa\x8e\x95\x0d\xf3\x23\x59\x2c"
  5811. "\xfe\x00\xba\xf0\x0e\xbc\x6d\xd6"
  5812. "\x62\xf0\x7a\x0e\x83\x3e\xdb\x32"
  5813. "\xfd\x43\x7d\xda\x42\x51\x87\x43"
  5814. "\x9d\xf9\xef\xf4\x30\x97\xf8\x09"
  5815. "\x88\xfc\x3f\x93\x70\xc1\x4a\xec"
  5816. "\x27\x5f\x11\xac\x71\xc7\x48\x46"
  5817. "\x2f\xf9\xdf\x8d\x9f\xf7\x2e\x56"
  5818. "\x0d\x4e\xb0\x32\x76\xce\x86\x81"
  5819. "\xcd\xdf\xe4\x00\xbf\xfd\x5f\x24"
  5820. "\xaf\xf7\x9a\xde\xff\x18\xac\x14"
  5821. "\x90\xc5\x01\x39\x34\x0f\x24\xf3"
  5822. "\x13\x2f\x5e\x4f\x30\x9a\x36\x40"
  5823. "\xec\xea\xbc\xcd\x9e\x0e\x5b\x23"
  5824. "\x50\x88\x97\x40\x69\xb1\x37\xf5"
  5825. "\xc3\x15\xf9\x3f\xb7\x79\x64\xe8"
  5826. "\x7b\x10\x20\xb9\x2b\x46\x83\x5b"
  5827. "\xd8\x39\xfc\xe4\xfa\x88\x52\xf2"
  5828. "\x72\xb0\x97\x4e\x89\xb3\x48\x00"
  5829. "\xc1\x16\x73\x50\x77\xba\xa6\x65"
  5830. "\x20\x2d\xb0\x02\x27\x89\xda\x99"
  5831. "\x45\xfb\xe9\xd3\x1d\x39\x2f\xd6"
  5832. "\x2a\xda\x09\x12\x11\xaf\xe6\x57"
  5833. "\x01\x04\x8a\xff\x86\x8b\xac\xf8"
  5834. "\xee\xe4\x1c\x98\x5b\xcf\x6b\x76"
  5835. "\xa3\x0e\x33\x74\x40\x18\x39\x72"
  5836. "\x66\x50\x31\xfd\x70\xdf\xe8\x51"
  5837. "\x96\x21\x36\xb2\x9b\xfa\x85\xd1"
  5838. "\x30\x05\xc8\x92\x98\x80\xff\x7a"
  5839. "\xaf\x43\x0b\xc5\x20\x41\x92\x20"
  5840. "\xd4\xa0\x91\x98\x11\x5f\x4d\xb1",
  5841. .ilen = 512,
  5842. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  5843. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5844. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5845. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5846. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5847. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5848. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5849. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5850. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5851. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5852. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5853. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5854. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5855. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5856. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5857. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5858. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5859. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5860. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5861. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5862. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5863. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5864. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5865. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5866. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5867. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5868. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5869. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5870. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5871. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5872. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5873. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  5874. "\x00\x01\x02\x03\x04\x05\x06\x07"
  5875. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  5876. "\x10\x11\x12\x13\x14\x15\x16\x17"
  5877. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  5878. "\x20\x21\x22\x23\x24\x25\x26\x27"
  5879. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  5880. "\x30\x31\x32\x33\x34\x35\x36\x37"
  5881. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  5882. "\x40\x41\x42\x43\x44\x45\x46\x47"
  5883. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  5884. "\x50\x51\x52\x53\x54\x55\x56\x57"
  5885. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  5886. "\x60\x61\x62\x63\x64\x65\x66\x67"
  5887. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  5888. "\x70\x71\x72\x73\x74\x75\x76\x77"
  5889. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  5890. "\x80\x81\x82\x83\x84\x85\x86\x87"
  5891. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  5892. "\x90\x91\x92\x93\x94\x95\x96\x97"
  5893. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  5894. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  5895. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  5896. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  5897. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  5898. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  5899. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  5900. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  5901. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  5902. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  5903. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  5904. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  5905. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  5906. .rlen = 512,
  5907. },
  5908. };
  5909. /* Cast6 test vectors from RFC 2612 */
  5910. #define CAST6_ENC_TEST_VECTORS 3
  5911. #define CAST6_DEC_TEST_VECTORS 3
  5912. static struct cipher_testvec cast6_enc_tv_template[] = {
  5913. {
  5914. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5915. "\x0a\xf7\x56\x47\xf2\x9f\x61\x5d",
  5916. .klen = 16,
  5917. .input = zeroed_string,
  5918. .ilen = 16,
  5919. .result = "\xc8\x42\xa0\x89\x72\xb4\x3d\x20"
  5920. "\x83\x6c\x91\xd1\xb7\x53\x0f\x6b",
  5921. .rlen = 16,
  5922. }, {
  5923. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5924. "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
  5925. "\xba\xc7\x7a\x77\x17\x94\x28\x63",
  5926. .klen = 24,
  5927. .input = zeroed_string,
  5928. .ilen = 16,
  5929. .result = "\x1b\x38\x6c\x02\x10\xdc\xad\xcb"
  5930. "\xdd\x0e\x41\xaa\x08\xa7\xa7\xe8",
  5931. .rlen = 16,
  5932. }, {
  5933. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5934. "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
  5935. "\x8d\x7c\x47\xce\x26\x49\x08\x46"
  5936. "\x1c\xc1\xb5\x13\x7a\xe6\xb6\x04",
  5937. .klen = 32,
  5938. .input = zeroed_string,
  5939. .ilen = 16,
  5940. .result = "\x4f\x6a\x20\x38\x28\x68\x97\xb9"
  5941. "\xc9\x87\x01\x36\x55\x33\x17\xfa",
  5942. .rlen = 16,
  5943. },
  5944. };
  5945. static struct cipher_testvec cast6_dec_tv_template[] = {
  5946. {
  5947. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5948. "\x0a\xf7\x56\x47\xf2\x9f\x61\x5d",
  5949. .klen = 16,
  5950. .input = "\xc8\x42\xa0\x89\x72\xb4\x3d\x20"
  5951. "\x83\x6c\x91\xd1\xb7\x53\x0f\x6b",
  5952. .ilen = 16,
  5953. .result = zeroed_string,
  5954. .rlen = 16,
  5955. }, {
  5956. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5957. "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
  5958. "\xba\xc7\x7a\x77\x17\x94\x28\x63",
  5959. .klen = 24,
  5960. .input = "\x1b\x38\x6c\x02\x10\xdc\xad\xcb"
  5961. "\xdd\x0e\x41\xaa\x08\xa7\xa7\xe8",
  5962. .ilen = 16,
  5963. .result = zeroed_string,
  5964. .rlen = 16,
  5965. }, {
  5966. .key = "\x23\x42\xbb\x9e\xfa\x38\x54\x2c"
  5967. "\xbe\xd0\xac\x83\x94\x0a\xc2\x98"
  5968. "\x8d\x7c\x47\xce\x26\x49\x08\x46"
  5969. "\x1c\xc1\xb5\x13\x7a\xe6\xb6\x04",
  5970. .klen = 32,
  5971. .input = "\x4f\x6a\x20\x38\x28\x68\x97\xb9"
  5972. "\xc9\x87\x01\x36\x55\x33\x17\xfa",
  5973. .ilen = 16,
  5974. .result = zeroed_string,
  5975. .rlen = 16,
  5976. },
  5977. };
  5978. /*
  5979. * AES test vectors.
  5980. */
  5981. #define AES_ENC_TEST_VECTORS 3
  5982. #define AES_DEC_TEST_VECTORS 3
  5983. #define AES_CBC_ENC_TEST_VECTORS 4
  5984. #define AES_CBC_DEC_TEST_VECTORS 4
  5985. #define AES_LRW_ENC_TEST_VECTORS 8
  5986. #define AES_LRW_DEC_TEST_VECTORS 8
  5987. #define AES_XTS_ENC_TEST_VECTORS 5
  5988. #define AES_XTS_DEC_TEST_VECTORS 5
  5989. #define AES_CTR_ENC_TEST_VECTORS 3
  5990. #define AES_CTR_DEC_TEST_VECTORS 3
  5991. #define AES_OFB_ENC_TEST_VECTORS 1
  5992. #define AES_OFB_DEC_TEST_VECTORS 1
  5993. #define AES_CTR_3686_ENC_TEST_VECTORS 7
  5994. #define AES_CTR_3686_DEC_TEST_VECTORS 6
  5995. #define AES_GCM_ENC_TEST_VECTORS 9
  5996. #define AES_GCM_DEC_TEST_VECTORS 8
  5997. #define AES_GCM_4106_ENC_TEST_VECTORS 7
  5998. #define AES_GCM_4106_DEC_TEST_VECTORS 7
  5999. #define AES_CCM_ENC_TEST_VECTORS 7
  6000. #define AES_CCM_DEC_TEST_VECTORS 7
  6001. #define AES_CCM_4309_ENC_TEST_VECTORS 7
  6002. #define AES_CCM_4309_DEC_TEST_VECTORS 10
  6003. static struct cipher_testvec aes_enc_tv_template[] = {
  6004. { /* From FIPS-197 */
  6005. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6006. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6007. .klen = 16,
  6008. .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6009. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6010. .ilen = 16,
  6011. .result = "\x69\xc4\xe0\xd8\x6a\x7b\x04\x30"
  6012. "\xd8\xcd\xb7\x80\x70\xb4\xc5\x5a",
  6013. .rlen = 16,
  6014. }, {
  6015. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6016. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6017. "\x10\x11\x12\x13\x14\x15\x16\x17",
  6018. .klen = 24,
  6019. .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6020. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6021. .ilen = 16,
  6022. .result = "\xdd\xa9\x7c\xa4\x86\x4c\xdf\xe0"
  6023. "\x6e\xaf\x70\xa0\xec\x0d\x71\x91",
  6024. .rlen = 16,
  6025. }, {
  6026. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6027. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6028. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6029. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  6030. .klen = 32,
  6031. .input = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6032. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6033. .ilen = 16,
  6034. .result = "\x8e\xa2\xb7\xca\x51\x67\x45\xbf"
  6035. "\xea\xfc\x49\x90\x4b\x49\x60\x89",
  6036. .rlen = 16,
  6037. },
  6038. };
  6039. static struct cipher_testvec aes_dec_tv_template[] = {
  6040. { /* From FIPS-197 */
  6041. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6042. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6043. .klen = 16,
  6044. .input = "\x69\xc4\xe0\xd8\x6a\x7b\x04\x30"
  6045. "\xd8\xcd\xb7\x80\x70\xb4\xc5\x5a",
  6046. .ilen = 16,
  6047. .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6048. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6049. .rlen = 16,
  6050. }, {
  6051. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6052. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6053. "\x10\x11\x12\x13\x14\x15\x16\x17",
  6054. .klen = 24,
  6055. .input = "\xdd\xa9\x7c\xa4\x86\x4c\xdf\xe0"
  6056. "\x6e\xaf\x70\xa0\xec\x0d\x71\x91",
  6057. .ilen = 16,
  6058. .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6059. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6060. .rlen = 16,
  6061. }, {
  6062. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6063. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6064. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6065. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  6066. .klen = 32,
  6067. .input = "\x8e\xa2\xb7\xca\x51\x67\x45\xbf"
  6068. "\xea\xfc\x49\x90\x4b\x49\x60\x89",
  6069. .ilen = 16,
  6070. .result = "\x00\x11\x22\x33\x44\x55\x66\x77"
  6071. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  6072. .rlen = 16,
  6073. },
  6074. };
  6075. static struct cipher_testvec aes_cbc_enc_tv_template[] = {
  6076. { /* From RFC 3602 */
  6077. .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
  6078. "\x51\x2e\x03\xd5\x34\x12\x00\x06",
  6079. .klen = 16,
  6080. .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
  6081. "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
  6082. .input = "Single block msg",
  6083. .ilen = 16,
  6084. .result = "\xe3\x53\x77\x9c\x10\x79\xae\xb8"
  6085. "\x27\x08\x94\x2d\xbe\x77\x18\x1a",
  6086. .rlen = 16,
  6087. }, {
  6088. .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
  6089. "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
  6090. .klen = 16,
  6091. .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
  6092. "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
  6093. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6094. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6095. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6096. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  6097. .ilen = 32,
  6098. .result = "\xd2\x96\xcd\x94\xc2\xcc\xcf\x8a"
  6099. "\x3a\x86\x30\x28\xb5\xe1\xdc\x0a"
  6100. "\x75\x86\x60\x2d\x25\x3c\xff\xf9"
  6101. "\x1b\x82\x66\xbe\xa6\xd6\x1a\xb1",
  6102. .rlen = 32,
  6103. }, { /* From NIST SP800-38A */
  6104. .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
  6105. "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
  6106. "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
  6107. .klen = 24,
  6108. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6109. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6110. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  6111. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  6112. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  6113. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  6114. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  6115. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  6116. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  6117. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  6118. .ilen = 64,
  6119. .result = "\x4f\x02\x1d\xb2\x43\xbc\x63\x3d"
  6120. "\x71\x78\x18\x3a\x9f\xa0\x71\xe8"
  6121. "\xb4\xd9\xad\xa9\xad\x7d\xed\xf4"
  6122. "\xe5\xe7\x38\x76\x3f\x69\x14\x5a"
  6123. "\x57\x1b\x24\x20\x12\xfb\x7a\xe0"
  6124. "\x7f\xa9\xba\xac\x3d\xf1\x02\xe0"
  6125. "\x08\xb0\xe2\x79\x88\x59\x88\x81"
  6126. "\xd9\x20\xa9\xe6\x4f\x56\x15\xcd",
  6127. .rlen = 64,
  6128. }, {
  6129. .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
  6130. "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
  6131. "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
  6132. "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
  6133. .klen = 32,
  6134. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6135. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6136. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  6137. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  6138. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  6139. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  6140. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  6141. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  6142. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  6143. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  6144. .ilen = 64,
  6145. .result = "\xf5\x8c\x4c\x04\xd6\xe5\xf1\xba"
  6146. "\x77\x9e\xab\xfb\x5f\x7b\xfb\xd6"
  6147. "\x9c\xfc\x4e\x96\x7e\xdb\x80\x8d"
  6148. "\x67\x9f\x77\x7b\xc6\x70\x2c\x7d"
  6149. "\x39\xf2\x33\x69\xa9\xd9\xba\xcf"
  6150. "\xa5\x30\xe2\x63\x04\x23\x14\x61"
  6151. "\xb2\xeb\x05\xe2\xc3\x9b\xe9\xfc"
  6152. "\xda\x6c\x19\x07\x8c\x6a\x9d\x1b",
  6153. .rlen = 64,
  6154. },
  6155. };
  6156. static struct cipher_testvec aes_cbc_dec_tv_template[] = {
  6157. { /* From RFC 3602 */
  6158. .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
  6159. "\x51\x2e\x03\xd5\x34\x12\x00\x06",
  6160. .klen = 16,
  6161. .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
  6162. "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
  6163. .input = "\xe3\x53\x77\x9c\x10\x79\xae\xb8"
  6164. "\x27\x08\x94\x2d\xbe\x77\x18\x1a",
  6165. .ilen = 16,
  6166. .result = "Single block msg",
  6167. .rlen = 16,
  6168. }, {
  6169. .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
  6170. "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
  6171. .klen = 16,
  6172. .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
  6173. "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
  6174. .input = "\xd2\x96\xcd\x94\xc2\xcc\xcf\x8a"
  6175. "\x3a\x86\x30\x28\xb5\xe1\xdc\x0a"
  6176. "\x75\x86\x60\x2d\x25\x3c\xff\xf9"
  6177. "\x1b\x82\x66\xbe\xa6\xd6\x1a\xb1",
  6178. .ilen = 32,
  6179. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6180. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6181. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6182. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  6183. .rlen = 32,
  6184. }, { /* From NIST SP800-38A */
  6185. .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
  6186. "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
  6187. "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
  6188. .klen = 24,
  6189. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6190. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6191. .input = "\x4f\x02\x1d\xb2\x43\xbc\x63\x3d"
  6192. "\x71\x78\x18\x3a\x9f\xa0\x71\xe8"
  6193. "\xb4\xd9\xad\xa9\xad\x7d\xed\xf4"
  6194. "\xe5\xe7\x38\x76\x3f\x69\x14\x5a"
  6195. "\x57\x1b\x24\x20\x12\xfb\x7a\xe0"
  6196. "\x7f\xa9\xba\xac\x3d\xf1\x02\xe0"
  6197. "\x08\xb0\xe2\x79\x88\x59\x88\x81"
  6198. "\xd9\x20\xa9\xe6\x4f\x56\x15\xcd",
  6199. .ilen = 64,
  6200. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  6201. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  6202. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  6203. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  6204. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  6205. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  6206. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  6207. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  6208. .rlen = 64,
  6209. }, {
  6210. .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
  6211. "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
  6212. "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
  6213. "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
  6214. .klen = 32,
  6215. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6216. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  6217. .input = "\xf5\x8c\x4c\x04\xd6\xe5\xf1\xba"
  6218. "\x77\x9e\xab\xfb\x5f\x7b\xfb\xd6"
  6219. "\x9c\xfc\x4e\x96\x7e\xdb\x80\x8d"
  6220. "\x67\x9f\x77\x7b\xc6\x70\x2c\x7d"
  6221. "\x39\xf2\x33\x69\xa9\xd9\xba\xcf"
  6222. "\xa5\x30\xe2\x63\x04\x23\x14\x61"
  6223. "\xb2\xeb\x05\xe2\xc3\x9b\xe9\xfc"
  6224. "\xda\x6c\x19\x07\x8c\x6a\x9d\x1b",
  6225. .ilen = 64,
  6226. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  6227. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  6228. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  6229. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  6230. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  6231. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  6232. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  6233. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  6234. .rlen = 64,
  6235. },
  6236. };
  6237. static struct cipher_testvec aes_lrw_enc_tv_template[] = {
  6238. /* from http://grouper.ieee.org/groups/1619/email/pdf00017.pdf */
  6239. { /* LRW-32-AES 1 */
  6240. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  6241. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  6242. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  6243. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  6244. .klen = 32,
  6245. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6246. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6247. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6248. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6249. .ilen = 16,
  6250. .result = "\xf1\xb2\x73\xcd\x65\xa3\xdf\x5f"
  6251. "\xe9\x5d\x48\x92\x54\x63\x4e\xb8",
  6252. .rlen = 16,
  6253. }, { /* LRW-32-AES 2 */
  6254. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  6255. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  6256. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  6257. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  6258. .klen = 32,
  6259. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6260. "\x00\x00\x00\x00\x00\x00\x00\x02",
  6261. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6262. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6263. .ilen = 16,
  6264. .result = "\x00\xc8\x2b\xae\x95\xbb\xcd\xe5"
  6265. "\x27\x4f\x07\x69\xb2\x60\xe1\x36",
  6266. .rlen = 16,
  6267. }, { /* LRW-32-AES 3 */
  6268. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  6269. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  6270. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  6271. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  6272. .klen = 32,
  6273. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6274. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6275. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6276. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6277. .ilen = 16,
  6278. .result = "\x76\x32\x21\x83\xed\x8f\xf1\x82"
  6279. "\xf9\x59\x62\x03\x69\x0e\x5e\x01",
  6280. .rlen = 16,
  6281. }, { /* LRW-32-AES 4 */
  6282. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  6283. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  6284. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  6285. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  6286. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  6287. .klen = 40,
  6288. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6289. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6290. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6291. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6292. .ilen = 16,
  6293. .result = "\x9c\x0f\x15\x2f\x55\xa2\xd8\xf0"
  6294. "\xd6\x7b\x8f\x9e\x28\x22\xbc\x41",
  6295. .rlen = 16,
  6296. }, { /* LRW-32-AES 5 */
  6297. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  6298. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  6299. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  6300. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  6301. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  6302. .klen = 40,
  6303. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6304. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6305. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6306. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6307. .ilen = 16,
  6308. .result = "\xd4\x27\x6a\x7f\x14\x91\x3d\x65"
  6309. "\xc8\x60\x48\x02\x87\xe3\x34\x06",
  6310. .rlen = 16,
  6311. }, { /* LRW-32-AES 6 */
  6312. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  6313. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  6314. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  6315. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  6316. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  6317. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  6318. .klen = 48,
  6319. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6320. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6321. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6322. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6323. .ilen = 16,
  6324. .result = "\xbd\x06\xb8\xe1\xdb\x98\x89\x9e"
  6325. "\xc4\x98\xe4\x91\xcf\x1c\x70\x2b",
  6326. .rlen = 16,
  6327. }, { /* LRW-32-AES 7 */
  6328. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  6329. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  6330. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  6331. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  6332. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  6333. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  6334. .klen = 48,
  6335. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6336. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6337. .input = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6338. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6339. .ilen = 16,
  6340. .result = "\x5b\x90\x8e\xc1\xab\xdd\x67\x5f"
  6341. "\x3d\x69\x8a\x95\x53\xc8\x9c\xe5",
  6342. .rlen = 16,
  6343. }, {
  6344. /* http://www.mail-archive.com/stds-p1619@listserv.ieee.org/msg00173.html */
  6345. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  6346. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  6347. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  6348. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  6349. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  6350. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  6351. .klen = 48,
  6352. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6353. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6354. .input = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  6355. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  6356. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  6357. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  6358. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  6359. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  6360. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  6361. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  6362. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  6363. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  6364. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  6365. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  6366. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  6367. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  6368. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  6369. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  6370. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  6371. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  6372. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  6373. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  6374. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  6375. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  6376. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  6377. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  6378. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  6379. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  6380. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  6381. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  6382. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  6383. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  6384. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  6385. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  6386. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  6387. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  6388. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  6389. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  6390. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  6391. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  6392. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  6393. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  6394. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  6395. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  6396. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  6397. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  6398. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  6399. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  6400. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  6401. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  6402. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  6403. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  6404. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  6405. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  6406. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  6407. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  6408. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  6409. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  6410. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  6411. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  6412. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  6413. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  6414. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  6415. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  6416. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  6417. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  6418. .ilen = 512,
  6419. .result = "\x1a\x1d\xa9\x30\xad\xf9\x2f\x9b"
  6420. "\xb6\x1d\xae\xef\xf0\x2f\xf8\x5a"
  6421. "\x39\x3c\xbf\x2a\xb2\x45\xb2\x23"
  6422. "\x1b\x63\x3c\xcf\xaa\xbe\xcf\x4e"
  6423. "\xfa\xe8\x29\xc2\x20\x68\x2b\x3c"
  6424. "\x2e\x8b\xf7\x6e\x25\xbd\xe3\x3d"
  6425. "\x66\x27\xd6\xaf\xd6\x64\x3e\xe3"
  6426. "\xe8\x58\x46\x97\x39\x51\x07\xde"
  6427. "\xcb\x37\xbc\xa9\xc0\x5f\x75\xc3"
  6428. "\x0e\x84\x23\x1d\x16\xd4\x1c\x59"
  6429. "\x9c\x1a\x02\x55\xab\x3a\x97\x1d"
  6430. "\xdf\xdd\xc7\x06\x51\xd7\x70\xae"
  6431. "\x23\xc6\x8c\xf5\x1e\xa0\xe5\x82"
  6432. "\xb8\xb2\xbf\x04\xa0\x32\x8e\x68"
  6433. "\xeb\xaf\x6e\x2d\x94\x22\x2f\xce"
  6434. "\x4c\xb5\x59\xe2\xa2\x2f\xa0\x98"
  6435. "\x1a\x97\xc6\xd4\xb5\x00\x59\xf2"
  6436. "\x84\x14\x72\xb1\x9a\x6e\xa3\x7f"
  6437. "\xea\x20\xe7\xcb\x65\x77\x3a\xdf"
  6438. "\xc8\x97\x67\x15\xc2\x2a\x27\xcc"
  6439. "\x18\x55\xa1\x24\x0b\x24\x24\xaf"
  6440. "\x5b\xec\x68\xb8\xc8\xf5\xba\x63"
  6441. "\xff\xed\x89\xce\xd5\x3d\x88\xf3"
  6442. "\x25\xef\x05\x7c\x3a\xef\xeb\xd8"
  6443. "\x7a\x32\x0d\xd1\x1e\x58\x59\x99"
  6444. "\x90\x25\xb5\x26\xb0\xe3\x2b\x6c"
  6445. "\x4c\xa9\x8b\x84\x4f\x5e\x01\x50"
  6446. "\x41\x30\x58\xc5\x62\x74\x52\x1d"
  6447. "\x45\x24\x6a\x42\x64\x4f\x97\x1c"
  6448. "\xa8\x66\xb5\x6d\x79\xd4\x0d\x48"
  6449. "\xc5\x5f\xf3\x90\x32\xdd\xdd\xe1"
  6450. "\xe4\xa9\x9f\xfc\xc3\x52\x5a\x46"
  6451. "\xe4\x81\x84\x95\x36\x59\x7a\x6b"
  6452. "\xaa\xb3\x60\xad\xce\x9f\x9f\x28"
  6453. "\xe0\x01\x75\x22\xc4\x4e\xa9\x62"
  6454. "\x5c\x62\x0d\x00\xcb\x13\xe8\x43"
  6455. "\x72\xd4\x2d\x53\x46\xb5\xd1\x16"
  6456. "\x22\x18\xdf\x34\x33\xf5\xd6\x1c"
  6457. "\xb8\x79\x78\x97\x94\xff\x72\x13"
  6458. "\x4c\x27\xfc\xcb\xbf\x01\x53\xa6"
  6459. "\xb4\x50\x6e\xde\xdf\xb5\x43\xa4"
  6460. "\x59\xdf\x52\xf9\x7c\xe0\x11\x6f"
  6461. "\x2d\x14\x8e\x24\x61\x2c\xe1\x17"
  6462. "\xcc\xce\x51\x0c\x19\x8a\x82\x30"
  6463. "\x94\xd5\x3d\x6a\x53\x06\x5e\xbd"
  6464. "\xb7\xeb\xfa\xfd\x27\x51\xde\x85"
  6465. "\x1e\x86\x53\x11\x53\x94\x00\xee"
  6466. "\x2b\x8c\x08\x2a\xbf\xdd\xae\x11"
  6467. "\xcb\x1e\xa2\x07\x9a\x80\xcf\x62"
  6468. "\x9b\x09\xdc\x95\x3c\x96\x8e\xb1"
  6469. "\x09\xbd\xe4\xeb\xdb\xca\x70\x7a"
  6470. "\x9e\xfa\x31\x18\x45\x3c\x21\x33"
  6471. "\xb0\xb3\x2b\xea\xf3\x71\x2d\xe1"
  6472. "\x03\xad\x1b\x48\xd4\x67\x27\xf0"
  6473. "\x62\xe4\x3d\xfb\x9b\x08\x76\xe7"
  6474. "\xdd\x2b\x01\x39\x04\x5a\x58\x7a"
  6475. "\xf7\x11\x90\xec\xbd\x51\x5c\x32"
  6476. "\x6b\xd7\x35\x39\x02\x6b\xf2\xa6"
  6477. "\xd0\x0d\x07\xe1\x06\xc4\x5b\x7d"
  6478. "\xe4\x6a\xd7\xee\x15\x1f\x83\xb4"
  6479. "\xa3\xa7\x5e\xc3\x90\xb7\xef\xd3"
  6480. "\xb7\x4f\xf8\x92\x4c\xb7\x3c\x29"
  6481. "\xcd\x7e\x2b\x5d\x43\xea\x42\xe7"
  6482. "\x74\x3f\x7d\x58\x88\x75\xde\x3e",
  6483. .rlen = 512,
  6484. }
  6485. };
  6486. static struct cipher_testvec aes_lrw_dec_tv_template[] = {
  6487. /* from http://grouper.ieee.org/groups/1619/email/pdf00017.pdf */
  6488. /* same as enc vectors with input and result reversed */
  6489. { /* LRW-32-AES 1 */
  6490. .key = "\x45\x62\xac\x25\xf8\x28\x17\x6d"
  6491. "\x4c\x26\x84\x14\xb5\x68\x01\x85"
  6492. "\x25\x8e\x2a\x05\xe7\x3e\x9d\x03"
  6493. "\xee\x5a\x83\x0c\xcc\x09\x4c\x87",
  6494. .klen = 32,
  6495. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6496. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6497. .input = "\xf1\xb2\x73\xcd\x65\xa3\xdf\x5f"
  6498. "\xe9\x5d\x48\x92\x54\x63\x4e\xb8",
  6499. .ilen = 16,
  6500. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6501. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6502. .rlen = 16,
  6503. }, { /* LRW-32-AES 2 */
  6504. .key = "\x59\x70\x47\x14\xf5\x57\x47\x8c"
  6505. "\xd7\x79\xe8\x0f\x54\x88\x79\x44"
  6506. "\x0d\x48\xf0\xb7\xb1\x5a\x53\xea"
  6507. "\x1c\xaa\x6b\x29\xc2\xca\xfb\xaf",
  6508. .klen = 32,
  6509. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6510. "\x00\x00\x00\x00\x00\x00\x00\x02",
  6511. .input = "\x00\xc8\x2b\xae\x95\xbb\xcd\xe5"
  6512. "\x27\x4f\x07\x69\xb2\x60\xe1\x36",
  6513. .ilen = 16,
  6514. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6515. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6516. .rlen = 16,
  6517. }, { /* LRW-32-AES 3 */
  6518. .key = "\xd8\x2a\x91\x34\xb2\x6a\x56\x50"
  6519. "\x30\xfe\x69\xe2\x37\x7f\x98\x47"
  6520. "\xcd\xf9\x0b\x16\x0c\x64\x8f\xb6"
  6521. "\xb0\x0d\x0d\x1b\xae\x85\x87\x1f",
  6522. .klen = 32,
  6523. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6524. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6525. .input = "\x76\x32\x21\x83\xed\x8f\xf1\x82"
  6526. "\xf9\x59\x62\x03\x69\x0e\x5e\x01",
  6527. .ilen = 16,
  6528. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6529. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6530. .rlen = 16,
  6531. }, { /* LRW-32-AES 4 */
  6532. .key = "\x0f\x6a\xef\xf8\xd3\xd2\xbb\x15"
  6533. "\x25\x83\xf7\x3c\x1f\x01\x28\x74"
  6534. "\xca\xc6\xbc\x35\x4d\x4a\x65\x54"
  6535. "\x90\xae\x61\xcf\x7b\xae\xbd\xcc"
  6536. "\xad\xe4\x94\xc5\x4a\x29\xae\x70",
  6537. .klen = 40,
  6538. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6539. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6540. .input = "\x9c\x0f\x15\x2f\x55\xa2\xd8\xf0"
  6541. "\xd6\x7b\x8f\x9e\x28\x22\xbc\x41",
  6542. .ilen = 16,
  6543. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6544. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6545. .rlen = 16,
  6546. }, { /* LRW-32-AES 5 */
  6547. .key = "\x8a\xd4\xee\x10\x2f\xbd\x81\xff"
  6548. "\xf8\x86\xce\xac\x93\xc5\xad\xc6"
  6549. "\xa0\x19\x07\xc0\x9d\xf7\xbb\xdd"
  6550. "\x52\x13\xb2\xb7\xf0\xff\x11\xd8"
  6551. "\xd6\x08\xd0\xcd\x2e\xb1\x17\x6f",
  6552. .klen = 40,
  6553. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6554. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6555. .input = "\xd4\x27\x6a\x7f\x14\x91\x3d\x65"
  6556. "\xc8\x60\x48\x02\x87\xe3\x34\x06",
  6557. .ilen = 16,
  6558. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6559. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6560. .rlen = 16,
  6561. }, { /* LRW-32-AES 6 */
  6562. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  6563. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  6564. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  6565. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  6566. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  6567. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  6568. .klen = 48,
  6569. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6570. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6571. .input = "\xbd\x06\xb8\xe1\xdb\x98\x89\x9e"
  6572. "\xc4\x98\xe4\x91\xcf\x1c\x70\x2b",
  6573. .ilen = 16,
  6574. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6575. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6576. .rlen = 16,
  6577. }, { /* LRW-32-AES 7 */
  6578. .key = "\xfb\x76\x15\xb2\x3d\x80\x89\x1d"
  6579. "\xd4\x70\x98\x0b\xc7\x95\x84\xc8"
  6580. "\xb2\xfb\x64\xce\x60\x97\x87\x8d"
  6581. "\x17\xfc\xe4\x5a\x49\xe8\x30\xb7"
  6582. "\x6e\x78\x17\xe7\x2d\x5e\x12\xd4"
  6583. "\x60\x64\x04\x7a\xf1\x2f\x9e\x0c",
  6584. .klen = 48,
  6585. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6586. "\x00\x00\x00\x02\x00\x00\x00\x00",
  6587. .input = "\x5b\x90\x8e\xc1\xab\xdd\x67\x5f"
  6588. "\x3d\x69\x8a\x95\x53\xc8\x9c\xe5",
  6589. .ilen = 16,
  6590. .result = "\x30\x31\x32\x33\x34\x35\x36\x37"
  6591. "\x38\x39\x41\x42\x43\x44\x45\x46",
  6592. .rlen = 16,
  6593. }, {
  6594. /* http://www.mail-archive.com/stds-p1619@listserv.ieee.org/msg00173.html */
  6595. .key = "\xf8\xd4\x76\xff\xd6\x46\xee\x6c"
  6596. "\x23\x84\xcb\x1c\x77\xd6\x19\x5d"
  6597. "\xfe\xf1\xa9\xf3\x7b\xbc\x8d\x21"
  6598. "\xa7\x9c\x21\xf8\xcb\x90\x02\x89"
  6599. "\xa8\x45\x34\x8e\xc8\xc5\xb5\xf1"
  6600. "\x26\xf5\x0e\x76\xfe\xfd\x1b\x1e",
  6601. .klen = 48,
  6602. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6603. "\x00\x00\x00\x00\x00\x00\x00\x01",
  6604. .input = "\x1a\x1d\xa9\x30\xad\xf9\x2f\x9b"
  6605. "\xb6\x1d\xae\xef\xf0\x2f\xf8\x5a"
  6606. "\x39\x3c\xbf\x2a\xb2\x45\xb2\x23"
  6607. "\x1b\x63\x3c\xcf\xaa\xbe\xcf\x4e"
  6608. "\xfa\xe8\x29\xc2\x20\x68\x2b\x3c"
  6609. "\x2e\x8b\xf7\x6e\x25\xbd\xe3\x3d"
  6610. "\x66\x27\xd6\xaf\xd6\x64\x3e\xe3"
  6611. "\xe8\x58\x46\x97\x39\x51\x07\xde"
  6612. "\xcb\x37\xbc\xa9\xc0\x5f\x75\xc3"
  6613. "\x0e\x84\x23\x1d\x16\xd4\x1c\x59"
  6614. "\x9c\x1a\x02\x55\xab\x3a\x97\x1d"
  6615. "\xdf\xdd\xc7\x06\x51\xd7\x70\xae"
  6616. "\x23\xc6\x8c\xf5\x1e\xa0\xe5\x82"
  6617. "\xb8\xb2\xbf\x04\xa0\x32\x8e\x68"
  6618. "\xeb\xaf\x6e\x2d\x94\x22\x2f\xce"
  6619. "\x4c\xb5\x59\xe2\xa2\x2f\xa0\x98"
  6620. "\x1a\x97\xc6\xd4\xb5\x00\x59\xf2"
  6621. "\x84\x14\x72\xb1\x9a\x6e\xa3\x7f"
  6622. "\xea\x20\xe7\xcb\x65\x77\x3a\xdf"
  6623. "\xc8\x97\x67\x15\xc2\x2a\x27\xcc"
  6624. "\x18\x55\xa1\x24\x0b\x24\x24\xaf"
  6625. "\x5b\xec\x68\xb8\xc8\xf5\xba\x63"
  6626. "\xff\xed\x89\xce\xd5\x3d\x88\xf3"
  6627. "\x25\xef\x05\x7c\x3a\xef\xeb\xd8"
  6628. "\x7a\x32\x0d\xd1\x1e\x58\x59\x99"
  6629. "\x90\x25\xb5\x26\xb0\xe3\x2b\x6c"
  6630. "\x4c\xa9\x8b\x84\x4f\x5e\x01\x50"
  6631. "\x41\x30\x58\xc5\x62\x74\x52\x1d"
  6632. "\x45\x24\x6a\x42\x64\x4f\x97\x1c"
  6633. "\xa8\x66\xb5\x6d\x79\xd4\x0d\x48"
  6634. "\xc5\x5f\xf3\x90\x32\xdd\xdd\xe1"
  6635. "\xe4\xa9\x9f\xfc\xc3\x52\x5a\x46"
  6636. "\xe4\x81\x84\x95\x36\x59\x7a\x6b"
  6637. "\xaa\xb3\x60\xad\xce\x9f\x9f\x28"
  6638. "\xe0\x01\x75\x22\xc4\x4e\xa9\x62"
  6639. "\x5c\x62\x0d\x00\xcb\x13\xe8\x43"
  6640. "\x72\xd4\x2d\x53\x46\xb5\xd1\x16"
  6641. "\x22\x18\xdf\x34\x33\xf5\xd6\x1c"
  6642. "\xb8\x79\x78\x97\x94\xff\x72\x13"
  6643. "\x4c\x27\xfc\xcb\xbf\x01\x53\xa6"
  6644. "\xb4\x50\x6e\xde\xdf\xb5\x43\xa4"
  6645. "\x59\xdf\x52\xf9\x7c\xe0\x11\x6f"
  6646. "\x2d\x14\x8e\x24\x61\x2c\xe1\x17"
  6647. "\xcc\xce\x51\x0c\x19\x8a\x82\x30"
  6648. "\x94\xd5\x3d\x6a\x53\x06\x5e\xbd"
  6649. "\xb7\xeb\xfa\xfd\x27\x51\xde\x85"
  6650. "\x1e\x86\x53\x11\x53\x94\x00\xee"
  6651. "\x2b\x8c\x08\x2a\xbf\xdd\xae\x11"
  6652. "\xcb\x1e\xa2\x07\x9a\x80\xcf\x62"
  6653. "\x9b\x09\xdc\x95\x3c\x96\x8e\xb1"
  6654. "\x09\xbd\xe4\xeb\xdb\xca\x70\x7a"
  6655. "\x9e\xfa\x31\x18\x45\x3c\x21\x33"
  6656. "\xb0\xb3\x2b\xea\xf3\x71\x2d\xe1"
  6657. "\x03\xad\x1b\x48\xd4\x67\x27\xf0"
  6658. "\x62\xe4\x3d\xfb\x9b\x08\x76\xe7"
  6659. "\xdd\x2b\x01\x39\x04\x5a\x58\x7a"
  6660. "\xf7\x11\x90\xec\xbd\x51\x5c\x32"
  6661. "\x6b\xd7\x35\x39\x02\x6b\xf2\xa6"
  6662. "\xd0\x0d\x07\xe1\x06\xc4\x5b\x7d"
  6663. "\xe4\x6a\xd7\xee\x15\x1f\x83\xb4"
  6664. "\xa3\xa7\x5e\xc3\x90\xb7\xef\xd3"
  6665. "\xb7\x4f\xf8\x92\x4c\xb7\x3c\x29"
  6666. "\xcd\x7e\x2b\x5d\x43\xea\x42\xe7"
  6667. "\x74\x3f\x7d\x58\x88\x75\xde\x3e",
  6668. .ilen = 512,
  6669. .result = "\x05\x11\xb7\x18\xab\xc6\x2d\xac"
  6670. "\x70\x5d\xf6\x22\x94\xcd\xe5\x6c"
  6671. "\x17\x6b\xf6\x1c\xf0\xf3\x6e\xf8"
  6672. "\x50\x38\x1f\x71\x49\xb6\x57\xd6"
  6673. "\x8f\xcb\x8d\x6b\xe3\xa6\x29\x90"
  6674. "\xfe\x2a\x62\x82\xae\x6d\x8b\xf6"
  6675. "\xad\x1e\x9e\x20\x5f\x38\xbe\x04"
  6676. "\xda\x10\x8e\xed\xa2\xa4\x87\xab"
  6677. "\xda\x6b\xb4\x0c\x75\xba\xd3\x7c"
  6678. "\xc9\xac\x42\x31\x95\x7c\xc9\x04"
  6679. "\xeb\xd5\x6e\x32\x69\x8a\xdb\xa6"
  6680. "\x15\xd7\x3f\x4f\x2f\x66\x69\x03"
  6681. "\x9c\x1f\x54\x0f\xde\x1f\xf3\x65"
  6682. "\x4c\x96\x12\xed\x7c\x92\x03\x01"
  6683. "\x6f\xbc\x35\x93\xac\xf1\x27\xf1"
  6684. "\xb4\x96\x82\x5a\x5f\xb0\xa0\x50"
  6685. "\x89\xa4\x8e\x66\x44\x85\xcc\xfd"
  6686. "\x33\x14\x70\xe3\x96\xb2\xc3\xd3"
  6687. "\xbb\x54\x5a\x1a\xf9\x74\xa2\xc5"
  6688. "\x2d\x64\x75\xdd\xb4\x54\xe6\x74"
  6689. "\x8c\xd3\x9d\x9e\x86\xab\x51\x53"
  6690. "\xb7\x93\x3e\x6f\xd0\x4e\x2c\x40"
  6691. "\xf6\xa8\x2e\x3e\x9d\xf4\x66\xa5"
  6692. "\x76\x12\x73\x44\x1a\x56\xd7\x72"
  6693. "\x88\xcd\x21\x8c\x4c\x0f\xfe\xda"
  6694. "\x95\xe0\x3a\xa6\xa5\x84\x46\xcd"
  6695. "\xd5\x3e\x9d\x3a\xe2\x67\xe6\x60"
  6696. "\x1a\xe2\x70\x85\x58\xc2\x1b\x09"
  6697. "\xe1\xd7\x2c\xca\xad\xa8\x8f\xf9"
  6698. "\xac\xb3\x0e\xdb\xca\x2e\xe2\xb8"
  6699. "\x51\x71\xd9\x3c\x6c\xf1\x56\xf8"
  6700. "\xea\x9c\xf1\xfb\x0c\xe6\xb7\x10"
  6701. "\x1c\xf8\xa9\x7c\xe8\x53\x35\xc1"
  6702. "\x90\x3e\x76\x4a\x74\xa4\x21\x2c"
  6703. "\xf6\x2c\x4e\x0f\x94\x3a\x88\x2e"
  6704. "\x41\x09\x6a\x33\x7d\xf6\xdd\x3f"
  6705. "\x8d\x23\x31\x74\x84\xeb\x88\x6e"
  6706. "\xcc\xb9\xbc\x22\x83\x19\x07\x22"
  6707. "\xa5\x2d\xdf\xa5\xf3\x80\x85\x78"
  6708. "\x84\x39\x6a\x6d\x6a\x99\x4f\xa5"
  6709. "\x15\xfe\x46\xb0\xe4\x6c\xa5\x41"
  6710. "\x3c\xce\x8f\x42\x60\x71\xa7\x75"
  6711. "\x08\x40\x65\x8a\x82\xbf\xf5\x43"
  6712. "\x71\x96\xa9\x4d\x44\x8a\x20\xbe"
  6713. "\xfa\x4d\xbb\xc0\x7d\x31\x96\x65"
  6714. "\xe7\x75\xe5\x3e\xfd\x92\x3b\xc9"
  6715. "\x55\xbb\x16\x7e\xf7\xc2\x8c\xa4"
  6716. "\x40\x1d\xe5\xef\x0e\xdf\xe4\x9a"
  6717. "\x62\x73\x65\xfd\x46\x63\x25\x3d"
  6718. "\x2b\xaf\xe5\x64\xfe\xa5\x5c\xcf"
  6719. "\x24\xf3\xb4\xac\x64\xba\xdf\x4b"
  6720. "\xc6\x96\x7d\x81\x2d\x8d\x97\xf7"
  6721. "\xc5\x68\x77\x84\x32\x2b\xcc\x85"
  6722. "\x74\x96\xf0\x12\x77\x61\xb9\xeb"
  6723. "\x71\xaa\x82\xcb\x1c\xdb\x89\xc8"
  6724. "\xc6\xb5\xe3\x5c\x7d\x39\x07\x24"
  6725. "\xda\x39\x87\x45\xc0\x2b\xbb\x01"
  6726. "\xac\xbc\x2a\x5c\x7f\xfc\xe8\xce"
  6727. "\x6d\x9c\x6f\xed\xd3\xc1\xa1\xd6"
  6728. "\xc5\x55\xa9\x66\x2f\xe1\xc8\x32"
  6729. "\xa6\x5d\xa4\x3a\x98\x73\xe8\x45"
  6730. "\xa4\xc7\xa8\xb4\xf6\x13\x03\xf6"
  6731. "\xe9\x2e\xc4\x29\x0f\x84\xdb\xc4"
  6732. "\x21\xc4\xc2\x75\x67\x89\x37\x0a",
  6733. .rlen = 512,
  6734. }
  6735. };
  6736. static struct cipher_testvec aes_xts_enc_tv_template[] = {
  6737. /* http://grouper.ieee.org/groups/1619/email/pdf00086.pdf */
  6738. { /* XTS-AES 1 */
  6739. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6740. "\x00\x00\x00\x00\x00\x00\x00\x00"
  6741. "\x00\x00\x00\x00\x00\x00\x00\x00"
  6742. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6743. .klen = 32,
  6744. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6745. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6746. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6747. "\x00\x00\x00\x00\x00\x00\x00\x00"
  6748. "\x00\x00\x00\x00\x00\x00\x00\x00"
  6749. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6750. .ilen = 32,
  6751. .result = "\x91\x7c\xf6\x9e\xbd\x68\xb2\xec"
  6752. "\x9b\x9f\xe9\xa3\xea\xdd\xa6\x92"
  6753. "\xcd\x43\xd2\xf5\x95\x98\xed\x85"
  6754. "\x8c\x02\xc2\x65\x2f\xbf\x92\x2e",
  6755. .rlen = 32,
  6756. }, { /* XTS-AES 2 */
  6757. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  6758. "\x11\x11\x11\x11\x11\x11\x11\x11"
  6759. "\x22\x22\x22\x22\x22\x22\x22\x22"
  6760. "\x22\x22\x22\x22\x22\x22\x22\x22",
  6761. .klen = 32,
  6762. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  6763. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6764. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  6765. "\x44\x44\x44\x44\x44\x44\x44\x44"
  6766. "\x44\x44\x44\x44\x44\x44\x44\x44"
  6767. "\x44\x44\x44\x44\x44\x44\x44\x44",
  6768. .ilen = 32,
  6769. .result = "\xc4\x54\x18\x5e\x6a\x16\x93\x6e"
  6770. "\x39\x33\x40\x38\xac\xef\x83\x8b"
  6771. "\xfb\x18\x6f\xff\x74\x80\xad\xc4"
  6772. "\x28\x93\x82\xec\xd6\xd3\x94\xf0",
  6773. .rlen = 32,
  6774. }, { /* XTS-AES 3 */
  6775. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  6776. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  6777. "\x22\x22\x22\x22\x22\x22\x22\x22"
  6778. "\x22\x22\x22\x22\x22\x22\x22\x22",
  6779. .klen = 32,
  6780. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  6781. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6782. .input = "\x44\x44\x44\x44\x44\x44\x44\x44"
  6783. "\x44\x44\x44\x44\x44\x44\x44\x44"
  6784. "\x44\x44\x44\x44\x44\x44\x44\x44"
  6785. "\x44\x44\x44\x44\x44\x44\x44\x44",
  6786. .ilen = 32,
  6787. .result = "\xaf\x85\x33\x6b\x59\x7a\xfc\x1a"
  6788. "\x90\x0b\x2e\xb2\x1e\xc9\x49\xd2"
  6789. "\x92\xdf\x4c\x04\x7e\x0b\x21\x53"
  6790. "\x21\x86\xa5\x97\x1a\x22\x7a\x89",
  6791. .rlen = 32,
  6792. }, { /* XTS-AES 4 */
  6793. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  6794. "\x23\x53\x60\x28\x74\x71\x35\x26"
  6795. "\x31\x41\x59\x26\x53\x58\x97\x93"
  6796. "\x23\x84\x62\x64\x33\x83\x27\x95",
  6797. .klen = 32,
  6798. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  6799. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6800. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6801. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6802. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6803. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  6804. "\x20\x21\x22\x23\x24\x25\x26\x27"
  6805. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  6806. "\x30\x31\x32\x33\x34\x35\x36\x37"
  6807. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  6808. "\x40\x41\x42\x43\x44\x45\x46\x47"
  6809. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  6810. "\x50\x51\x52\x53\x54\x55\x56\x57"
  6811. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  6812. "\x60\x61\x62\x63\x64\x65\x66\x67"
  6813. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  6814. "\x70\x71\x72\x73\x74\x75\x76\x77"
  6815. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  6816. "\x80\x81\x82\x83\x84\x85\x86\x87"
  6817. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  6818. "\x90\x91\x92\x93\x94\x95\x96\x97"
  6819. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  6820. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  6821. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  6822. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  6823. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  6824. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  6825. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  6826. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  6827. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  6828. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  6829. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  6830. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  6831. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  6832. "\x00\x01\x02\x03\x04\x05\x06\x07"
  6833. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6834. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6835. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  6836. "\x20\x21\x22\x23\x24\x25\x26\x27"
  6837. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  6838. "\x30\x31\x32\x33\x34\x35\x36\x37"
  6839. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  6840. "\x40\x41\x42\x43\x44\x45\x46\x47"
  6841. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  6842. "\x50\x51\x52\x53\x54\x55\x56\x57"
  6843. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  6844. "\x60\x61\x62\x63\x64\x65\x66\x67"
  6845. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  6846. "\x70\x71\x72\x73\x74\x75\x76\x77"
  6847. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  6848. "\x80\x81\x82\x83\x84\x85\x86\x87"
  6849. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  6850. "\x90\x91\x92\x93\x94\x95\x96\x97"
  6851. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  6852. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  6853. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  6854. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  6855. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  6856. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  6857. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  6858. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  6859. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  6860. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  6861. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  6862. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  6863. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  6864. .ilen = 512,
  6865. .result = "\x27\xa7\x47\x9b\xef\xa1\xd4\x76"
  6866. "\x48\x9f\x30\x8c\xd4\xcf\xa6\xe2"
  6867. "\xa9\x6e\x4b\xbe\x32\x08\xff\x25"
  6868. "\x28\x7d\xd3\x81\x96\x16\xe8\x9c"
  6869. "\xc7\x8c\xf7\xf5\xe5\x43\x44\x5f"
  6870. "\x83\x33\xd8\xfa\x7f\x56\x00\x00"
  6871. "\x05\x27\x9f\xa5\xd8\xb5\xe4\xad"
  6872. "\x40\xe7\x36\xdd\xb4\xd3\x54\x12"
  6873. "\x32\x80\x63\xfd\x2a\xab\x53\xe5"
  6874. "\xea\x1e\x0a\x9f\x33\x25\x00\xa5"
  6875. "\xdf\x94\x87\xd0\x7a\x5c\x92\xcc"
  6876. "\x51\x2c\x88\x66\xc7\xe8\x60\xce"
  6877. "\x93\xfd\xf1\x66\xa2\x49\x12\xb4"
  6878. "\x22\x97\x61\x46\xae\x20\xce\x84"
  6879. "\x6b\xb7\xdc\x9b\xa9\x4a\x76\x7a"
  6880. "\xae\xf2\x0c\x0d\x61\xad\x02\x65"
  6881. "\x5e\xa9\x2d\xc4\xc4\xe4\x1a\x89"
  6882. "\x52\xc6\x51\xd3\x31\x74\xbe\x51"
  6883. "\xa1\x0c\x42\x11\x10\xe6\xd8\x15"
  6884. "\x88\xed\xe8\x21\x03\xa2\x52\xd8"
  6885. "\xa7\x50\xe8\x76\x8d\xef\xff\xed"
  6886. "\x91\x22\x81\x0a\xae\xb9\x9f\x91"
  6887. "\x72\xaf\x82\xb6\x04\xdc\x4b\x8e"
  6888. "\x51\xbc\xb0\x82\x35\xa6\xf4\x34"
  6889. "\x13\x32\xe4\xca\x60\x48\x2a\x4b"
  6890. "\xa1\xa0\x3b\x3e\x65\x00\x8f\xc5"
  6891. "\xda\x76\xb7\x0b\xf1\x69\x0d\xb4"
  6892. "\xea\xe2\x9c\x5f\x1b\xad\xd0\x3c"
  6893. "\x5c\xcf\x2a\x55\xd7\x05\xdd\xcd"
  6894. "\x86\xd4\x49\x51\x1c\xeb\x7e\xc3"
  6895. "\x0b\xf1\x2b\x1f\xa3\x5b\x91\x3f"
  6896. "\x9f\x74\x7a\x8a\xfd\x1b\x13\x0e"
  6897. "\x94\xbf\xf9\x4e\xff\xd0\x1a\x91"
  6898. "\x73\x5c\xa1\x72\x6a\xcd\x0b\x19"
  6899. "\x7c\x4e\x5b\x03\x39\x36\x97\xe1"
  6900. "\x26\x82\x6f\xb6\xbb\xde\x8e\xcc"
  6901. "\x1e\x08\x29\x85\x16\xe2\xc9\xed"
  6902. "\x03\xff\x3c\x1b\x78\x60\xf6\xde"
  6903. "\x76\xd4\xce\xcd\x94\xc8\x11\x98"
  6904. "\x55\xef\x52\x97\xca\x67\xe9\xf3"
  6905. "\xe7\xff\x72\xb1\xe9\x97\x85\xca"
  6906. "\x0a\x7e\x77\x20\xc5\xb3\x6d\xc6"
  6907. "\xd7\x2c\xac\x95\x74\xc8\xcb\xbc"
  6908. "\x2f\x80\x1e\x23\xe5\x6f\xd3\x44"
  6909. "\xb0\x7f\x22\x15\x4b\xeb\xa0\xf0"
  6910. "\x8c\xe8\x89\x1e\x64\x3e\xd9\x95"
  6911. "\xc9\x4d\x9a\x69\xc9\xf1\xb5\xf4"
  6912. "\x99\x02\x7a\x78\x57\x2a\xee\xbd"
  6913. "\x74\xd2\x0c\xc3\x98\x81\xc2\x13"
  6914. "\xee\x77\x0b\x10\x10\xe4\xbe\xa7"
  6915. "\x18\x84\x69\x77\xae\x11\x9f\x7a"
  6916. "\x02\x3a\xb5\x8c\xca\x0a\xd7\x52"
  6917. "\xaf\xe6\x56\xbb\x3c\x17\x25\x6a"
  6918. "\x9f\x6e\x9b\xf1\x9f\xdd\x5a\x38"
  6919. "\xfc\x82\xbb\xe8\x72\xc5\x53\x9e"
  6920. "\xdb\x60\x9e\xf4\xf7\x9c\x20\x3e"
  6921. "\xbb\x14\x0f\x2e\x58\x3c\xb2\xad"
  6922. "\x15\xb4\xaa\x5b\x65\x50\x16\xa8"
  6923. "\x44\x92\x77\xdb\xd4\x77\xef\x2c"
  6924. "\x8d\x6c\x01\x7d\xb7\x38\xb1\x8d"
  6925. "\xeb\x4a\x42\x7d\x19\x23\xce\x3f"
  6926. "\xf2\x62\x73\x57\x79\xa4\x18\xf2"
  6927. "\x0a\x28\x2d\xf9\x20\x14\x7b\xea"
  6928. "\xbe\x42\x1e\xe5\x31\x9d\x05\x68",
  6929. .rlen = 512,
  6930. }, { /* XTS-AES 10, XTS-AES-256, data unit 512 bytes */
  6931. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  6932. "\x23\x53\x60\x28\x74\x71\x35\x26"
  6933. "\x62\x49\x77\x57\x24\x70\x93\x69"
  6934. "\x99\x59\x57\x49\x66\x96\x76\x27"
  6935. "\x31\x41\x59\x26\x53\x58\x97\x93"
  6936. "\x23\x84\x62\x64\x33\x83\x27\x95"
  6937. "\x02\x88\x41\x97\x16\x93\x99\x37"
  6938. "\x51\x05\x82\x09\x74\x94\x45\x92",
  6939. .klen = 64,
  6940. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  6941. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6942. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6943. "\x00\x00\x00\x00\x00\x00\x00\x00",
  6944. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  6945. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6946. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6947. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  6948. "\x20\x21\x22\x23\x24\x25\x26\x27"
  6949. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  6950. "\x30\x31\x32\x33\x34\x35\x36\x37"
  6951. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  6952. "\x40\x41\x42\x43\x44\x45\x46\x47"
  6953. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  6954. "\x50\x51\x52\x53\x54\x55\x56\x57"
  6955. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  6956. "\x60\x61\x62\x63\x64\x65\x66\x67"
  6957. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  6958. "\x70\x71\x72\x73\x74\x75\x76\x77"
  6959. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  6960. "\x80\x81\x82\x83\x84\x85\x86\x87"
  6961. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  6962. "\x90\x91\x92\x93\x94\x95\x96\x97"
  6963. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  6964. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  6965. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  6966. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  6967. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  6968. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  6969. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  6970. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  6971. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  6972. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  6973. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  6974. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  6975. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  6976. "\x00\x01\x02\x03\x04\x05\x06\x07"
  6977. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  6978. "\x10\x11\x12\x13\x14\x15\x16\x17"
  6979. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  6980. "\x20\x21\x22\x23\x24\x25\x26\x27"
  6981. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  6982. "\x30\x31\x32\x33\x34\x35\x36\x37"
  6983. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  6984. "\x40\x41\x42\x43\x44\x45\x46\x47"
  6985. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  6986. "\x50\x51\x52\x53\x54\x55\x56\x57"
  6987. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  6988. "\x60\x61\x62\x63\x64\x65\x66\x67"
  6989. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  6990. "\x70\x71\x72\x73\x74\x75\x76\x77"
  6991. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  6992. "\x80\x81\x82\x83\x84\x85\x86\x87"
  6993. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  6994. "\x90\x91\x92\x93\x94\x95\x96\x97"
  6995. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  6996. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  6997. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  6998. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  6999. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7000. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7001. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7002. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7003. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7004. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7005. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7006. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7007. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7008. .ilen = 512,
  7009. .result = "\x1c\x3b\x3a\x10\x2f\x77\x03\x86"
  7010. "\xe4\x83\x6c\x99\xe3\x70\xcf\x9b"
  7011. "\xea\x00\x80\x3f\x5e\x48\x23\x57"
  7012. "\xa4\xae\x12\xd4\x14\xa3\xe6\x3b"
  7013. "\x5d\x31\xe2\x76\xf8\xfe\x4a\x8d"
  7014. "\x66\xb3\x17\xf9\xac\x68\x3f\x44"
  7015. "\x68\x0a\x86\xac\x35\xad\xfc\x33"
  7016. "\x45\xbe\xfe\xcb\x4b\xb1\x88\xfd"
  7017. "\x57\x76\x92\x6c\x49\xa3\x09\x5e"
  7018. "\xb1\x08\xfd\x10\x98\xba\xec\x70"
  7019. "\xaa\xa6\x69\x99\xa7\x2a\x82\xf2"
  7020. "\x7d\x84\x8b\x21\xd4\xa7\x41\xb0"
  7021. "\xc5\xcd\x4d\x5f\xff\x9d\xac\x89"
  7022. "\xae\xba\x12\x29\x61\xd0\x3a\x75"
  7023. "\x71\x23\xe9\x87\x0f\x8a\xcf\x10"
  7024. "\x00\x02\x08\x87\x89\x14\x29\xca"
  7025. "\x2a\x3e\x7a\x7d\x7d\xf7\xb1\x03"
  7026. "\x55\x16\x5c\x8b\x9a\x6d\x0a\x7d"
  7027. "\xe8\xb0\x62\xc4\x50\x0d\xc4\xcd"
  7028. "\x12\x0c\x0f\x74\x18\xda\xe3\xd0"
  7029. "\xb5\x78\x1c\x34\x80\x3f\xa7\x54"
  7030. "\x21\xc7\x90\xdf\xe1\xde\x18\x34"
  7031. "\xf2\x80\xd7\x66\x7b\x32\x7f\x6c"
  7032. "\x8c\xd7\x55\x7e\x12\xac\x3a\x0f"
  7033. "\x93\xec\x05\xc5\x2e\x04\x93\xef"
  7034. "\x31\xa1\x2d\x3d\x92\x60\xf7\x9a"
  7035. "\x28\x9d\x6a\x37\x9b\xc7\x0c\x50"
  7036. "\x84\x14\x73\xd1\xa8\xcc\x81\xec"
  7037. "\x58\x3e\x96\x45\xe0\x7b\x8d\x96"
  7038. "\x70\x65\x5b\xa5\xbb\xcf\xec\xc6"
  7039. "\xdc\x39\x66\x38\x0a\xd8\xfe\xcb"
  7040. "\x17\xb6\xba\x02\x46\x9a\x02\x0a"
  7041. "\x84\xe1\x8e\x8f\x84\x25\x20\x70"
  7042. "\xc1\x3e\x9f\x1f\x28\x9b\xe5\x4f"
  7043. "\xbc\x48\x14\x57\x77\x8f\x61\x60"
  7044. "\x15\xe1\x32\x7a\x02\xb1\x40\xf1"
  7045. "\x50\x5e\xb3\x09\x32\x6d\x68\x37"
  7046. "\x8f\x83\x74\x59\x5c\x84\x9d\x84"
  7047. "\xf4\xc3\x33\xec\x44\x23\x88\x51"
  7048. "\x43\xcb\x47\xbd\x71\xc5\xed\xae"
  7049. "\x9b\xe6\x9a\x2f\xfe\xce\xb1\xbe"
  7050. "\xc9\xde\x24\x4f\xbe\x15\x99\x2b"
  7051. "\x11\xb7\x7c\x04\x0f\x12\xbd\x8f"
  7052. "\x6a\x97\x5a\x44\xa0\xf9\x0c\x29"
  7053. "\xa9\xab\xc3\xd4\xd8\x93\x92\x72"
  7054. "\x84\xc5\x87\x54\xcc\xe2\x94\x52"
  7055. "\x9f\x86\x14\xdc\xd2\xab\xa9\x91"
  7056. "\x92\x5f\xed\xc4\xae\x74\xff\xac"
  7057. "\x6e\x33\x3b\x93\xeb\x4a\xff\x04"
  7058. "\x79\xda\x9a\x41\x0e\x44\x50\xe0"
  7059. "\xdd\x7a\xe4\xc6\xe2\x91\x09\x00"
  7060. "\x57\x5d\xa4\x01\xfc\x07\x05\x9f"
  7061. "\x64\x5e\x8b\x7e\x9b\xfd\xef\x33"
  7062. "\x94\x30\x54\xff\x84\x01\x14\x93"
  7063. "\xc2\x7b\x34\x29\xea\xed\xb4\xed"
  7064. "\x53\x76\x44\x1a\x77\xed\x43\x85"
  7065. "\x1a\xd7\x7f\x16\xf5\x41\xdf\xd2"
  7066. "\x69\xd5\x0d\x6a\x5f\x14\xfb\x0a"
  7067. "\xab\x1c\xbb\x4c\x15\x50\xbe\x97"
  7068. "\xf7\xab\x40\x66\x19\x3c\x4c\xaa"
  7069. "\x77\x3d\xad\x38\x01\x4b\xd2\x09"
  7070. "\x2f\xa7\x55\xc8\x24\xbb\x5e\x54"
  7071. "\xc4\xf3\x6f\xfd\xa9\xfc\xea\x70"
  7072. "\xb9\xc6\xe6\x93\xe1\x48\xc1\x51",
  7073. .rlen = 512,
  7074. }
  7075. };
  7076. static struct cipher_testvec aes_xts_dec_tv_template[] = {
  7077. /* http://grouper.ieee.org/groups/1619/email/pdf00086.pdf */
  7078. { /* XTS-AES 1 */
  7079. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  7080. "\x00\x00\x00\x00\x00\x00\x00\x00"
  7081. "\x00\x00\x00\x00\x00\x00\x00\x00"
  7082. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7083. .klen = 32,
  7084. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  7085. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7086. .input = "\x91\x7c\xf6\x9e\xbd\x68\xb2\xec"
  7087. "\x9b\x9f\xe9\xa3\xea\xdd\xa6\x92"
  7088. "\xcd\x43\xd2\xf5\x95\x98\xed\x85"
  7089. "\x8c\x02\xc2\x65\x2f\xbf\x92\x2e",
  7090. .ilen = 32,
  7091. .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
  7092. "\x00\x00\x00\x00\x00\x00\x00\x00"
  7093. "\x00\x00\x00\x00\x00\x00\x00\x00"
  7094. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7095. .rlen = 32,
  7096. }, { /* XTS-AES 2 */
  7097. .key = "\x11\x11\x11\x11\x11\x11\x11\x11"
  7098. "\x11\x11\x11\x11\x11\x11\x11\x11"
  7099. "\x22\x22\x22\x22\x22\x22\x22\x22"
  7100. "\x22\x22\x22\x22\x22\x22\x22\x22",
  7101. .klen = 32,
  7102. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  7103. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7104. .input = "\xc4\x54\x18\x5e\x6a\x16\x93\x6e"
  7105. "\x39\x33\x40\x38\xac\xef\x83\x8b"
  7106. "\xfb\x18\x6f\xff\x74\x80\xad\xc4"
  7107. "\x28\x93\x82\xec\xd6\xd3\x94\xf0",
  7108. .ilen = 32,
  7109. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  7110. "\x44\x44\x44\x44\x44\x44\x44\x44"
  7111. "\x44\x44\x44\x44\x44\x44\x44\x44"
  7112. "\x44\x44\x44\x44\x44\x44\x44\x44",
  7113. .rlen = 32,
  7114. }, { /* XTS-AES 3 */
  7115. .key = "\xff\xfe\xfd\xfc\xfb\xfa\xf9\xf8"
  7116. "\xf7\xf6\xf5\xf4\xf3\xf2\xf1\xf0"
  7117. "\x22\x22\x22\x22\x22\x22\x22\x22"
  7118. "\x22\x22\x22\x22\x22\x22\x22\x22",
  7119. .klen = 32,
  7120. .iv = "\x33\x33\x33\x33\x33\x00\x00\x00"
  7121. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7122. .input = "\xaf\x85\x33\x6b\x59\x7a\xfc\x1a"
  7123. "\x90\x0b\x2e\xb2\x1e\xc9\x49\xd2"
  7124. "\x92\xdf\x4c\x04\x7e\x0b\x21\x53"
  7125. "\x21\x86\xa5\x97\x1a\x22\x7a\x89",
  7126. .ilen = 32,
  7127. .result = "\x44\x44\x44\x44\x44\x44\x44\x44"
  7128. "\x44\x44\x44\x44\x44\x44\x44\x44"
  7129. "\x44\x44\x44\x44\x44\x44\x44\x44"
  7130. "\x44\x44\x44\x44\x44\x44\x44\x44",
  7131. .rlen = 32,
  7132. }, { /* XTS-AES 4 */
  7133. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  7134. "\x23\x53\x60\x28\x74\x71\x35\x26"
  7135. "\x31\x41\x59\x26\x53\x58\x97\x93"
  7136. "\x23\x84\x62\x64\x33\x83\x27\x95",
  7137. .klen = 32,
  7138. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  7139. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7140. .input = "\x27\xa7\x47\x9b\xef\xa1\xd4\x76"
  7141. "\x48\x9f\x30\x8c\xd4\xcf\xa6\xe2"
  7142. "\xa9\x6e\x4b\xbe\x32\x08\xff\x25"
  7143. "\x28\x7d\xd3\x81\x96\x16\xe8\x9c"
  7144. "\xc7\x8c\xf7\xf5\xe5\x43\x44\x5f"
  7145. "\x83\x33\xd8\xfa\x7f\x56\x00\x00"
  7146. "\x05\x27\x9f\xa5\xd8\xb5\xe4\xad"
  7147. "\x40\xe7\x36\xdd\xb4\xd3\x54\x12"
  7148. "\x32\x80\x63\xfd\x2a\xab\x53\xe5"
  7149. "\xea\x1e\x0a\x9f\x33\x25\x00\xa5"
  7150. "\xdf\x94\x87\xd0\x7a\x5c\x92\xcc"
  7151. "\x51\x2c\x88\x66\xc7\xe8\x60\xce"
  7152. "\x93\xfd\xf1\x66\xa2\x49\x12\xb4"
  7153. "\x22\x97\x61\x46\xae\x20\xce\x84"
  7154. "\x6b\xb7\xdc\x9b\xa9\x4a\x76\x7a"
  7155. "\xae\xf2\x0c\x0d\x61\xad\x02\x65"
  7156. "\x5e\xa9\x2d\xc4\xc4\xe4\x1a\x89"
  7157. "\x52\xc6\x51\xd3\x31\x74\xbe\x51"
  7158. "\xa1\x0c\x42\x11\x10\xe6\xd8\x15"
  7159. "\x88\xed\xe8\x21\x03\xa2\x52\xd8"
  7160. "\xa7\x50\xe8\x76\x8d\xef\xff\xed"
  7161. "\x91\x22\x81\x0a\xae\xb9\x9f\x91"
  7162. "\x72\xaf\x82\xb6\x04\xdc\x4b\x8e"
  7163. "\x51\xbc\xb0\x82\x35\xa6\xf4\x34"
  7164. "\x13\x32\xe4\xca\x60\x48\x2a\x4b"
  7165. "\xa1\xa0\x3b\x3e\x65\x00\x8f\xc5"
  7166. "\xda\x76\xb7\x0b\xf1\x69\x0d\xb4"
  7167. "\xea\xe2\x9c\x5f\x1b\xad\xd0\x3c"
  7168. "\x5c\xcf\x2a\x55\xd7\x05\xdd\xcd"
  7169. "\x86\xd4\x49\x51\x1c\xeb\x7e\xc3"
  7170. "\x0b\xf1\x2b\x1f\xa3\x5b\x91\x3f"
  7171. "\x9f\x74\x7a\x8a\xfd\x1b\x13\x0e"
  7172. "\x94\xbf\xf9\x4e\xff\xd0\x1a\x91"
  7173. "\x73\x5c\xa1\x72\x6a\xcd\x0b\x19"
  7174. "\x7c\x4e\x5b\x03\x39\x36\x97\xe1"
  7175. "\x26\x82\x6f\xb6\xbb\xde\x8e\xcc"
  7176. "\x1e\x08\x29\x85\x16\xe2\xc9\xed"
  7177. "\x03\xff\x3c\x1b\x78\x60\xf6\xde"
  7178. "\x76\xd4\xce\xcd\x94\xc8\x11\x98"
  7179. "\x55\xef\x52\x97\xca\x67\xe9\xf3"
  7180. "\xe7\xff\x72\xb1\xe9\x97\x85\xca"
  7181. "\x0a\x7e\x77\x20\xc5\xb3\x6d\xc6"
  7182. "\xd7\x2c\xac\x95\x74\xc8\xcb\xbc"
  7183. "\x2f\x80\x1e\x23\xe5\x6f\xd3\x44"
  7184. "\xb0\x7f\x22\x15\x4b\xeb\xa0\xf0"
  7185. "\x8c\xe8\x89\x1e\x64\x3e\xd9\x95"
  7186. "\xc9\x4d\x9a\x69\xc9\xf1\xb5\xf4"
  7187. "\x99\x02\x7a\x78\x57\x2a\xee\xbd"
  7188. "\x74\xd2\x0c\xc3\x98\x81\xc2\x13"
  7189. "\xee\x77\x0b\x10\x10\xe4\xbe\xa7"
  7190. "\x18\x84\x69\x77\xae\x11\x9f\x7a"
  7191. "\x02\x3a\xb5\x8c\xca\x0a\xd7\x52"
  7192. "\xaf\xe6\x56\xbb\x3c\x17\x25\x6a"
  7193. "\x9f\x6e\x9b\xf1\x9f\xdd\x5a\x38"
  7194. "\xfc\x82\xbb\xe8\x72\xc5\x53\x9e"
  7195. "\xdb\x60\x9e\xf4\xf7\x9c\x20\x3e"
  7196. "\xbb\x14\x0f\x2e\x58\x3c\xb2\xad"
  7197. "\x15\xb4\xaa\x5b\x65\x50\x16\xa8"
  7198. "\x44\x92\x77\xdb\xd4\x77\xef\x2c"
  7199. "\x8d\x6c\x01\x7d\xb7\x38\xb1\x8d"
  7200. "\xeb\x4a\x42\x7d\x19\x23\xce\x3f"
  7201. "\xf2\x62\x73\x57\x79\xa4\x18\xf2"
  7202. "\x0a\x28\x2d\xf9\x20\x14\x7b\xea"
  7203. "\xbe\x42\x1e\xe5\x31\x9d\x05\x68",
  7204. .ilen = 512,
  7205. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7206. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7207. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7208. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7209. "\x20\x21\x22\x23\x24\x25\x26\x27"
  7210. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  7211. "\x30\x31\x32\x33\x34\x35\x36\x37"
  7212. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  7213. "\x40\x41\x42\x43\x44\x45\x46\x47"
  7214. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  7215. "\x50\x51\x52\x53\x54\x55\x56\x57"
  7216. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  7217. "\x60\x61\x62\x63\x64\x65\x66\x67"
  7218. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  7219. "\x70\x71\x72\x73\x74\x75\x76\x77"
  7220. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  7221. "\x80\x81\x82\x83\x84\x85\x86\x87"
  7222. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  7223. "\x90\x91\x92\x93\x94\x95\x96\x97"
  7224. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  7225. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  7226. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  7227. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  7228. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7229. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7230. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7231. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7232. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7233. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7234. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7235. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7236. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  7237. "\x00\x01\x02\x03\x04\x05\x06\x07"
  7238. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7239. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7240. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7241. "\x20\x21\x22\x23\x24\x25\x26\x27"
  7242. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  7243. "\x30\x31\x32\x33\x34\x35\x36\x37"
  7244. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  7245. "\x40\x41\x42\x43\x44\x45\x46\x47"
  7246. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  7247. "\x50\x51\x52\x53\x54\x55\x56\x57"
  7248. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  7249. "\x60\x61\x62\x63\x64\x65\x66\x67"
  7250. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  7251. "\x70\x71\x72\x73\x74\x75\x76\x77"
  7252. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  7253. "\x80\x81\x82\x83\x84\x85\x86\x87"
  7254. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  7255. "\x90\x91\x92\x93\x94\x95\x96\x97"
  7256. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  7257. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  7258. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  7259. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  7260. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7261. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7262. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7263. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7264. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7265. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7266. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7267. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7268. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7269. .rlen = 512,
  7270. }, { /* XTS-AES 10, XTS-AES-256, data unit 512 bytes */
  7271. .key = "\x27\x18\x28\x18\x28\x45\x90\x45"
  7272. "\x23\x53\x60\x28\x74\x71\x35\x26"
  7273. "\x62\x49\x77\x57\x24\x70\x93\x69"
  7274. "\x99\x59\x57\x49\x66\x96\x76\x27"
  7275. "\x31\x41\x59\x26\x53\x58\x97\x93"
  7276. "\x23\x84\x62\x64\x33\x83\x27\x95"
  7277. "\x02\x88\x41\x97\x16\x93\x99\x37"
  7278. "\x51\x05\x82\x09\x74\x94\x45\x92",
  7279. .klen = 64,
  7280. .iv = "\xff\x00\x00\x00\x00\x00\x00\x00"
  7281. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7282. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7283. "\x00\x00\x00\x00\x00\x00\x00\x00",
  7284. .input = "\x1c\x3b\x3a\x10\x2f\x77\x03\x86"
  7285. "\xe4\x83\x6c\x99\xe3\x70\xcf\x9b"
  7286. "\xea\x00\x80\x3f\x5e\x48\x23\x57"
  7287. "\xa4\xae\x12\xd4\x14\xa3\xe6\x3b"
  7288. "\x5d\x31\xe2\x76\xf8\xfe\x4a\x8d"
  7289. "\x66\xb3\x17\xf9\xac\x68\x3f\x44"
  7290. "\x68\x0a\x86\xac\x35\xad\xfc\x33"
  7291. "\x45\xbe\xfe\xcb\x4b\xb1\x88\xfd"
  7292. "\x57\x76\x92\x6c\x49\xa3\x09\x5e"
  7293. "\xb1\x08\xfd\x10\x98\xba\xec\x70"
  7294. "\xaa\xa6\x69\x99\xa7\x2a\x82\xf2"
  7295. "\x7d\x84\x8b\x21\xd4\xa7\x41\xb0"
  7296. "\xc5\xcd\x4d\x5f\xff\x9d\xac\x89"
  7297. "\xae\xba\x12\x29\x61\xd0\x3a\x75"
  7298. "\x71\x23\xe9\x87\x0f\x8a\xcf\x10"
  7299. "\x00\x02\x08\x87\x89\x14\x29\xca"
  7300. "\x2a\x3e\x7a\x7d\x7d\xf7\xb1\x03"
  7301. "\x55\x16\x5c\x8b\x9a\x6d\x0a\x7d"
  7302. "\xe8\xb0\x62\xc4\x50\x0d\xc4\xcd"
  7303. "\x12\x0c\x0f\x74\x18\xda\xe3\xd0"
  7304. "\xb5\x78\x1c\x34\x80\x3f\xa7\x54"
  7305. "\x21\xc7\x90\xdf\xe1\xde\x18\x34"
  7306. "\xf2\x80\xd7\x66\x7b\x32\x7f\x6c"
  7307. "\x8c\xd7\x55\x7e\x12\xac\x3a\x0f"
  7308. "\x93\xec\x05\xc5\x2e\x04\x93\xef"
  7309. "\x31\xa1\x2d\x3d\x92\x60\xf7\x9a"
  7310. "\x28\x9d\x6a\x37\x9b\xc7\x0c\x50"
  7311. "\x84\x14\x73\xd1\xa8\xcc\x81\xec"
  7312. "\x58\x3e\x96\x45\xe0\x7b\x8d\x96"
  7313. "\x70\x65\x5b\xa5\xbb\xcf\xec\xc6"
  7314. "\xdc\x39\x66\x38\x0a\xd8\xfe\xcb"
  7315. "\x17\xb6\xba\x02\x46\x9a\x02\x0a"
  7316. "\x84\xe1\x8e\x8f\x84\x25\x20\x70"
  7317. "\xc1\x3e\x9f\x1f\x28\x9b\xe5\x4f"
  7318. "\xbc\x48\x14\x57\x77\x8f\x61\x60"
  7319. "\x15\xe1\x32\x7a\x02\xb1\x40\xf1"
  7320. "\x50\x5e\xb3\x09\x32\x6d\x68\x37"
  7321. "\x8f\x83\x74\x59\x5c\x84\x9d\x84"
  7322. "\xf4\xc3\x33\xec\x44\x23\x88\x51"
  7323. "\x43\xcb\x47\xbd\x71\xc5\xed\xae"
  7324. "\x9b\xe6\x9a\x2f\xfe\xce\xb1\xbe"
  7325. "\xc9\xde\x24\x4f\xbe\x15\x99\x2b"
  7326. "\x11\xb7\x7c\x04\x0f\x12\xbd\x8f"
  7327. "\x6a\x97\x5a\x44\xa0\xf9\x0c\x29"
  7328. "\xa9\xab\xc3\xd4\xd8\x93\x92\x72"
  7329. "\x84\xc5\x87\x54\xcc\xe2\x94\x52"
  7330. "\x9f\x86\x14\xdc\xd2\xab\xa9\x91"
  7331. "\x92\x5f\xed\xc4\xae\x74\xff\xac"
  7332. "\x6e\x33\x3b\x93\xeb\x4a\xff\x04"
  7333. "\x79\xda\x9a\x41\x0e\x44\x50\xe0"
  7334. "\xdd\x7a\xe4\xc6\xe2\x91\x09\x00"
  7335. "\x57\x5d\xa4\x01\xfc\x07\x05\x9f"
  7336. "\x64\x5e\x8b\x7e\x9b\xfd\xef\x33"
  7337. "\x94\x30\x54\xff\x84\x01\x14\x93"
  7338. "\xc2\x7b\x34\x29\xea\xed\xb4\xed"
  7339. "\x53\x76\x44\x1a\x77\xed\x43\x85"
  7340. "\x1a\xd7\x7f\x16\xf5\x41\xdf\xd2"
  7341. "\x69\xd5\x0d\x6a\x5f\x14\xfb\x0a"
  7342. "\xab\x1c\xbb\x4c\x15\x50\xbe\x97"
  7343. "\xf7\xab\x40\x66\x19\x3c\x4c\xaa"
  7344. "\x77\x3d\xad\x38\x01\x4b\xd2\x09"
  7345. "\x2f\xa7\x55\xc8\x24\xbb\x5e\x54"
  7346. "\xc4\xf3\x6f\xfd\xa9\xfc\xea\x70"
  7347. "\xb9\xc6\xe6\x93\xe1\x48\xc1\x51",
  7348. .ilen = 512,
  7349. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7350. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7351. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7352. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7353. "\x20\x21\x22\x23\x24\x25\x26\x27"
  7354. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  7355. "\x30\x31\x32\x33\x34\x35\x36\x37"
  7356. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  7357. "\x40\x41\x42\x43\x44\x45\x46\x47"
  7358. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  7359. "\x50\x51\x52\x53\x54\x55\x56\x57"
  7360. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  7361. "\x60\x61\x62\x63\x64\x65\x66\x67"
  7362. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  7363. "\x70\x71\x72\x73\x74\x75\x76\x77"
  7364. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  7365. "\x80\x81\x82\x83\x84\x85\x86\x87"
  7366. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  7367. "\x90\x91\x92\x93\x94\x95\x96\x97"
  7368. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  7369. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  7370. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  7371. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  7372. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7373. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7374. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7375. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7376. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7377. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7378. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7379. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7380. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  7381. "\x00\x01\x02\x03\x04\x05\x06\x07"
  7382. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7383. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7384. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7385. "\x20\x21\x22\x23\x24\x25\x26\x27"
  7386. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  7387. "\x30\x31\x32\x33\x34\x35\x36\x37"
  7388. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  7389. "\x40\x41\x42\x43\x44\x45\x46\x47"
  7390. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  7391. "\x50\x51\x52\x53\x54\x55\x56\x57"
  7392. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  7393. "\x60\x61\x62\x63\x64\x65\x66\x67"
  7394. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  7395. "\x70\x71\x72\x73\x74\x75\x76\x77"
  7396. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  7397. "\x80\x81\x82\x83\x84\x85\x86\x87"
  7398. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  7399. "\x90\x91\x92\x93\x94\x95\x96\x97"
  7400. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  7401. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  7402. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  7403. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  7404. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7405. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7406. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7407. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7408. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7409. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7410. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7411. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7412. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7413. .rlen = 512,
  7414. }
  7415. };
  7416. static struct cipher_testvec aes_ctr_enc_tv_template[] = {
  7417. { /* From NIST Special Publication 800-38A, Appendix F.5 */
  7418. .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
  7419. "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
  7420. .klen = 16,
  7421. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7422. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7423. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7424. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7425. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7426. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7427. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7428. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7429. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7430. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7431. .ilen = 64,
  7432. .result = "\x87\x4d\x61\x91\xb6\x20\xe3\x26"
  7433. "\x1b\xef\x68\x64\x99\x0d\xb6\xce"
  7434. "\x98\x06\xf6\x6b\x79\x70\xfd\xff"
  7435. "\x86\x17\x18\x7b\xb9\xff\xfd\xff"
  7436. "\x5a\xe4\xdf\x3e\xdb\xd5\xd3\x5e"
  7437. "\x5b\x4f\x09\x02\x0d\xb0\x3e\xab"
  7438. "\x1e\x03\x1d\xda\x2f\xbe\x03\xd1"
  7439. "\x79\x21\x70\xa0\xf3\x00\x9c\xee",
  7440. .rlen = 64,
  7441. }, {
  7442. .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
  7443. "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
  7444. "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
  7445. .klen = 24,
  7446. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7447. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7448. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7449. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7450. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7451. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7452. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7453. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7454. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7455. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7456. .ilen = 64,
  7457. .result = "\x1a\xbc\x93\x24\x17\x52\x1c\xa2"
  7458. "\x4f\x2b\x04\x59\xfe\x7e\x6e\x0b"
  7459. "\x09\x03\x39\xec\x0a\xa6\xfa\xef"
  7460. "\xd5\xcc\xc2\xc6\xf4\xce\x8e\x94"
  7461. "\x1e\x36\xb2\x6b\xd1\xeb\xc6\x70"
  7462. "\xd1\xbd\x1d\x66\x56\x20\xab\xf7"
  7463. "\x4f\x78\xa7\xf6\xd2\x98\x09\x58"
  7464. "\x5a\x97\xda\xec\x58\xc6\xb0\x50",
  7465. .rlen = 64,
  7466. }, {
  7467. .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
  7468. "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
  7469. "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
  7470. "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
  7471. .klen = 32,
  7472. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7473. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7474. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7475. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7476. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7477. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7478. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7479. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7480. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7481. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7482. .ilen = 64,
  7483. .result = "\x60\x1e\xc3\x13\x77\x57\x89\xa5"
  7484. "\xb7\xa7\xf5\x04\xbb\xf3\xd2\x28"
  7485. "\xf4\x43\xe3\xca\x4d\x62\xb5\x9a"
  7486. "\xca\x84\xe9\x90\xca\xca\xf5\xc5"
  7487. "\x2b\x09\x30\xda\xa2\x3d\xe9\x4c"
  7488. "\xe8\x70\x17\xba\x2d\x84\x98\x8d"
  7489. "\xdf\xc9\xc5\x8d\xb6\x7a\xad\xa6"
  7490. "\x13\xc2\xdd\x08\x45\x79\x41\xa6",
  7491. .rlen = 64,
  7492. }
  7493. };
  7494. static struct cipher_testvec aes_ctr_dec_tv_template[] = {
  7495. { /* From NIST Special Publication 800-38A, Appendix F.5 */
  7496. .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
  7497. "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
  7498. .klen = 16,
  7499. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7500. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7501. .input = "\x87\x4d\x61\x91\xb6\x20\xe3\x26"
  7502. "\x1b\xef\x68\x64\x99\x0d\xb6\xce"
  7503. "\x98\x06\xf6\x6b\x79\x70\xfd\xff"
  7504. "\x86\x17\x18\x7b\xb9\xff\xfd\xff"
  7505. "\x5a\xe4\xdf\x3e\xdb\xd5\xd3\x5e"
  7506. "\x5b\x4f\x09\x02\x0d\xb0\x3e\xab"
  7507. "\x1e\x03\x1d\xda\x2f\xbe\x03\xd1"
  7508. "\x79\x21\x70\xa0\xf3\x00\x9c\xee",
  7509. .ilen = 64,
  7510. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7511. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7512. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7513. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7514. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7515. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7516. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7517. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7518. .rlen = 64,
  7519. }, {
  7520. .key = "\x8e\x73\xb0\xf7\xda\x0e\x64\x52"
  7521. "\xc8\x10\xf3\x2b\x80\x90\x79\xe5"
  7522. "\x62\xf8\xea\xd2\x52\x2c\x6b\x7b",
  7523. .klen = 24,
  7524. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7525. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7526. .input = "\x1a\xbc\x93\x24\x17\x52\x1c\xa2"
  7527. "\x4f\x2b\x04\x59\xfe\x7e\x6e\x0b"
  7528. "\x09\x03\x39\xec\x0a\xa6\xfa\xef"
  7529. "\xd5\xcc\xc2\xc6\xf4\xce\x8e\x94"
  7530. "\x1e\x36\xb2\x6b\xd1\xeb\xc6\x70"
  7531. "\xd1\xbd\x1d\x66\x56\x20\xab\xf7"
  7532. "\x4f\x78\xa7\xf6\xd2\x98\x09\x58"
  7533. "\x5a\x97\xda\xec\x58\xc6\xb0\x50",
  7534. .ilen = 64,
  7535. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7536. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7537. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7538. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7539. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7540. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7541. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7542. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7543. .rlen = 64,
  7544. }, {
  7545. .key = "\x60\x3d\xeb\x10\x15\xca\x71\xbe"
  7546. "\x2b\x73\xae\xf0\x85\x7d\x77\x81"
  7547. "\x1f\x35\x2c\x07\x3b\x61\x08\xd7"
  7548. "\x2d\x98\x10\xa3\x09\x14\xdf\xf4",
  7549. .klen = 32,
  7550. .iv = "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7551. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff",
  7552. .input = "\x60\x1e\xc3\x13\x77\x57\x89\xa5"
  7553. "\xb7\xa7\xf5\x04\xbb\xf3\xd2\x28"
  7554. "\xf4\x43\xe3\xca\x4d\x62\xb5\x9a"
  7555. "\xca\x84\xe9\x90\xca\xca\xf5\xc5"
  7556. "\x2b\x09\x30\xda\xa2\x3d\xe9\x4c"
  7557. "\xe8\x70\x17\xba\x2d\x84\x98\x8d"
  7558. "\xdf\xc9\xc5\x8d\xb6\x7a\xad\xa6"
  7559. "\x13\xc2\xdd\x08\x45\x79\x41\xa6",
  7560. .ilen = 64,
  7561. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  7562. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  7563. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  7564. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  7565. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  7566. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  7567. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  7568. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  7569. .rlen = 64,
  7570. }
  7571. };
  7572. static struct cipher_testvec aes_ctr_rfc3686_enc_tv_template[] = {
  7573. { /* From RFC 3686 */
  7574. .key = "\xae\x68\x52\xf8\x12\x10\x67\xcc"
  7575. "\x4b\xf7\xa5\x76\x55\x77\xf3\x9e"
  7576. "\x00\x00\x00\x30",
  7577. .klen = 20,
  7578. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  7579. .input = "Single block msg",
  7580. .ilen = 16,
  7581. .result = "\xe4\x09\x5d\x4f\xb7\xa7\xb3\x79"
  7582. "\x2d\x61\x75\xa3\x26\x13\x11\xb8",
  7583. .rlen = 16,
  7584. }, {
  7585. .key = "\x7e\x24\x06\x78\x17\xfa\xe0\xd7"
  7586. "\x43\xd6\xce\x1f\x32\x53\x91\x63"
  7587. "\x00\x6c\xb6\xdb",
  7588. .klen = 20,
  7589. .iv = "\xc0\x54\x3b\x59\xda\x48\xd9\x0b",
  7590. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7591. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7592. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7593. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  7594. .ilen = 32,
  7595. .result = "\x51\x04\xa1\x06\x16\x8a\x72\xd9"
  7596. "\x79\x0d\x41\xee\x8e\xda\xd3\x88"
  7597. "\xeb\x2e\x1e\xfc\x46\xda\x57\xc8"
  7598. "\xfc\xe6\x30\xdf\x91\x41\xbe\x28",
  7599. .rlen = 32,
  7600. }, {
  7601. .key = "\x16\xaf\x5b\x14\x5f\xc9\xf5\x79"
  7602. "\xc1\x75\xf9\x3e\x3b\xfb\x0e\xed"
  7603. "\x86\x3d\x06\xcc\xfd\xb7\x85\x15"
  7604. "\x00\x00\x00\x48",
  7605. .klen = 28,
  7606. .iv = "\x36\x73\x3c\x14\x7d\x6d\x93\xcb",
  7607. .input = "Single block msg",
  7608. .ilen = 16,
  7609. .result = "\x4b\x55\x38\x4f\xe2\x59\xc9\xc8"
  7610. "\x4e\x79\x35\xa0\x03\xcb\xe9\x28",
  7611. .rlen = 16,
  7612. }, {
  7613. .key = "\x7c\x5c\xb2\x40\x1b\x3d\xc3\x3c"
  7614. "\x19\xe7\x34\x08\x19\xe0\xf6\x9c"
  7615. "\x67\x8c\x3d\xb8\xe6\xf6\xa9\x1a"
  7616. "\x00\x96\xb0\x3b",
  7617. .klen = 28,
  7618. .iv = "\x02\x0c\x6e\xad\xc2\xcb\x50\x0d",
  7619. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7620. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7621. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7622. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  7623. .ilen = 32,
  7624. .result = "\x45\x32\x43\xfc\x60\x9b\x23\x32"
  7625. "\x7e\xdf\xaa\xfa\x71\x31\xcd\x9f"
  7626. "\x84\x90\x70\x1c\x5a\xd4\xa7\x9c"
  7627. "\xfc\x1f\xe0\xff\x42\xf4\xfb\x00",
  7628. .rlen = 32,
  7629. }, {
  7630. .key = "\x77\x6b\xef\xf2\x85\x1d\xb0\x6f"
  7631. "\x4c\x8a\x05\x42\xc8\x69\x6f\x6c"
  7632. "\x6a\x81\xaf\x1e\xec\x96\xb4\xd3"
  7633. "\x7f\xc1\xd6\x89\xe6\xc1\xc1\x04"
  7634. "\x00\x00\x00\x60",
  7635. .klen = 36,
  7636. .iv = "\xdb\x56\x72\xc9\x7a\xa8\xf0\xb2",
  7637. .input = "Single block msg",
  7638. .ilen = 16,
  7639. .result = "\x14\x5a\xd0\x1d\xbf\x82\x4e\xc7"
  7640. "\x56\x08\x63\xdc\x71\xe3\xe0\xc0",
  7641. .rlen = 16,
  7642. }, {
  7643. .key = "\xf6\xd6\x6d\x6b\xd5\x2d\x59\xbb"
  7644. "\x07\x96\x36\x58\x79\xef\xf8\x86"
  7645. "\xc6\x6d\xd5\x1a\x5b\x6a\x99\x74"
  7646. "\x4b\x50\x59\x0c\x87\xa2\x38\x84"
  7647. "\x00\xfa\xac\x24",
  7648. .klen = 36,
  7649. .iv = "\xc1\x58\x5e\xf1\x5a\x43\xd8\x75",
  7650. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7651. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7652. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7653. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  7654. .ilen = 32,
  7655. .result = "\xf0\x5e\x23\x1b\x38\x94\x61\x2c"
  7656. "\x49\xee\x00\x0b\x80\x4e\xb2\xa9"
  7657. "\xb8\x30\x6b\x50\x8f\x83\x9d\x6a"
  7658. "\x55\x30\x83\x1d\x93\x44\xaf\x1c",
  7659. .rlen = 32,
  7660. }, {
  7661. // generated using Crypto++
  7662. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  7663. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7664. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7665. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7666. "\x00\x00\x00\x00",
  7667. .klen = 32 + 4,
  7668. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  7669. .input =
  7670. "\x00\x01\x02\x03\x04\x05\x06\x07"
  7671. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  7672. "\x10\x11\x12\x13\x14\x15\x16\x17"
  7673. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  7674. "\x20\x21\x22\x23\x24\x25\x26\x27"
  7675. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  7676. "\x30\x31\x32\x33\x34\x35\x36\x37"
  7677. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  7678. "\x40\x41\x42\x43\x44\x45\x46\x47"
  7679. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  7680. "\x50\x51\x52\x53\x54\x55\x56\x57"
  7681. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  7682. "\x60\x61\x62\x63\x64\x65\x66\x67"
  7683. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  7684. "\x70\x71\x72\x73\x74\x75\x76\x77"
  7685. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  7686. "\x80\x81\x82\x83\x84\x85\x86\x87"
  7687. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  7688. "\x90\x91\x92\x93\x94\x95\x96\x97"
  7689. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  7690. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  7691. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  7692. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  7693. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  7694. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  7695. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  7696. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  7697. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  7698. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  7699. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  7700. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  7701. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  7702. "\x00\x03\x06\x09\x0c\x0f\x12\x15"
  7703. "\x18\x1b\x1e\x21\x24\x27\x2a\x2d"
  7704. "\x30\x33\x36\x39\x3c\x3f\x42\x45"
  7705. "\x48\x4b\x4e\x51\x54\x57\x5a\x5d"
  7706. "\x60\x63\x66\x69\x6c\x6f\x72\x75"
  7707. "\x78\x7b\x7e\x81\x84\x87\x8a\x8d"
  7708. "\x90\x93\x96\x99\x9c\x9f\xa2\xa5"
  7709. "\xa8\xab\xae\xb1\xb4\xb7\xba\xbd"
  7710. "\xc0\xc3\xc6\xc9\xcc\xcf\xd2\xd5"
  7711. "\xd8\xdb\xde\xe1\xe4\xe7\xea\xed"
  7712. "\xf0\xf3\xf6\xf9\xfc\xff\x02\x05"
  7713. "\x08\x0b\x0e\x11\x14\x17\x1a\x1d"
  7714. "\x20\x23\x26\x29\x2c\x2f\x32\x35"
  7715. "\x38\x3b\x3e\x41\x44\x47\x4a\x4d"
  7716. "\x50\x53\x56\x59\x5c\x5f\x62\x65"
  7717. "\x68\x6b\x6e\x71\x74\x77\x7a\x7d"
  7718. "\x80\x83\x86\x89\x8c\x8f\x92\x95"
  7719. "\x98\x9b\x9e\xa1\xa4\xa7\xaa\xad"
  7720. "\xb0\xb3\xb6\xb9\xbc\xbf\xc2\xc5"
  7721. "\xc8\xcb\xce\xd1\xd4\xd7\xda\xdd"
  7722. "\xe0\xe3\xe6\xe9\xec\xef\xf2\xf5"
  7723. "\xf8\xfb\xfe\x01\x04\x07\x0a\x0d"
  7724. "\x10\x13\x16\x19\x1c\x1f\x22\x25"
  7725. "\x28\x2b\x2e\x31\x34\x37\x3a\x3d"
  7726. "\x40\x43\x46\x49\x4c\x4f\x52\x55"
  7727. "\x58\x5b\x5e\x61\x64\x67\x6a\x6d"
  7728. "\x70\x73\x76\x79\x7c\x7f\x82\x85"
  7729. "\x88\x8b\x8e\x91\x94\x97\x9a\x9d"
  7730. "\xa0\xa3\xa6\xa9\xac\xaf\xb2\xb5"
  7731. "\xb8\xbb\xbe\xc1\xc4\xc7\xca\xcd"
  7732. "\xd0\xd3\xd6\xd9\xdc\xdf\xe2\xe5"
  7733. "\xe8\xeb\xee\xf1\xf4\xf7\xfa\xfd"
  7734. "\x00\x05\x0a\x0f\x14\x19\x1e\x23"
  7735. "\x28\x2d\x32\x37\x3c\x41\x46\x4b"
  7736. "\x50\x55\x5a\x5f\x64\x69\x6e\x73"
  7737. "\x78\x7d\x82\x87\x8c\x91\x96\x9b"
  7738. "\xa0\xa5\xaa\xaf\xb4\xb9\xbe\xc3"
  7739. "\xc8\xcd\xd2\xd7\xdc\xe1\xe6\xeb"
  7740. "\xf0\xf5\xfa\xff\x04\x09\x0e\x13"
  7741. "\x18\x1d\x22\x27\x2c\x31\x36\x3b"
  7742. "\x40\x45\x4a\x4f\x54\x59\x5e\x63"
  7743. "\x68\x6d\x72\x77\x7c\x81\x86\x8b"
  7744. "\x90\x95\x9a\x9f\xa4\xa9\xae\xb3"
  7745. "\xb8\xbd\xc2\xc7\xcc\xd1\xd6\xdb"
  7746. "\xe0\xe5\xea\xef\xf4\xf9\xfe\x03"
  7747. "\x08\x0d\x12\x17\x1c\x21\x26\x2b"
  7748. "\x30\x35\x3a\x3f\x44\x49\x4e\x53"
  7749. "\x58\x5d\x62\x67\x6c\x71\x76\x7b"
  7750. "\x80\x85\x8a\x8f\x94\x99\x9e\xa3"
  7751. "\xa8\xad\xb2\xb7\xbc\xc1\xc6\xcb"
  7752. "\xd0\xd5\xda\xdf\xe4\xe9\xee\xf3"
  7753. "\xf8\xfd\x02\x07\x0c\x11\x16\x1b"
  7754. "\x20\x25\x2a\x2f\x34\x39\x3e\x43"
  7755. "\x48\x4d\x52\x57\x5c\x61\x66\x6b"
  7756. "\x70\x75\x7a\x7f\x84\x89\x8e\x93"
  7757. "\x98\x9d\xa2\xa7\xac\xb1\xb6\xbb"
  7758. "\xc0\xc5\xca\xcf\xd4\xd9\xde\xe3"
  7759. "\xe8\xed\xf2\xf7\xfc\x01\x06\x0b"
  7760. "\x10\x15\x1a\x1f\x24\x29\x2e\x33"
  7761. "\x38\x3d\x42\x47\x4c\x51\x56\x5b"
  7762. "\x60\x65\x6a\x6f\x74\x79\x7e\x83"
  7763. "\x88\x8d\x92\x97\x9c\xa1\xa6\xab"
  7764. "\xb0\xb5\xba\xbf\xc4\xc9\xce\xd3"
  7765. "\xd8\xdd\xe2\xe7\xec\xf1\xf6\xfb"
  7766. "\x00\x07\x0e\x15\x1c\x23\x2a\x31"
  7767. "\x38\x3f\x46\x4d\x54\x5b\x62\x69"
  7768. "\x70\x77\x7e\x85\x8c\x93\x9a\xa1"
  7769. "\xa8\xaf\xb6\xbd\xc4\xcb\xd2\xd9"
  7770. "\xe0\xe7\xee\xf5\xfc\x03\x0a\x11"
  7771. "\x18\x1f\x26\x2d\x34\x3b\x42\x49"
  7772. "\x50\x57\x5e\x65\x6c\x73\x7a\x81"
  7773. "\x88\x8f\x96\x9d\xa4\xab\xb2\xb9"
  7774. "\xc0\xc7\xce\xd5\xdc\xe3\xea\xf1"
  7775. "\xf8\xff\x06\x0d\x14\x1b\x22\x29"
  7776. "\x30\x37\x3e\x45\x4c\x53\x5a\x61"
  7777. "\x68\x6f\x76\x7d\x84\x8b\x92\x99"
  7778. "\xa0\xa7\xae\xb5\xbc\xc3\xca\xd1"
  7779. "\xd8\xdf\xe6\xed\xf4\xfb\x02\x09"
  7780. "\x10\x17\x1e\x25\x2c\x33\x3a\x41"
  7781. "\x48\x4f\x56\x5d\x64\x6b\x72\x79"
  7782. "\x80\x87\x8e\x95\x9c\xa3\xaa\xb1"
  7783. "\xb8\xbf\xc6\xcd\xd4\xdb\xe2\xe9"
  7784. "\xf0\xf7\xfe\x05\x0c\x13\x1a\x21"
  7785. "\x28\x2f\x36\x3d\x44\x4b\x52\x59"
  7786. "\x60\x67\x6e\x75\x7c\x83\x8a\x91"
  7787. "\x98\x9f\xa6\xad\xb4\xbb\xc2\xc9"
  7788. "\xd0\xd7\xde\xe5\xec\xf3\xfa\x01"
  7789. "\x08\x0f\x16\x1d\x24\x2b\x32\x39"
  7790. "\x40\x47\x4e\x55\x5c\x63\x6a\x71"
  7791. "\x78\x7f\x86\x8d\x94\x9b\xa2\xa9"
  7792. "\xb0\xb7\xbe\xc5\xcc\xd3\xda\xe1"
  7793. "\xe8\xef\xf6\xfd\x04\x0b\x12\x19"
  7794. "\x20\x27\x2e\x35\x3c\x43\x4a\x51"
  7795. "\x58\x5f\x66\x6d\x74\x7b\x82\x89"
  7796. "\x90\x97\x9e\xa5\xac\xb3\xba\xc1"
  7797. "\xc8\xcf\xd6\xdd\xe4\xeb\xf2\xf9"
  7798. "\x00\x09\x12\x1b\x24\x2d\x36\x3f"
  7799. "\x48\x51\x5a\x63\x6c\x75\x7e\x87"
  7800. "\x90\x99\xa2\xab\xb4\xbd\xc6\xcf"
  7801. "\xd8\xe1\xea\xf3\xfc\x05\x0e\x17"
  7802. "\x20\x29\x32\x3b\x44\x4d\x56\x5f"
  7803. "\x68\x71\x7a\x83\x8c\x95\x9e\xa7"
  7804. "\xb0\xb9\xc2\xcb\xd4\xdd\xe6\xef"
  7805. "\xf8\x01\x0a\x13\x1c\x25\x2e\x37"
  7806. "\x40\x49\x52\x5b\x64\x6d\x76\x7f"
  7807. "\x88\x91\x9a\xa3\xac\xb5\xbe\xc7"
  7808. "\xd0\xd9\xe2\xeb\xf4\xfd\x06\x0f"
  7809. "\x18\x21\x2a\x33\x3c\x45\x4e\x57"
  7810. "\x60\x69\x72\x7b\x84\x8d\x96\x9f"
  7811. "\xa8\xb1\xba\xc3\xcc\xd5\xde\xe7"
  7812. "\xf0\xf9\x02\x0b\x14\x1d\x26\x2f"
  7813. "\x38\x41\x4a\x53\x5c\x65\x6e\x77"
  7814. "\x80\x89\x92\x9b\xa4\xad\xb6\xbf"
  7815. "\xc8\xd1\xda\xe3\xec\xf5\xfe\x07"
  7816. "\x10\x19\x22\x2b\x34\x3d\x46\x4f"
  7817. "\x58\x61\x6a\x73\x7c\x85\x8e\x97"
  7818. "\xa0\xa9\xb2\xbb\xc4\xcd\xd6\xdf"
  7819. "\xe8\xf1\xfa\x03\x0c\x15\x1e\x27"
  7820. "\x30\x39\x42\x4b\x54\x5d\x66\x6f"
  7821. "\x78\x81\x8a\x93\x9c\xa5\xae\xb7"
  7822. "\xc0\xc9\xd2\xdb\xe4\xed\xf6\xff"
  7823. "\x08\x11\x1a\x23\x2c\x35\x3e\x47"
  7824. "\x50\x59\x62\x6b\x74\x7d\x86\x8f"
  7825. "\x98\xa1\xaa\xb3\xbc\xc5\xce\xd7"
  7826. "\xe0\xe9\xf2\xfb\x04\x0d\x16\x1f"
  7827. "\x28\x31\x3a\x43\x4c\x55\x5e\x67"
  7828. "\x70\x79\x82\x8b\x94\x9d\xa6\xaf"
  7829. "\xb8\xc1\xca\xd3\xdc\xe5\xee\xf7"
  7830. "\x00\x0b\x16\x21\x2c\x37\x42\x4d"
  7831. "\x58\x63\x6e\x79\x84\x8f\x9a\xa5"
  7832. "\xb0\xbb\xc6\xd1\xdc\xe7\xf2\xfd"
  7833. "\x08\x13\x1e\x29\x34\x3f\x4a\x55"
  7834. "\x60\x6b\x76\x81\x8c\x97\xa2\xad"
  7835. "\xb8\xc3\xce\xd9\xe4\xef\xfa\x05"
  7836. "\x10\x1b\x26\x31\x3c\x47\x52\x5d"
  7837. "\x68\x73\x7e\x89\x94\x9f\xaa\xb5"
  7838. "\xc0\xcb\xd6\xe1\xec\xf7\x02\x0d"
  7839. "\x18\x23\x2e\x39\x44\x4f\x5a\x65"
  7840. "\x70\x7b\x86\x91\x9c\xa7\xb2\xbd"
  7841. "\xc8\xd3\xde\xe9\xf4\xff\x0a\x15"
  7842. "\x20\x2b\x36\x41\x4c\x57\x62\x6d"
  7843. "\x78\x83\x8e\x99\xa4\xaf\xba\xc5"
  7844. "\xd0\xdb\xe6\xf1\xfc\x07\x12\x1d"
  7845. "\x28\x33\x3e\x49\x54\x5f\x6a\x75"
  7846. "\x80\x8b\x96\xa1\xac\xb7\xc2\xcd"
  7847. "\xd8\xe3\xee\xf9\x04\x0f\x1a\x25"
  7848. "\x30\x3b\x46\x51\x5c\x67\x72\x7d"
  7849. "\x88\x93\x9e\xa9\xb4\xbf\xca\xd5"
  7850. "\xe0\xeb\xf6\x01\x0c\x17\x22\x2d"
  7851. "\x38\x43\x4e\x59\x64\x6f\x7a\x85"
  7852. "\x90\x9b\xa6\xb1\xbc\xc7\xd2\xdd"
  7853. "\xe8\xf3\xfe\x09\x14\x1f\x2a\x35"
  7854. "\x40\x4b\x56\x61\x6c\x77\x82\x8d"
  7855. "\x98\xa3\xae\xb9\xc4\xcf\xda\xe5"
  7856. "\xf0\xfb\x06\x11\x1c\x27\x32\x3d"
  7857. "\x48\x53\x5e\x69\x74\x7f\x8a\x95"
  7858. "\xa0\xab\xb6\xc1\xcc\xd7\xe2\xed"
  7859. "\xf8\x03\x0e\x19\x24\x2f\x3a\x45"
  7860. "\x50\x5b\x66\x71\x7c\x87\x92\x9d"
  7861. "\xa8\xb3\xbe\xc9\xd4\xdf\xea\xf5"
  7862. "\x00\x0d\x1a\x27\x34\x41\x4e\x5b"
  7863. "\x68\x75\x82\x8f\x9c\xa9\xb6\xc3"
  7864. "\xd0\xdd\xea\xf7\x04\x11\x1e\x2b"
  7865. "\x38\x45\x52\x5f\x6c\x79\x86\x93"
  7866. "\xa0\xad\xba\xc7\xd4\xe1\xee\xfb"
  7867. "\x08\x15\x22\x2f\x3c\x49\x56\x63"
  7868. "\x70\x7d\x8a\x97\xa4\xb1\xbe\xcb"
  7869. "\xd8\xe5\xf2\xff\x0c\x19\x26\x33"
  7870. "\x40\x4d\x5a\x67\x74\x81\x8e\x9b"
  7871. "\xa8\xb5\xc2\xcf\xdc\xe9\xf6\x03"
  7872. "\x10\x1d\x2a\x37\x44\x51\x5e\x6b"
  7873. "\x78\x85\x92\x9f\xac\xb9\xc6\xd3"
  7874. "\xe0\xed\xfa\x07\x14\x21\x2e\x3b"
  7875. "\x48\x55\x62\x6f\x7c\x89\x96\xa3"
  7876. "\xb0\xbd\xca\xd7\xe4\xf1\xfe\x0b"
  7877. "\x18\x25\x32\x3f\x4c\x59\x66\x73"
  7878. "\x80\x8d\x9a\xa7\xb4\xc1\xce\xdb"
  7879. "\xe8\xf5\x02\x0f\x1c\x29\x36\x43"
  7880. "\x50\x5d\x6a\x77\x84\x91\x9e\xab"
  7881. "\xb8\xc5\xd2\xdf\xec\xf9\x06\x13"
  7882. "\x20\x2d\x3a\x47\x54\x61\x6e\x7b"
  7883. "\x88\x95\xa2\xaf\xbc\xc9\xd6\xe3"
  7884. "\xf0\xfd\x0a\x17\x24\x31\x3e\x4b"
  7885. "\x58\x65\x72\x7f\x8c\x99\xa6\xb3"
  7886. "\xc0\xcd\xda\xe7\xf4\x01\x0e\x1b"
  7887. "\x28\x35\x42\x4f\x5c\x69\x76\x83"
  7888. "\x90\x9d\xaa\xb7\xc4\xd1\xde\xeb"
  7889. "\xf8\x05\x12\x1f\x2c\x39\x46\x53"
  7890. "\x60\x6d\x7a\x87\x94\xa1\xae\xbb"
  7891. "\xc8\xd5\xe2\xef\xfc\x09\x16\x23"
  7892. "\x30\x3d\x4a\x57\x64\x71\x7e\x8b"
  7893. "\x98\xa5\xb2\xbf\xcc\xd9\xe6\xf3"
  7894. "\x00\x0f\x1e\x2d\x3c\x4b\x5a\x69"
  7895. "\x78\x87\x96\xa5\xb4\xc3\xd2\xe1"
  7896. "\xf0\xff\x0e\x1d\x2c\x3b\x4a\x59"
  7897. "\x68\x77\x86\x95\xa4\xb3\xc2\xd1"
  7898. "\xe0\xef\xfe\x0d\x1c\x2b\x3a\x49"
  7899. "\x58\x67\x76\x85\x94\xa3\xb2\xc1"
  7900. "\xd0\xdf\xee\xfd\x0c\x1b\x2a\x39"
  7901. "\x48\x57\x66\x75\x84\x93\xa2\xb1"
  7902. "\xc0\xcf\xde\xed\xfc\x0b\x1a\x29"
  7903. "\x38\x47\x56\x65\x74\x83\x92\xa1"
  7904. "\xb0\xbf\xce\xdd\xec\xfb\x0a\x19"
  7905. "\x28\x37\x46\x55\x64\x73\x82\x91"
  7906. "\xa0\xaf\xbe\xcd\xdc\xeb\xfa\x09"
  7907. "\x18\x27\x36\x45\x54\x63\x72\x81"
  7908. "\x90\x9f\xae\xbd\xcc\xdb\xea\xf9"
  7909. "\x08\x17\x26\x35\x44\x53\x62\x71"
  7910. "\x80\x8f\x9e\xad\xbc\xcb\xda\xe9"
  7911. "\xf8\x07\x16\x25\x34\x43\x52\x61"
  7912. "\x70\x7f\x8e\x9d\xac\xbb\xca\xd9"
  7913. "\xe8\xf7\x06\x15\x24\x33\x42\x51"
  7914. "\x60\x6f\x7e\x8d\x9c\xab\xba\xc9"
  7915. "\xd8\xe7\xf6\x05\x14\x23\x32\x41"
  7916. "\x50\x5f\x6e\x7d\x8c\x9b\xaa\xb9"
  7917. "\xc8\xd7\xe6\xf5\x04\x13\x22\x31"
  7918. "\x40\x4f\x5e\x6d\x7c\x8b\x9a\xa9"
  7919. "\xb8\xc7\xd6\xe5\xf4\x03\x12\x21"
  7920. "\x30\x3f\x4e\x5d\x6c\x7b\x8a\x99"
  7921. "\xa8\xb7\xc6\xd5\xe4\xf3\x02\x11"
  7922. "\x20\x2f\x3e\x4d\x5c\x6b\x7a\x89"
  7923. "\x98\xa7\xb6\xc5\xd4\xe3\xf2\x01"
  7924. "\x10\x1f\x2e\x3d\x4c\x5b\x6a\x79"
  7925. "\x88\x97\xa6\xb5\xc4\xd3\xe2\xf1"
  7926. "\x00\x11\x22\x33\x44\x55\x66\x77"
  7927. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff"
  7928. "\x10\x21\x32\x43\x54\x65\x76\x87"
  7929. "\x98\xa9\xba\xcb\xdc\xed\xfe\x0f"
  7930. "\x20\x31\x42\x53\x64\x75\x86\x97"
  7931. "\xa8\xb9\xca\xdb\xec\xfd\x0e\x1f"
  7932. "\x30\x41\x52\x63\x74\x85\x96\xa7"
  7933. "\xb8\xc9\xda\xeb\xfc\x0d\x1e\x2f"
  7934. "\x40\x51\x62\x73\x84\x95\xa6\xb7"
  7935. "\xc8\xd9\xea\xfb\x0c\x1d\x2e\x3f"
  7936. "\x50\x61\x72\x83\x94\xa5\xb6\xc7"
  7937. "\xd8\xe9\xfa\x0b\x1c\x2d\x3e\x4f"
  7938. "\x60\x71\x82\x93\xa4\xb5\xc6\xd7"
  7939. "\xe8\xf9\x0a\x1b\x2c\x3d\x4e\x5f"
  7940. "\x70\x81\x92\xa3\xb4\xc5\xd6\xe7"
  7941. "\xf8\x09\x1a\x2b\x3c\x4d\x5e\x6f"
  7942. "\x80\x91\xa2\xb3\xc4\xd5\xe6\xf7"
  7943. "\x08\x19\x2a\x3b\x4c\x5d\x6e\x7f"
  7944. "\x90\xa1\xb2\xc3\xd4\xe5\xf6\x07"
  7945. "\x18\x29\x3a\x4b\x5c\x6d\x7e\x8f"
  7946. "\xa0\xb1\xc2\xd3\xe4\xf5\x06\x17"
  7947. "\x28\x39\x4a\x5b\x6c\x7d\x8e\x9f"
  7948. "\xb0\xc1\xd2\xe3\xf4\x05\x16\x27"
  7949. "\x38\x49\x5a\x6b\x7c\x8d\x9e\xaf"
  7950. "\xc0\xd1\xe2\xf3\x04\x15\x26\x37"
  7951. "\x48\x59\x6a\x7b\x8c\x9d\xae\xbf"
  7952. "\xd0\xe1\xf2\x03\x14\x25\x36\x47"
  7953. "\x58\x69\x7a\x8b\x9c\xad\xbe\xcf"
  7954. "\xe0\xf1\x02\x13\x24\x35\x46\x57"
  7955. "\x68\x79\x8a\x9b\xac\xbd\xce\xdf"
  7956. "\xf0\x01\x12\x23\x34\x45\x56\x67"
  7957. "\x78\x89\x9a\xab\xbc\xcd\xde\xef"
  7958. "\x00\x13\x26\x39\x4c\x5f\x72\x85"
  7959. "\x98\xab\xbe\xd1\xe4\xf7\x0a\x1d"
  7960. "\x30\x43\x56\x69\x7c\x8f\xa2\xb5"
  7961. "\xc8\xdb\xee\x01\x14\x27\x3a\x4d"
  7962. "\x60\x73\x86\x99\xac\xbf\xd2\xe5"
  7963. "\xf8\x0b\x1e\x31\x44\x57\x6a\x7d"
  7964. "\x90\xa3\xb6\xc9\xdc\xef\x02\x15"
  7965. "\x28\x3b\x4e\x61\x74\x87\x9a\xad"
  7966. "\xc0\xd3\xe6\xf9\x0c\x1f\x32\x45"
  7967. "\x58\x6b\x7e\x91\xa4\xb7\xca\xdd"
  7968. "\xf0\x03\x16\x29\x3c\x4f\x62\x75"
  7969. "\x88\x9b\xae\xc1\xd4\xe7\xfa\x0d"
  7970. "\x20\x33\x46\x59\x6c\x7f\x92\xa5"
  7971. "\xb8\xcb\xde\xf1\x04\x17\x2a\x3d"
  7972. "\x50\x63\x76\x89\x9c\xaf\xc2\xd5"
  7973. "\xe8\xfb\x0e\x21\x34\x47\x5a\x6d"
  7974. "\x80\x93\xa6\xb9\xcc\xdf\xf2\x05"
  7975. "\x18\x2b\x3e\x51\x64\x77\x8a\x9d"
  7976. "\xb0\xc3\xd6\xe9\xfc\x0f\x22\x35"
  7977. "\x48\x5b\x6e\x81\x94\xa7\xba\xcd"
  7978. "\xe0\xf3\x06\x19\x2c\x3f\x52\x65"
  7979. "\x78\x8b\x9e\xb1\xc4\xd7\xea\xfd"
  7980. "\x10\x23\x36\x49\x5c\x6f\x82\x95"
  7981. "\xa8\xbb\xce\xe1\xf4\x07\x1a\x2d"
  7982. "\x40\x53\x66\x79\x8c\x9f\xb2\xc5"
  7983. "\xd8\xeb\xfe\x11\x24\x37\x4a\x5d"
  7984. "\x70\x83\x96\xa9\xbc\xcf\xe2\xf5"
  7985. "\x08\x1b\x2e\x41\x54\x67\x7a\x8d"
  7986. "\xa0\xb3\xc6\xd9\xec\xff\x12\x25"
  7987. "\x38\x4b\x5e\x71\x84\x97\xaa\xbd"
  7988. "\xd0\xe3\xf6\x09\x1c\x2f\x42\x55"
  7989. "\x68\x7b\x8e\xa1\xb4\xc7\xda\xed"
  7990. "\x00\x15\x2a\x3f\x54\x69\x7e\x93"
  7991. "\xa8\xbd\xd2\xe7\xfc\x11\x26\x3b"
  7992. "\x50\x65\x7a\x8f\xa4\xb9\xce\xe3"
  7993. "\xf8\x0d\x22\x37\x4c\x61\x76\x8b"
  7994. "\xa0\xb5\xca\xdf\xf4\x09\x1e\x33"
  7995. "\x48\x5d\x72\x87\x9c\xb1\xc6\xdb"
  7996. "\xf0\x05\x1a\x2f\x44\x59\x6e\x83"
  7997. "\x98\xad\xc2\xd7\xec\x01\x16\x2b"
  7998. "\x40\x55\x6a\x7f\x94\xa9\xbe\xd3"
  7999. "\xe8\xfd\x12\x27\x3c\x51\x66\x7b"
  8000. "\x90\xa5\xba\xcf\xe4\xf9\x0e\x23"
  8001. "\x38\x4d\x62\x77\x8c\xa1\xb6\xcb"
  8002. "\xe0\xf5\x0a\x1f\x34\x49\x5e\x73"
  8003. "\x88\x9d\xb2\xc7\xdc\xf1\x06\x1b"
  8004. "\x30\x45\x5a\x6f\x84\x99\xae\xc3"
  8005. "\xd8\xed\x02\x17\x2c\x41\x56\x6b"
  8006. "\x80\x95\xaa\xbf\xd4\xe9\xfe\x13"
  8007. "\x28\x3d\x52\x67\x7c\x91\xa6\xbb"
  8008. "\xd0\xe5\xfa\x0f\x24\x39\x4e\x63"
  8009. "\x78\x8d\xa2\xb7\xcc\xe1\xf6\x0b"
  8010. "\x20\x35\x4a\x5f\x74\x89\x9e\xb3"
  8011. "\xc8\xdd\xf2\x07\x1c\x31\x46\x5b"
  8012. "\x70\x85\x9a\xaf\xc4\xd9\xee\x03"
  8013. "\x18\x2d\x42\x57\x6c\x81\x96\xab"
  8014. "\xc0\xd5\xea\xff\x14\x29\x3e\x53"
  8015. "\x68\x7d\x92\xa7\xbc\xd1\xe6\xfb"
  8016. "\x10\x25\x3a\x4f\x64\x79\x8e\xa3"
  8017. "\xb8\xcd\xe2\xf7\x0c\x21\x36\x4b"
  8018. "\x60\x75\x8a\x9f\xb4\xc9\xde\xf3"
  8019. "\x08\x1d\x32\x47\x5c\x71\x86\x9b"
  8020. "\xb0\xc5\xda\xef\x04\x19\x2e\x43"
  8021. "\x58\x6d\x82\x97\xac\xc1\xd6\xeb"
  8022. "\x00\x17\x2e\x45\x5c\x73\x8a\xa1"
  8023. "\xb8\xcf\xe6\xfd\x14\x2b\x42\x59"
  8024. "\x70\x87\x9e\xb5\xcc\xe3\xfa\x11"
  8025. "\x28\x3f\x56\x6d\x84\x9b\xb2\xc9"
  8026. "\xe0\xf7\x0e\x25\x3c\x53\x6a\x81"
  8027. "\x98\xaf\xc6\xdd\xf4\x0b\x22\x39"
  8028. "\x50\x67\x7e\x95\xac\xc3\xda\xf1"
  8029. "\x08\x1f\x36\x4d\x64\x7b\x92\xa9"
  8030. "\xc0\xd7\xee\x05\x1c\x33\x4a\x61"
  8031. "\x78\x8f\xa6\xbd\xd4\xeb\x02\x19"
  8032. "\x30\x47\x5e\x75\x8c\xa3\xba\xd1"
  8033. "\xe8\xff\x16\x2d\x44\x5b\x72\x89"
  8034. "\xa0\xb7\xce\xe5\xfc\x13\x2a\x41"
  8035. "\x58\x6f\x86\x9d\xb4\xcb\xe2\xf9"
  8036. "\x10\x27\x3e\x55\x6c\x83\x9a\xb1"
  8037. "\xc8\xdf\xf6\x0d\x24\x3b\x52\x69"
  8038. "\x80\x97\xae\xc5\xdc\xf3\x0a\x21"
  8039. "\x38\x4f\x66\x7d\x94\xab\xc2\xd9"
  8040. "\xf0\x07\x1e\x35\x4c\x63\x7a\x91"
  8041. "\xa8\xbf\xd6\xed\x04\x1b\x32\x49"
  8042. "\x60\x77\x8e\xa5\xbc\xd3\xea\x01"
  8043. "\x18\x2f\x46\x5d\x74\x8b\xa2\xb9"
  8044. "\xd0\xe7\xfe\x15\x2c\x43\x5a\x71"
  8045. "\x88\x9f\xb6\xcd\xe4\xfb\x12\x29"
  8046. "\x40\x57\x6e\x85\x9c\xb3\xca\xe1"
  8047. "\xf8\x0f\x26\x3d\x54\x6b\x82\x99"
  8048. "\xb0\xc7\xde\xf5\x0c\x23\x3a\x51"
  8049. "\x68\x7f\x96\xad\xc4\xdb\xf2\x09"
  8050. "\x20\x37\x4e\x65\x7c\x93\xaa\xc1"
  8051. "\xd8\xef\x06\x1d\x34\x4b\x62\x79"
  8052. "\x90\xa7\xbe\xd5\xec\x03\x1a\x31"
  8053. "\x48\x5f\x76\x8d\xa4\xbb\xd2\xe9"
  8054. "\x00\x19\x32\x4b\x64\x7d\x96\xaf"
  8055. "\xc8\xe1\xfa\x13\x2c\x45\x5e\x77"
  8056. "\x90\xa9\xc2\xdb\xf4\x0d\x26\x3f"
  8057. "\x58\x71\x8a\xa3\xbc\xd5\xee\x07"
  8058. "\x20\x39\x52\x6b\x84\x9d\xb6\xcf"
  8059. "\xe8\x01\x1a\x33\x4c\x65\x7e\x97"
  8060. "\xb0\xc9\xe2\xfb\x14\x2d\x46\x5f"
  8061. "\x78\x91\xaa\xc3\xdc\xf5\x0e\x27"
  8062. "\x40\x59\x72\x8b\xa4\xbd\xd6\xef"
  8063. "\x08\x21\x3a\x53\x6c\x85\x9e\xb7"
  8064. "\xd0\xe9\x02\x1b\x34\x4d\x66\x7f"
  8065. "\x98\xb1\xca\xe3\xfc\x15\x2e\x47"
  8066. "\x60\x79\x92\xab\xc4\xdd\xf6\x0f"
  8067. "\x28\x41\x5a\x73\x8c\xa5\xbe\xd7"
  8068. "\xf0\x09\x22\x3b\x54\x6d\x86\x9f"
  8069. "\xb8\xd1\xea\x03\x1c\x35\x4e\x67"
  8070. "\x80\x99\xb2\xcb\xe4\xfd\x16\x2f"
  8071. "\x48\x61\x7a\x93\xac\xc5\xde\xf7"
  8072. "\x10\x29\x42\x5b\x74\x8d\xa6\xbf"
  8073. "\xd8\xf1\x0a\x23\x3c\x55\x6e\x87"
  8074. "\xa0\xb9\xd2\xeb\x04\x1d\x36\x4f"
  8075. "\x68\x81\x9a\xb3\xcc\xe5\xfe\x17"
  8076. "\x30\x49\x62\x7b\x94\xad\xc6\xdf"
  8077. "\xf8\x11\x2a\x43\x5c\x75\x8e\xa7"
  8078. "\xc0\xd9\xf2\x0b\x24\x3d\x56\x6f"
  8079. "\x88\xa1\xba\xd3\xec\x05\x1e\x37"
  8080. "\x50\x69\x82\x9b\xb4\xcd\xe6\xff"
  8081. "\x18\x31\x4a\x63\x7c\x95\xae\xc7"
  8082. "\xe0\xf9\x12\x2b\x44\x5d\x76\x8f"
  8083. "\xa8\xc1\xda\xf3\x0c\x25\x3e\x57"
  8084. "\x70\x89\xa2\xbb\xd4\xed\x06\x1f"
  8085. "\x38\x51\x6a\x83\x9c\xb5\xce\xe7"
  8086. "\x00\x1b\x36\x51\x6c\x87\xa2\xbd"
  8087. "\xd8\xf3\x0e\x29\x44\x5f\x7a\x95"
  8088. "\xb0\xcb\xe6\x01\x1c\x37\x52\x6d"
  8089. "\x88\xa3\xbe\xd9\xf4\x0f\x2a\x45"
  8090. "\x60\x7b\x96\xb1\xcc\xe7\x02\x1d"
  8091. "\x38\x53\x6e\x89\xa4\xbf\xda\xf5"
  8092. "\x10\x2b\x46\x61\x7c\x97\xb2\xcd"
  8093. "\xe8\x03\x1e\x39\x54\x6f\x8a\xa5"
  8094. "\xc0\xdb\xf6\x11\x2c\x47\x62\x7d"
  8095. "\x98\xb3\xce\xe9\x04\x1f\x3a\x55"
  8096. "\x70\x8b\xa6\xc1\xdc\xf7\x12\x2d"
  8097. "\x48\x63\x7e\x99\xb4\xcf\xea\x05"
  8098. "\x20\x3b\x56\x71\x8c\xa7\xc2\xdd"
  8099. "\xf8\x13\x2e\x49\x64\x7f\x9a\xb5"
  8100. "\xd0\xeb\x06\x21\x3c\x57\x72\x8d"
  8101. "\xa8\xc3\xde\xf9\x14\x2f\x4a\x65"
  8102. "\x80\x9b\xb6\xd1\xec\x07\x22\x3d"
  8103. "\x58\x73\x8e\xa9\xc4\xdf\xfa\x15"
  8104. "\x30\x4b\x66\x81\x9c\xb7\xd2\xed"
  8105. "\x08\x23\x3e\x59\x74\x8f\xaa\xc5"
  8106. "\xe0\xfb\x16\x31\x4c\x67\x82\x9d"
  8107. "\xb8\xd3\xee\x09\x24\x3f\x5a\x75"
  8108. "\x90\xab\xc6\xe1\xfc\x17\x32\x4d"
  8109. "\x68\x83\x9e\xb9\xd4\xef\x0a\x25"
  8110. "\x40\x5b\x76\x91\xac\xc7\xe2\xfd"
  8111. "\x18\x33\x4e\x69\x84\x9f\xba\xd5"
  8112. "\xf0\x0b\x26\x41\x5c\x77\x92\xad"
  8113. "\xc8\xe3\xfe\x19\x34\x4f\x6a\x85"
  8114. "\xa0\xbb\xd6\xf1\x0c\x27\x42\x5d"
  8115. "\x78\x93\xae\xc9\xe4\xff\x1a\x35"
  8116. "\x50\x6b\x86\xa1\xbc\xd7\xf2\x0d"
  8117. "\x28\x43\x5e\x79\x94\xaf\xca\xe5"
  8118. "\x00\x1d\x3a\x57\x74\x91\xae\xcb"
  8119. "\xe8\x05\x22\x3f\x5c\x79\x96\xb3"
  8120. "\xd0\xed\x0a\x27\x44\x61\x7e\x9b"
  8121. "\xb8\xd5\xf2\x0f\x2c\x49\x66\x83"
  8122. "\xa0\xbd\xda\xf7\x14\x31\x4e\x6b"
  8123. "\x88\xa5\xc2\xdf\xfc\x19\x36\x53"
  8124. "\x70\x8d\xaa\xc7\xe4\x01\x1e\x3b"
  8125. "\x58\x75\x92\xaf\xcc\xe9\x06\x23"
  8126. "\x40\x5d\x7a\x97\xb4\xd1\xee\x0b"
  8127. "\x28\x45\x62\x7f\x9c\xb9\xd6\xf3"
  8128. "\x10\x2d\x4a\x67\x84\xa1\xbe\xdb"
  8129. "\xf8\x15\x32\x4f\x6c\x89\xa6\xc3"
  8130. "\xe0\xfd\x1a\x37\x54\x71\x8e\xab"
  8131. "\xc8\xe5\x02\x1f\x3c\x59\x76\x93"
  8132. "\xb0\xcd\xea\x07\x24\x41\x5e\x7b"
  8133. "\x98\xb5\xd2\xef\x0c\x29\x46\x63"
  8134. "\x80\x9d\xba\xd7\xf4\x11\x2e\x4b"
  8135. "\x68\x85\xa2\xbf\xdc\xf9\x16\x33"
  8136. "\x50\x6d\x8a\xa7\xc4\xe1\xfe\x1b"
  8137. "\x38\x55\x72\x8f\xac\xc9\xe6\x03"
  8138. "\x20\x3d\x5a\x77\x94\xb1\xce\xeb"
  8139. "\x08\x25\x42\x5f\x7c\x99\xb6\xd3"
  8140. "\xf0\x0d\x2a\x47\x64\x81\x9e\xbb"
  8141. "\xd8\xf5\x12\x2f\x4c\x69\x86\xa3"
  8142. "\xc0\xdd\xfa\x17\x34\x51\x6e\x8b"
  8143. "\xa8\xc5\xe2\xff\x1c\x39\x56\x73"
  8144. "\x90\xad\xca\xe7\x04\x21\x3e\x5b"
  8145. "\x78\x95\xb2\xcf\xec\x09\x26\x43"
  8146. "\x60\x7d\x9a\xb7\xd4\xf1\x0e\x2b"
  8147. "\x48\x65\x82\x9f\xbc\xd9\xf6\x13"
  8148. "\x30\x4d\x6a\x87\xa4\xc1\xde\xfb"
  8149. "\x18\x35\x52\x6f\x8c\xa9\xc6\xe3"
  8150. "\x00\x1f\x3e\x5d\x7c\x9b\xba\xd9"
  8151. "\xf8\x17\x36\x55\x74\x93\xb2\xd1"
  8152. "\xf0\x0f\x2e\x4d\x6c\x8b\xaa\xc9"
  8153. "\xe8\x07\x26\x45\x64\x83\xa2\xc1"
  8154. "\xe0\xff\x1e\x3d\x5c\x7b\x9a\xb9"
  8155. "\xd8\xf7\x16\x35\x54\x73\x92\xb1"
  8156. "\xd0\xef\x0e\x2d\x4c\x6b\x8a\xa9"
  8157. "\xc8\xe7\x06\x25\x44\x63\x82\xa1"
  8158. "\xc0\xdf\xfe\x1d\x3c\x5b\x7a\x99"
  8159. "\xb8\xd7\xf6\x15\x34\x53\x72\x91"
  8160. "\xb0\xcf\xee\x0d\x2c\x4b\x6a\x89"
  8161. "\xa8\xc7\xe6\x05\x24\x43\x62\x81"
  8162. "\xa0\xbf\xde\xfd\x1c\x3b\x5a\x79"
  8163. "\x98\xb7\xd6\xf5\x14\x33\x52\x71"
  8164. "\x90\xaf\xce\xed\x0c\x2b\x4a\x69"
  8165. "\x88\xa7\xc6\xe5\x04\x23\x42\x61"
  8166. "\x80\x9f\xbe\xdd\xfc\x1b\x3a\x59"
  8167. "\x78\x97\xb6\xd5\xf4\x13\x32\x51"
  8168. "\x70\x8f\xae\xcd\xec\x0b\x2a\x49"
  8169. "\x68\x87\xa6\xc5\xe4\x03\x22\x41"
  8170. "\x60\x7f\x9e\xbd\xdc\xfb\x1a\x39"
  8171. "\x58\x77\x96\xb5\xd4\xf3\x12\x31"
  8172. "\x50\x6f\x8e\xad\xcc\xeb\x0a\x29"
  8173. "\x48\x67\x86\xa5\xc4\xe3\x02\x21"
  8174. "\x40\x5f\x7e\x9d\xbc\xdb\xfa\x19"
  8175. "\x38\x57\x76\x95\xb4\xd3\xf2\x11"
  8176. "\x30\x4f\x6e\x8d\xac\xcb\xea\x09"
  8177. "\x28\x47\x66\x85\xa4\xc3\xe2\x01"
  8178. "\x20\x3f\x5e\x7d\x9c\xbb\xda\xf9"
  8179. "\x18\x37\x56\x75\x94\xb3\xd2\xf1"
  8180. "\x10\x2f\x4e\x6d\x8c\xab\xca\xe9"
  8181. "\x08\x27\x46\x65\x84\xa3\xc2\xe1"
  8182. "\x00\x21\x42\x63",
  8183. .ilen = 4100,
  8184. .result =
  8185. "\xf0\x5c\x74\xad\x4e\xbc\x99\xe2"
  8186. "\xae\xff\x91\x3a\x44\xcf\x38\x32"
  8187. "\x1e\xad\xa7\xcd\xa1\x39\x95\xaa"
  8188. "\x10\xb1\xb3\x2e\x04\x31\x8f\x86"
  8189. "\xf2\x62\x74\x70\x0c\xa4\x46\x08"
  8190. "\xa8\xb7\x99\xa8\xe9\xd2\x73\x79"
  8191. "\x7e\x6e\xd4\x8f\x1e\xc7\x8e\x31"
  8192. "\x0b\xfa\x4b\xce\xfd\xf3\x57\x71"
  8193. "\xe9\x46\x03\xa5\x3d\x34\x00\xe2"
  8194. "\x18\xff\x75\x6d\x06\x2d\x00\xab"
  8195. "\xb9\x3e\x6c\x59\xc5\x84\x06\xb5"
  8196. "\x8b\xd0\x89\x9c\x4a\x79\x16\xc6"
  8197. "\x3d\x74\x54\xfa\x44\xcd\x23\x26"
  8198. "\x5c\xcf\x7e\x28\x92\x32\xbf\xdf"
  8199. "\xa7\x20\x3c\x74\x58\x2a\x9a\xde"
  8200. "\x61\x00\x1c\x4f\xff\x59\xc4\x22"
  8201. "\xac\x3c\xd0\xe8\x6c\xf9\x97\x1b"
  8202. "\x58\x9b\xad\x71\xe8\xa9\xb5\x0d"
  8203. "\xee\x2f\x04\x1f\x7f\xbc\x99\xee"
  8204. "\x84\xff\x42\x60\xdc\x3a\x18\xa5"
  8205. "\x81\xf9\xef\xdc\x7a\x0f\x65\x41"
  8206. "\x2f\xa3\xd3\xf9\xc2\xcb\xc0\x4d"
  8207. "\x8f\xd3\x76\x96\xad\x49\x6d\x38"
  8208. "\x3d\x39\x0b\x6c\x80\xb7\x54\x69"
  8209. "\xf0\x2c\x90\x02\x29\x0d\x1c\x12"
  8210. "\xad\x55\xc3\x8b\x68\xd9\xcc\xb3"
  8211. "\xb2\x64\x33\x90\x5e\xca\x4b\xe2"
  8212. "\xfb\x75\xdc\x63\xf7\x9f\x82\x74"
  8213. "\xf0\xc9\xaa\x7f\xe9\x2a\x9b\x33"
  8214. "\xbc\x88\x00\x7f\xca\xb2\x1f\x14"
  8215. "\xdb\xc5\x8e\x7b\x11\x3c\x3e\x08"
  8216. "\xf3\x83\xe8\xe0\x94\x86\x2e\x92"
  8217. "\x78\x6b\x01\xc9\xc7\x83\xba\x21"
  8218. "\x6a\x25\x15\x33\x4e\x45\x08\xec"
  8219. "\x35\xdb\xe0\x6e\x31\x51\x79\xa9"
  8220. "\x42\x44\x65\xc1\xa0\xf1\xf9\x2a"
  8221. "\x70\xd5\xb6\xc6\xc1\x8c\x39\xfc"
  8222. "\x25\xa6\x55\xd9\xdd\x2d\x4c\xec"
  8223. "\x49\xc6\xeb\x0e\xa8\x25\x2a\x16"
  8224. "\x1b\x66\x84\xda\xe2\x92\xe5\xc0"
  8225. "\xc8\x53\x07\xaf\x80\x84\xec\xfd"
  8226. "\xcd\xd1\x6e\xcd\x6f\x6a\xf5\x36"
  8227. "\xc5\x15\xe5\x25\x7d\x77\xd1\x1a"
  8228. "\x93\x36\xa9\xcf\x7c\xa4\x54\x4a"
  8229. "\x06\x51\x48\x4e\xf6\x59\x87\xd2"
  8230. "\x04\x02\xef\xd3\x44\xde\x76\x31"
  8231. "\xb3\x34\x17\x1b\x9d\x66\x11\x9f"
  8232. "\x1e\xcc\x17\xe9\xc7\x3c\x1b\xe7"
  8233. "\xcb\x50\x08\xfc\xdc\x2b\x24\xdb"
  8234. "\x65\x83\xd0\x3b\xe3\x30\xea\x94"
  8235. "\x6c\xe7\xe8\x35\x32\xc7\xdb\x64"
  8236. "\xb4\x01\xab\x36\x2c\x77\x13\xaf"
  8237. "\xf8\x2b\x88\x3f\x54\x39\xc4\x44"
  8238. "\xfe\xef\x6f\x68\x34\xbe\x0f\x05"
  8239. "\x16\x6d\xf6\x0a\x30\xe7\xe3\xed"
  8240. "\xc4\xde\x3c\x1b\x13\xd8\xdb\xfe"
  8241. "\x41\x62\xe5\x28\xd4\x8d\xa3\xc7"
  8242. "\x93\x97\xc6\x48\x45\x1d\x9f\x83"
  8243. "\xdf\x4b\x40\x3e\x42\x25\x87\x80"
  8244. "\x4c\x7d\xa8\xd4\x98\x23\x95\x75"
  8245. "\x41\x8c\xda\x41\x9b\xd4\xa7\x06"
  8246. "\xb5\xf1\x71\x09\x53\xbe\xca\xbf"
  8247. "\x32\x03\xed\xf0\x50\x1c\x56\x39"
  8248. "\x5b\xa4\x75\x18\xf7\x9b\x58\xef"
  8249. "\x53\xfc\x2a\x38\x23\x15\x75\xcd"
  8250. "\x45\xe5\x5a\x82\x55\xba\x21\xfa"
  8251. "\xd4\xbd\xc6\x94\x7c\xc5\x80\x12"
  8252. "\xf7\x4b\x32\xc4\x9a\x82\xd8\x28"
  8253. "\x8f\xd9\xc2\x0f\x60\x03\xbe\x5e"
  8254. "\x21\xd6\x5f\x58\xbf\x5c\xb1\x32"
  8255. "\x82\x8d\xa9\xe5\xf2\x66\x1a\xc0"
  8256. "\xa0\xbc\x58\x2f\x71\xf5\x2f\xed"
  8257. "\xd1\x26\xb9\xd8\x49\x5a\x07\x19"
  8258. "\x01\x7c\x59\xb0\xf8\xa4\xb7\xd3"
  8259. "\x7b\x1a\x8c\x38\xf4\x50\xa4\x59"
  8260. "\xb0\xcc\x41\x0b\x88\x7f\xe5\x31"
  8261. "\xb3\x42\xba\xa2\x7e\xd4\x32\x71"
  8262. "\x45\x87\x48\xa9\xc2\xf2\x89\xb3"
  8263. "\xe4\xa7\x7e\x52\x15\x61\xfa\xfe"
  8264. "\xc9\xdd\x81\xeb\x13\xab\xab\xc3"
  8265. "\x98\x59\xd8\x16\x3d\x14\x7a\x1c"
  8266. "\x3c\x41\x9a\x16\x16\x9b\xd2\xd2"
  8267. "\x69\x3a\x29\x23\xac\x86\x32\xa5"
  8268. "\x48\x9c\x9e\xf3\x47\x77\x81\x70"
  8269. "\x24\xe8\x85\xd2\xf5\xb5\xfa\xff"
  8270. "\x59\x6a\xd3\x50\x59\x43\x59\xde"
  8271. "\xd9\xf1\x55\xa5\x0c\xc3\x1a\x1a"
  8272. "\x18\x34\x0d\x1a\x63\x33\xed\x10"
  8273. "\xe0\x1d\x2a\x18\xd2\xc0\x54\xa8"
  8274. "\xca\xb5\x9a\xd3\xdd\xca\x45\x84"
  8275. "\x50\xe7\x0f\xfe\xa4\x99\x5a\xbe"
  8276. "\x43\x2d\x9a\xcb\x92\x3f\x5a\x1d"
  8277. "\x85\xd8\xc9\xdf\x68\xc9\x12\x80"
  8278. "\x56\x0c\xdc\x00\xdc\x3a\x7d\x9d"
  8279. "\xa3\xa2\xe8\x4d\xbf\xf9\x70\xa0"
  8280. "\xa4\x13\x4f\x6b\xaf\x0a\x89\x7f"
  8281. "\xda\xf0\xbf\x9b\xc8\x1d\xe5\xf8"
  8282. "\x2e\x8b\x07\xb5\x73\x1b\xcc\xa2"
  8283. "\xa6\xad\x30\xbc\x78\x3c\x5b\x10"
  8284. "\xfa\x5e\x62\x2d\x9e\x64\xb3\x33"
  8285. "\xce\xf9\x1f\x86\xe7\x8b\xa2\xb8"
  8286. "\xe8\x99\x57\x8c\x11\xed\x66\xd9"
  8287. "\x3c\x72\xb9\xc3\xe6\x4e\x17\x3a"
  8288. "\x6a\xcb\x42\x24\x06\xed\x3e\x4e"
  8289. "\xa3\xe8\x6a\x94\xda\x0d\x4e\xd5"
  8290. "\x14\x19\xcf\xb6\x26\xd8\x2e\xcc"
  8291. "\x64\x76\x38\x49\x4d\xfe\x30\x6d"
  8292. "\xe4\xc8\x8c\x7b\xc4\xe0\x35\xba"
  8293. "\x22\x6e\x76\xe1\x1a\xf2\x53\xc3"
  8294. "\x28\xa2\x82\x1f\x61\x69\xad\xc1"
  8295. "\x7b\x28\x4b\x1e\x6c\x85\x95\x9b"
  8296. "\x51\xb5\x17\x7f\x12\x69\x8c\x24"
  8297. "\xd5\xc7\x5a\x5a\x11\x54\xff\x5a"
  8298. "\xf7\x16\xc3\x91\xa6\xf0\xdc\x0a"
  8299. "\xb6\xa7\x4a\x0d\x7a\x58\xfe\xa5"
  8300. "\xf5\xcb\x8f\x7b\x0e\xea\x57\xe7"
  8301. "\xbd\x79\xd6\x1c\x88\x23\x6c\xf2"
  8302. "\x4d\x29\x77\x53\x35\x6a\x00\x8d"
  8303. "\xcd\xa3\x58\xbe\x77\x99\x18\xf8"
  8304. "\xe6\xe1\x8f\xe9\x37\x8f\xe3\xe2"
  8305. "\x5a\x8a\x93\x25\xaf\xf3\x78\x80"
  8306. "\xbe\xa6\x1b\xc6\xac\x8b\x1c\x91"
  8307. "\x58\xe1\x9f\x89\x35\x9d\x1d\x21"
  8308. "\x29\x9f\xf4\x99\x02\x27\x0f\xa8"
  8309. "\x4f\x79\x94\x2b\x33\x2c\xda\xa2"
  8310. "\x26\x39\x83\x94\xef\x27\xd8\x53"
  8311. "\x8f\x66\x0d\xe4\x41\x7d\x34\xcd"
  8312. "\x43\x7c\x95\x0a\x53\xef\x66\xda"
  8313. "\x7e\x9b\xf3\x93\xaf\xd0\x73\x71"
  8314. "\xba\x40\x9b\x74\xf8\xd7\xd7\x41"
  8315. "\x6d\xaf\x72\x9c\x8d\x21\x87\x3c"
  8316. "\xfd\x0a\x90\xa9\x47\x96\x9e\xd3"
  8317. "\x88\xee\x73\xcf\x66\x2f\x52\x56"
  8318. "\x6d\xa9\x80\x4c\xe2\x6f\x62\x88"
  8319. "\x3f\x0e\x54\x17\x48\x80\x5d\xd3"
  8320. "\xc3\xda\x25\x3d\xa1\xc8\xcb\x9f"
  8321. "\x9b\x70\xb3\xa1\xeb\x04\x52\xa1"
  8322. "\xf2\x22\x0f\xfc\xc8\x18\xfa\xf9"
  8323. "\x85\x9c\xf1\xac\xeb\x0c\x02\x46"
  8324. "\x75\xd2\xf5\x2c\xe3\xd2\x59\x94"
  8325. "\x12\xf3\x3c\xfc\xd7\x92\xfa\x36"
  8326. "\xba\x61\x34\x38\x7c\xda\x48\x3e"
  8327. "\x08\xc9\x39\x23\x5e\x02\x2c\x1a"
  8328. "\x18\x7e\xb4\xd9\xfd\x9e\x40\x02"
  8329. "\xb1\x33\x37\x32\xe7\xde\xd6\xd0"
  8330. "\x7c\x58\x65\x4b\xf8\x34\x27\x9c"
  8331. "\x44\xb4\xbd\xe9\xe9\x4c\x78\x7d"
  8332. "\x4b\x9f\xce\xb1\xcd\x47\xa5\x37"
  8333. "\xe5\x6d\xbd\xb9\x43\x94\x0a\xd4"
  8334. "\xd6\xf9\x04\x5f\xb5\x66\x6c\x1a"
  8335. "\x35\x12\xe3\x36\x28\x27\x36\x58"
  8336. "\x01\x2b\x79\xe4\xba\x6d\x10\x7d"
  8337. "\x65\xdf\x84\x95\xf4\xd5\xb6\x8f"
  8338. "\x2b\x9f\x96\x00\x86\x60\xf0\x21"
  8339. "\x76\xa8\x6a\x8c\x28\x1c\xb3\x6b"
  8340. "\x97\xd7\xb6\x53\x2a\xcc\xab\x40"
  8341. "\x9d\x62\x79\x58\x52\xe6\x65\xb7"
  8342. "\xab\x55\x67\x9c\x89\x7c\x03\xb0"
  8343. "\x73\x59\xc5\x81\xf5\x18\x17\x5c"
  8344. "\x89\xf3\x78\x35\x44\x62\x78\x72"
  8345. "\xd0\x96\xeb\x31\xe7\x87\x77\x14"
  8346. "\x99\x51\xf2\x59\x26\x9e\xb5\xa6"
  8347. "\x45\xfe\x6e\xbd\x07\x4c\x94\x5a"
  8348. "\xa5\x7d\xfc\xf1\x2b\x77\xe2\xfe"
  8349. "\x17\xd4\x84\xa0\xac\xb5\xc7\xda"
  8350. "\xa9\x1a\xb6\xf3\x74\x11\xb4\x9d"
  8351. "\xfb\x79\x2e\x04\x2d\x50\x28\x83"
  8352. "\xbf\xc6\x52\xd3\x34\xd6\xe8\x7a"
  8353. "\xb6\xea\xe7\xa8\x6c\x15\x1e\x2c"
  8354. "\x57\xbc\x48\x4e\x5f\x5c\xb6\x92"
  8355. "\xd2\x49\x77\x81\x6d\x90\x70\xae"
  8356. "\x98\xa1\x03\x0d\x6b\xb9\x77\x14"
  8357. "\xf1\x4e\x23\xd3\xf8\x68\xbd\xc2"
  8358. "\xfe\x04\xb7\x5c\xc5\x17\x60\x8f"
  8359. "\x65\x54\xa4\x7a\x42\xdc\x18\x0d"
  8360. "\xb5\xcf\x0f\xd3\xc7\x91\x66\x1b"
  8361. "\x45\x42\x27\x75\x50\xe5\xee\xb8"
  8362. "\x7f\x33\x2c\xba\x4a\x92\x4d\x2c"
  8363. "\x3c\xe3\x0d\x80\x01\xba\x0d\x29"
  8364. "\xd8\x3c\xe9\x13\x16\x57\xe6\xea"
  8365. "\x94\x52\xe7\x00\x4d\x30\xb0\x0f"
  8366. "\x35\xb8\xb8\xa7\xb1\xb5\x3b\x44"
  8367. "\xe1\x2f\xfd\x88\xed\x43\xe7\x52"
  8368. "\x10\x93\xb3\x8a\x30\x6b\x0a\xf7"
  8369. "\x23\xc6\x50\x9d\x4a\xb0\xde\xc3"
  8370. "\xdc\x9b\x2f\x01\x56\x36\x09\xc5"
  8371. "\x2f\x6b\xfe\xf1\xd8\x27\x45\x03"
  8372. "\x30\x5e\x5c\x5b\xb4\x62\x0e\x1a"
  8373. "\xa9\x21\x2b\x92\x94\x87\x62\x57"
  8374. "\x4c\x10\x74\x1a\xf1\x0a\xc5\x84"
  8375. "\x3b\x9e\x72\x02\xd7\xcc\x09\x56"
  8376. "\xbd\x54\xc1\xf0\xc3\xe3\xb3\xf8"
  8377. "\xd2\x0d\x61\xcb\xef\xce\x0d\x05"
  8378. "\xb0\x98\xd9\x8e\x4f\xf9\xbc\x93"
  8379. "\xa6\xea\xc8\xcf\x10\x53\x4b\xf1"
  8380. "\xec\xfc\x89\xf9\x64\xb0\x22\xbf"
  8381. "\x9e\x55\x46\x9f\x7c\x50\x8e\x84"
  8382. "\x54\x20\x98\xd7\x6c\x40\x1e\xdb"
  8383. "\x69\x34\x78\x61\x24\x21\x9c\x8a"
  8384. "\xb3\x62\x31\x8b\x6e\xf5\x2a\x35"
  8385. "\x86\x13\xb1\x6c\x64\x2e\x41\xa5"
  8386. "\x05\xf2\x42\xba\xd2\x3a\x0d\x8e"
  8387. "\x8a\x59\x94\x3c\xcf\x36\x27\x82"
  8388. "\xc2\x45\xee\x58\xcd\x88\xb4\xec"
  8389. "\xde\xb2\x96\x0a\xaf\x38\x6f\x88"
  8390. "\xd7\xd8\xe1\xdf\xb9\x96\xa9\x0a"
  8391. "\xb1\x95\x28\x86\x20\xe9\x17\x49"
  8392. "\xa2\x29\x38\xaa\xa5\xe9\x6e\xf1"
  8393. "\x19\x27\xc0\xd5\x2a\x22\xc3\x0b"
  8394. "\xdb\x7c\x73\x10\xb9\xba\x89\x76"
  8395. "\x54\xae\x7d\x71\xb3\x93\xf6\x32"
  8396. "\xe6\x47\x43\x55\xac\xa0\x0d\xc2"
  8397. "\x93\x27\x4a\x8e\x0e\x74\x15\xc7"
  8398. "\x0b\x85\xd9\x0c\xa9\x30\x7a\x3e"
  8399. "\xea\x8f\x85\x6d\x3a\x12\x4f\x72"
  8400. "\x69\x58\x7a\x80\xbb\xb5\x97\xf3"
  8401. "\xcf\x70\xd2\x5d\xdd\x4d\x21\x79"
  8402. "\x54\x4d\xe4\x05\xe8\xbd\xc2\x62"
  8403. "\xb1\x3b\x77\x1c\xd6\x5c\xf3\xa0"
  8404. "\x79\x00\xa8\x6c\x29\xd9\x18\x24"
  8405. "\x36\xa2\x46\xc0\x96\x65\x7f\xbd"
  8406. "\x2a\xed\x36\x16\x0c\xaa\x9f\xf4"
  8407. "\xc5\xb4\xe2\x12\xed\x69\xed\x4f"
  8408. "\x26\x2c\x39\x52\x89\x98\xe7\x2c"
  8409. "\x99\xa4\x9e\xa3\x9b\x99\x46\x7a"
  8410. "\x3a\xdc\xa8\x59\xa3\xdb\xc3\x3b"
  8411. "\x95\x0d\x3b\x09\x6e\xee\x83\x5d"
  8412. "\x32\x4d\xed\xab\xfa\x98\x14\x4e"
  8413. "\xc3\x15\x45\x53\x61\xc4\x93\xbd"
  8414. "\x90\xf4\x99\x95\x4c\xe6\x76\x92"
  8415. "\x29\x90\x46\x30\x92\x69\x7d\x13"
  8416. "\xf2\xa5\xcd\x69\x49\x44\xb2\x0f"
  8417. "\x63\x40\x36\x5f\x09\xe2\x78\xf8"
  8418. "\x91\xe3\xe2\xfa\x10\xf7\xc8\x24"
  8419. "\xa8\x89\x32\x5c\x37\x25\x1d\xb2"
  8420. "\xea\x17\x8a\x0a\xa9\x64\xc3\x7c"
  8421. "\x3c\x7c\xbd\xc6\x79\x34\xe7\xe2"
  8422. "\x85\x8e\xbf\xf8\xde\x92\xa0\xae"
  8423. "\x20\xc4\xf6\xbb\x1f\x38\x19\x0e"
  8424. "\xe8\x79\x9c\xa1\x23\xe9\x54\x7e"
  8425. "\x37\x2f\xe2\x94\x32\xaf\xa0\x23"
  8426. "\x49\xe4\xc0\xb3\xac\x00\x8f\x36"
  8427. "\x05\xc4\xa6\x96\xec\x05\x98\x4f"
  8428. "\x96\x67\x57\x1f\x20\x86\x1b\x2d"
  8429. "\x69\xe4\x29\x93\x66\x5f\xaf\x6b"
  8430. "\x88\x26\x2c\x67\x02\x4b\x52\xd0"
  8431. "\x83\x7a\x43\x1f\xc0\x71\x15\x25"
  8432. "\x77\x65\x08\x60\x11\x76\x4c\x8d"
  8433. "\xed\xa9\x27\xc6\xb1\x2a\x2c\x6a"
  8434. "\x4a\x97\xf5\xc6\xb7\x70\x42\xd3"
  8435. "\x03\xd1\x24\x95\xec\x6d\xab\x38"
  8436. "\x72\xce\xe2\x8b\x33\xd7\x51\x09"
  8437. "\xdc\x45\xe0\x09\x96\x32\xf3\xc4"
  8438. "\x84\xdc\x73\x73\x2d\x1b\x11\x98"
  8439. "\xc5\x0e\x69\x28\x94\xc7\xb5\x4d"
  8440. "\xc8\x8a\xd0\xaa\x13\x2e\x18\x74"
  8441. "\xdd\xd1\x1e\xf3\x90\xe8\xfc\x9a"
  8442. "\x72\x4a\x0e\xd1\xe4\xfb\x0d\x96"
  8443. "\xd1\x0c\x79\x85\x1b\x1c\xfe\xe1"
  8444. "\x62\x8f\x7a\x73\x32\xab\xc8\x18"
  8445. "\x69\xe3\x34\x30\xdf\x13\xa6\xe5"
  8446. "\xe8\x0e\x67\x7f\x81\x11\xb4\x60"
  8447. "\xc7\xbd\x79\x65\x50\xdc\xc4\x5b"
  8448. "\xde\x39\xa4\x01\x72\x63\xf3\xd1"
  8449. "\x64\x4e\xdf\xfc\x27\x92\x37\x0d"
  8450. "\x57\xcd\x11\x4f\x11\x04\x8e\x1d"
  8451. "\x16\xf7\xcd\x92\x9a\x99\x30\x14"
  8452. "\xf1\x7c\x67\x1b\x1f\x41\x0b\xe8"
  8453. "\x32\xe8\xb8\xc1\x4f\x54\x86\x4f"
  8454. "\xe5\x79\x81\x73\xcd\x43\x59\x68"
  8455. "\x73\x02\x3b\x78\x21\x72\x43\x00"
  8456. "\x49\x17\xf7\x00\xaf\x68\x24\x53"
  8457. "\x05\x0a\xc3\x33\xe0\x33\x3f\x69"
  8458. "\xd2\x84\x2f\x0b\xed\xde\x04\xf4"
  8459. "\x11\x94\x13\x69\x51\x09\x28\xde"
  8460. "\x57\x5c\xef\xdc\x9a\x49\x1c\x17"
  8461. "\x97\xf3\x96\xc1\x7f\x5d\x2e\x7d"
  8462. "\x55\xb8\xb3\x02\x09\xb3\x1f\xe7"
  8463. "\xc9\x8d\xa3\x36\x34\x8a\x77\x13"
  8464. "\x30\x63\x4c\xa5\xcd\xc3\xe0\x7e"
  8465. "\x05\xa1\x7b\x0c\xcb\x74\x47\x31"
  8466. "\x62\x03\x43\xf1\x87\xb4\xb0\x85"
  8467. "\x87\x8e\x4b\x25\xc7\xcf\xae\x4b"
  8468. "\x36\x46\x3e\x62\xbc\x6f\xeb\x5f"
  8469. "\x73\xac\xe6\x07\xee\xc1\xa1\xd6"
  8470. "\xc4\xab\xc9\xd6\x89\x45\xe1\xf1"
  8471. "\x04\x4e\x1a\x6f\xbb\x4f\x3a\xa3"
  8472. "\xa0\xcb\xa3\x0a\xd8\x71\x35\x55"
  8473. "\xe4\xbc\x2e\x04\x06\xe6\xff\x5b"
  8474. "\x1c\xc0\x11\x7c\xc5\x17\xf3\x38"
  8475. "\xcf\xe9\xba\x0f\x0e\xef\x02\xc2"
  8476. "\x8d\xc6\xbc\x4b\x67\x20\x95\xd7"
  8477. "\x2c\x45\x5b\x86\x44\x8c\x6f\x2e"
  8478. "\x7e\x9f\x1c\x77\xba\x6b\x0e\xa3"
  8479. "\x69\xdc\xab\x24\x57\x60\x47\xc1"
  8480. "\xd1\xa5\x9d\x23\xe6\xb1\x37\xfe"
  8481. "\x93\xd2\x4c\x46\xf9\x0c\xc6\xfb"
  8482. "\xd6\x9d\x99\x69\xab\x7a\x07\x0c"
  8483. "\x65\xe7\xc4\x08\x96\xe2\xa5\x01"
  8484. "\x3f\x46\x07\x05\x7e\xe8\x9a\x90"
  8485. "\x50\xdc\xe9\x7a\xea\xa1\x39\x6e"
  8486. "\x66\xe4\x6f\xa5\x5f\xb2\xd9\x5b"
  8487. "\xf5\xdb\x2a\x32\xf0\x11\x6f\x7c"
  8488. "\x26\x10\x8f\x3d\x80\xe9\x58\xf7"
  8489. "\xe0\xa8\x57\xf8\xdb\x0e\xce\x99"
  8490. "\x63\x19\x3d\xd5\xec\x1b\x77\x69"
  8491. "\x98\xf6\xe4\x5f\x67\x17\x4b\x09"
  8492. "\x85\x62\x82\x70\x18\xe2\x9a\x78"
  8493. "\xe2\x62\xbd\xb4\xf1\x42\xc6\xfb"
  8494. "\x08\xd0\xbd\xeb\x4e\x09\xf2\xc8"
  8495. "\x1e\xdc\x3d\x32\x21\x56\x9c\x4f"
  8496. "\x35\xf3\x61\x06\x72\x84\xc4\x32"
  8497. "\xf2\xf1\xfa\x0b\x2f\xc3\xdb\x02"
  8498. "\x04\xc2\xde\x57\x64\x60\x8d\xcf"
  8499. "\xcb\x86\x5d\x97\x3e\xb1\x9c\x01"
  8500. "\xd6\x28\x8f\x99\xbc\x46\xeb\x05"
  8501. "\xaf\x7e\xb8\x21\x2a\x56\x85\x1c"
  8502. "\xb3\x71\xa0\xde\xca\x96\xf1\x78"
  8503. "\x49\xa2\x99\x81\x80\x5c\x01\xf5"
  8504. "\xa0\xa2\x56\x63\xe2\x70\x07\xa5"
  8505. "\x95\xd6\x85\xeb\x36\x9e\xa9\x51"
  8506. "\x66\x56\x5f\x1d\x02\x19\xe2\xf6"
  8507. "\x4f\x73\x38\x09\x75\x64\x48\xe0"
  8508. "\xf1\x7e\x0e\xe8\x9d\xf9\xed\x94"
  8509. "\xfe\x16\x26\x62\x49\x74\xf4\xb0"
  8510. "\xd4\xa9\x6c\xb0\xfd\x53\xe9\x81"
  8511. "\xe0\x7a\xbf\xcf\xb5\xc4\x01\x81"
  8512. "\x79\x99\x77\x01\x3b\xe9\xa2\xb6"
  8513. "\xe6\x6a\x8a\x9e\x56\x1c\x8d\x1e"
  8514. "\x8f\x06\x55\x2c\x6c\xdc\x92\x87"
  8515. "\x64\x3b\x4b\x19\xa1\x13\x64\x1d"
  8516. "\x4a\xe9\xc0\x00\xb8\x95\xef\x6b"
  8517. "\x1a\x86\x6d\x37\x52\x02\xc2\xe0"
  8518. "\xc8\xbb\x42\x0c\x02\x21\x4a\xc9"
  8519. "\xef\xa0\x54\xe4\x5e\x16\x53\x81"
  8520. "\x70\x62\x10\xaf\xde\xb8\xb5\xd3"
  8521. "\xe8\x5e\x6c\xc3\x8a\x3e\x18\x07"
  8522. "\xf2\x2f\x7d\xa7\xe1\x3d\x4e\xb4"
  8523. "\x26\xa7\xa3\x93\x86\xb2\x04\x1e"
  8524. "\x53\x5d\x86\xd6\xde\x65\xca\xe3"
  8525. "\x4e\xc1\xcf\xef\xc8\x70\x1b\x83"
  8526. "\x13\xdd\x18\x8b\x0d\x76\xd2\xf6"
  8527. "\x37\x7a\x93\x7a\x50\x11\x9f\x96"
  8528. "\x86\x25\xfd\xac\xdc\xbe\x18\x93"
  8529. "\x19\x6b\xec\x58\x4f\xb9\x75\xa7"
  8530. "\xdd\x3f\x2f\xec\xc8\x5a\x84\xab"
  8531. "\xd5\xe4\x8a\x07\xf6\x4d\x23\xd6"
  8532. "\x03\xfb\x03\x6a\xea\x66\xbf\xd4"
  8533. "\xb1\x34\xfb\x78\xe9\x55\xdc\x7c"
  8534. "\x3d\x9c\xe5\x9a\xac\xc3\x7a\x80"
  8535. "\x24\x6d\xa0\xef\x25\x7c\xb7\xea"
  8536. "\xce\x4d\x5f\x18\x60\xce\x87\x22"
  8537. "\x66\x2f\xd5\xdd\xdd\x02\x21\x75"
  8538. "\x82\xa0\x1f\x58\xc6\xd3\x62\xf7"
  8539. "\x32\xd8\xaf\x1e\x07\x77\x51\x96"
  8540. "\xd5\x6b\x1e\x7e\x80\x02\xe8\x67"
  8541. "\xea\x17\x0b\x10\xd2\x3f\x28\x25"
  8542. "\x4f\x05\x77\x02\x14\x69\xf0\x2c"
  8543. "\xbe\x0c\xf1\x74\x30\xd1\xb9\x9b"
  8544. "\xfc\x8c\xbb\x04\x16\xd9\xba\xc3"
  8545. "\xbc\x91\x8a\xc4\x30\xa4\xb0\x12"
  8546. "\x4c\x21\x87\xcb\xc9\x1d\x16\x96"
  8547. "\x07\x6f\x23\x54\xb9\x6f\x79\xe5"
  8548. "\x64\xc0\x64\xda\xb1\xae\xdd\x60"
  8549. "\x6c\x1a\x9d\xd3\x04\x8e\x45\xb0"
  8550. "\x92\x61\xd0\x48\x81\xed\x5e\x1d"
  8551. "\xa0\xc9\xa4\x33\xc7\x13\x51\x5d"
  8552. "\x7f\x83\x73\xb6\x70\x18\x65\x3e"
  8553. "\x2f\x0e\x7a\x12\x39\x98\xab\xd8"
  8554. "\x7e\x6f\xa3\xd1\xba\x56\xad\xbd"
  8555. "\xf0\x03\x01\x1c\x85\x35\x9f\xeb"
  8556. "\x19\x63\xa1\xaf\xfe\x2d\x35\x50"
  8557. "\x39\xa0\x65\x7c\x95\x7e\x6b\xfe"
  8558. "\xc1\xac\x07\x7c\x98\x4f\xbe\x57"
  8559. "\xa7\x22\xec\xe2\x7e\x29\x09\x53"
  8560. "\xe8\xbf\xb4\x7e\x3f\x8f\xfc\x14"
  8561. "\xce\x54\xf9\x18\x58\xb5\xff\x44"
  8562. "\x05\x9d\xce\x1b\xb6\x82\x23\xc8"
  8563. "\x2e\xbc\x69\xbb\x4a\x29\x0f\x65"
  8564. "\x94\xf0\x63\x06\x0e\xef\x8c\xbd"
  8565. "\xff\xfd\xb0\x21\x6e\x57\x05\x75"
  8566. "\xda\xd5\xc4\xeb\x8d\x32\xf7\x50"
  8567. "\xd3\x6f\x22\xed\x5f\x8e\xa2\x5b"
  8568. "\x80\x8c\xc8\x78\x40\x24\x4b\x89"
  8569. "\x30\xce\x7a\x97\x0e\xc4\xaf\xef"
  8570. "\x9b\xb4\xcd\x66\x74\x14\x04\x2b"
  8571. "\xf7\xce\x0b\x1c\x6e\xc2\x78\x8c"
  8572. "\xca\xc5\xd0\x1c\x95\x4a\x91\x2d"
  8573. "\xa7\x20\xeb\x86\x52\xb7\x67\xd8"
  8574. "\x0c\xd6\x04\x14\xde\x51\x74\x75"
  8575. "\xe7\x11\xb4\x87\xa3\x3d\x2d\xad"
  8576. "\x4f\xef\xa0\x0f\x70\x00\x6d\x13"
  8577. "\x19\x1d\x41\x50\xe9\xd8\xf0\x32"
  8578. "\x71\xbc\xd3\x11\xf2\xac\xbe\xaf"
  8579. "\x75\x46\x65\x4e\x07\x34\x37\xa3"
  8580. "\x89\xfe\x75\xd4\x70\x4c\xc6\x3f"
  8581. "\x69\x24\x0e\x38\x67\x43\x8c\xde"
  8582. "\x06\xb5\xb8\xe7\xc4\xf0\x41\x8f"
  8583. "\xf0\xbd\x2f\x0b\xb9\x18\xf8\xde"
  8584. "\x64\xb1\xdb\xee\x00\x50\x77\xe1"
  8585. "\xc7\xff\xa6\xfa\xdd\x70\xf4\xe3"
  8586. "\x93\xe9\x77\x35\x3d\x4b\x2f\x2b"
  8587. "\x6d\x55\xf0\xfc\x88\x54\x4e\x89"
  8588. "\xc1\x8a\x23\x31\x2d\x14\x2a\xb8"
  8589. "\x1b\x15\xdd\x9e\x6e\x7b\xda\x05"
  8590. "\x91\x7d\x62\x64\x96\x72\xde\xfc"
  8591. "\xc1\xec\xf0\x23\x51\x6f\xdb\x5b"
  8592. "\x1d\x08\x57\xce\x09\xb8\xf6\xcd"
  8593. "\x8d\x95\xf2\x20\xbf\x0f\x20\x57"
  8594. "\x98\x81\x84\x4f\x15\x5c\x76\xe7"
  8595. "\x3e\x0a\x3a\x6c\xc4\x8a\xbe\x78"
  8596. "\x74\x77\xc3\x09\x4b\x5d\x48\xe4"
  8597. "\xc8\xcb\x0b\xea\x17\x28\xcf\xcf"
  8598. "\x31\x32\x44\xa4\xe5\x0e\x1a\x98"
  8599. "\x94\xc4\xf0\xff\xae\x3e\x44\xe8"
  8600. "\xa5\xb3\xb5\x37\x2f\xe8\xaf\x6f"
  8601. "\x28\xc1\x37\x5f\x31\xd2\xb9\x33"
  8602. "\xb1\xb2\x52\x94\x75\x2c\x29\x59"
  8603. "\x06\xc2\x25\xe8\x71\x65\x4e\xed"
  8604. "\xc0\x9c\xb1\xbb\x25\xdc\x6c\xe7"
  8605. "\x4b\xa5\x7a\x54\x7a\x60\xff\x7a"
  8606. "\xe0\x50\x40\x96\x35\x63\xe4\x0b"
  8607. "\x76\xbd\xa4\x65\x00\x1b\x57\x88"
  8608. "\xae\xed\x39\x88\x42\x11\x3c\xed"
  8609. "\x85\x67\x7d\xb9\x68\x82\xe9\x43"
  8610. "\x3c\x47\x53\xfa\xe8\xf8\x9f\x1f"
  8611. "\x9f\xef\x0f\xf7\x30\xd9\x30\x0e"
  8612. "\xb9\x9f\x69\x18\x2f\x7e\xf8\xf8"
  8613. "\xf8\x8c\x0f\xd4\x02\x4d\xea\xcd"
  8614. "\x0a\x9c\x6f\x71\x6d\x5a\x4c\x60"
  8615. "\xce\x20\x56\x32\xc6\xc5\x99\x1f"
  8616. "\x09\xe6\x4e\x18\x1a\x15\x13\xa8"
  8617. "\x7d\xb1\x6b\xc0\xb2\x6d\xf8\x26"
  8618. "\x66\xf8\x3d\x18\x74\x70\x66\x7a"
  8619. "\x34\x17\xde\xba\x47\xf1\x06\x18"
  8620. "\xcb\xaf\xeb\x4a\x1e\x8f\xa7\x77"
  8621. "\xe0\x3b\x78\x62\x66\xc9\x10\xea"
  8622. "\x1f\xb7\x29\x0a\x45\xa1\x1d\x1e"
  8623. "\x1d\xe2\x65\x61\x50\x9c\xd7\x05"
  8624. "\xf2\x0b\x5b\x12\x61\x02\xc8\xe5"
  8625. "\x63\x4f\x20\x0c\x07\x17\x33\x5e"
  8626. "\x03\x9a\x53\x0f\x2e\x55\xfe\x50"
  8627. "\x43\x7d\xd0\xb6\x7e\x5a\xda\xae"
  8628. "\x58\xef\x15\xa9\x83\xd9\x46\xb1"
  8629. "\x42\xaa\xf5\x02\x6c\xce\x92\x06"
  8630. "\x1b\xdb\x66\x45\x91\x79\xc2\x2d"
  8631. "\xe6\x53\xd3\x14\xfd\xbb\x44\x63"
  8632. "\xc6\xd7\x3d\x7a\x0c\x75\x78\x9d"
  8633. "\x5c\xa6\x39\xb3\xe5\x63\xca\x8b"
  8634. "\xfe\xd3\xef\x60\x83\xf6\x8e\x70"
  8635. "\xb6\x67\xc7\x77\xed\x23\xef\x4c"
  8636. "\xf0\xed\x2d\x07\x59\x6f\xc1\x01"
  8637. "\x34\x37\x08\xab\xd9\x1f\x09\xb1"
  8638. "\xce\x5b\x17\xff\x74\xf8\x9c\xd5"
  8639. "\x2c\x56\x39\x79\x0f\x69\x44\x75"
  8640. "\x58\x27\x01\xc4\xbf\xa7\xa1\x1d"
  8641. "\x90\x17\x77\x86\x5a\x3f\xd9\xd1"
  8642. "\x0e\xa0\x10\xf8\xec\x1e\xa5\x7f"
  8643. "\x5e\x36\xd1\xe3\x04\x2c\x70\xf7"
  8644. "\x8e\xc0\x98\x2f\x6c\x94\x2b\x41"
  8645. "\xb7\x60\x00\xb7\x2e\xb8\x02\x8d"
  8646. "\xb8\xb0\xd3\x86\xba\x1d\xd7\x90"
  8647. "\xd6\xb6\xe1\xfc\xd7\xd8\x28\x06"
  8648. "\x63\x9b\xce\x61\x24\x79\xc0\x70"
  8649. "\x52\xd0\xb6\xd4\x28\x95\x24\x87"
  8650. "\x03\x1f\xb7\x9a\xda\xa3\xfb\x52"
  8651. "\x5b\x68\xe7\x4c\x8c\x24\xe1\x42"
  8652. "\xf7\xd5\xfd\xad\x06\x32\x9f\xba"
  8653. "\xc1\xfc\xdd\xc6\xfc\xfc\xb3\x38"
  8654. "\x74\x56\x58\x40\x02\x37\x52\x2c"
  8655. "\x55\xcc\xb3\x9e\x7a\xe9\xd4\x38"
  8656. "\x41\x5e\x0c\x35\xe2\x11\xd1\x13"
  8657. "\xf8\xb7\x8d\x72\x6b\x22\x2a\xb0"
  8658. "\xdb\x08\xba\x35\xb9\x3f\xc8\xd3"
  8659. "\x24\x90\xec\x58\xd2\x09\xc7\x2d"
  8660. "\xed\x38\x80\x36\x72\x43\x27\x49"
  8661. "\x4a\x80\x8a\xa2\xe8\xd3\xda\x30"
  8662. "\x7d\xb6\x82\x37\x86\x92\x86\x3e"
  8663. "\x08\xb2\x28\x5a\x55\x44\x24\x7d"
  8664. "\x40\x48\x8a\xb6\x89\x58\x08\xa0"
  8665. "\xd6\x6d\x3a\x17\xbf\xf6\x54\xa2"
  8666. "\xf5\xd3\x8c\x0f\x78\x12\x57\x8b"
  8667. "\xd5\xc2\xfd\x58\x5b\x7f\x38\xe3"
  8668. "\xcc\xb7\x7c\x48\xb3\x20\xe8\x81"
  8669. "\x14\x32\x45\x05\xe0\xdb\x9f\x75"
  8670. "\x85\xb4\x6a\xfc\x95\xe3\x54\x22"
  8671. "\x12\xee\x30\xfe\xd8\x30\xef\x34"
  8672. "\x50\xab\x46\x30\x98\x2f\xb7\xc0"
  8673. "\x15\xa2\x83\xb6\xf2\x06\x21\xa2"
  8674. "\xc3\x26\x37\x14\xd1\x4d\xb5\x10"
  8675. "\x52\x76\x4d\x6a\xee\xb5\x2b\x15"
  8676. "\xb7\xf9\x51\xe8\x2a\xaf\xc7\xfa"
  8677. "\x77\xaf\xb0\x05\x4d\xd1\x68\x8e"
  8678. "\x74\x05\x9f\x9d\x93\xa5\x3e\x7f"
  8679. "\x4e\x5f\x9d\xcb\x09\xc7\x83\xe3"
  8680. "\x02\x9d\x27\x1f\xef\x85\x05\x8d"
  8681. "\xec\x55\x88\x0f\x0d\x7c\x4c\xe8"
  8682. "\xa1\x75\xa0\xd8\x06\x47\x14\xef"
  8683. "\xaa\x61\xcf\x26\x15\xad\xd8\xa3"
  8684. "\xaa\x75\xf2\x78\x4a\x5a\x61\xdf"
  8685. "\x8b\xc7\x04\xbc\xb2\x32\xd2\x7e"
  8686. "\x42\xee\xb4\x2f\x51\xff\x7b\x2e"
  8687. "\xd3\x02\xe8\xdc\x5d\x0d\x50\xdc"
  8688. "\xae\xb7\x46\xf9\xa8\xe6\xd0\x16"
  8689. "\xcc\xe6\x2c\x81\xc7\xad\xe9\xf0"
  8690. "\x05\x72\x6d\x3d\x0a\x7a\xa9\x02"
  8691. "\xac\x82\x93\x6e\xb6\x1c\x28\xfc"
  8692. "\x44\x12\xfb\x73\x77\xd4\x13\x39"
  8693. "\x29\x88\x8a\xf3\x5c\xa6\x36\xa0"
  8694. "\x2a\xed\x7e\xb1\x1d\xd6\x4c\x6b"
  8695. "\x41\x01\x18\x5d\x5d\x07\x97\xa6"
  8696. "\x4b\xef\x31\x18\xea\xac\xb1\x84"
  8697. "\x21\xed\xda\x86",
  8698. .rlen = 4100,
  8699. .np = 2,
  8700. .tap = { 4064, 36 },
  8701. },
  8702. };
  8703. static struct cipher_testvec aes_ctr_rfc3686_dec_tv_template[] = {
  8704. { /* From RFC 3686 */
  8705. .key = "\xae\x68\x52\xf8\x12\x10\x67\xcc"
  8706. "\x4b\xf7\xa5\x76\x55\x77\xf3\x9e"
  8707. "\x00\x00\x00\x30",
  8708. .klen = 20,
  8709. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  8710. .input = "\xe4\x09\x5d\x4f\xb7\xa7\xb3\x79"
  8711. "\x2d\x61\x75\xa3\x26\x13\x11\xb8",
  8712. .ilen = 16,
  8713. .result = "Single block msg",
  8714. .rlen = 16,
  8715. }, {
  8716. .key = "\x7e\x24\x06\x78\x17\xfa\xe0\xd7"
  8717. "\x43\xd6\xce\x1f\x32\x53\x91\x63"
  8718. "\x00\x6c\xb6\xdb",
  8719. .klen = 20,
  8720. .iv = "\xc0\x54\x3b\x59\xda\x48\xd9\x0b",
  8721. .input = "\x51\x04\xa1\x06\x16\x8a\x72\xd9"
  8722. "\x79\x0d\x41\xee\x8e\xda\xd3\x88"
  8723. "\xeb\x2e\x1e\xfc\x46\xda\x57\xc8"
  8724. "\xfc\xe6\x30\xdf\x91\x41\xbe\x28",
  8725. .ilen = 32,
  8726. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  8727. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  8728. "\x10\x11\x12\x13\x14\x15\x16\x17"
  8729. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  8730. .rlen = 32,
  8731. }, {
  8732. .key = "\x16\xaf\x5b\x14\x5f\xc9\xf5\x79"
  8733. "\xc1\x75\xf9\x3e\x3b\xfb\x0e\xed"
  8734. "\x86\x3d\x06\xcc\xfd\xb7\x85\x15"
  8735. "\x00\x00\x00\x48",
  8736. .klen = 28,
  8737. .iv = "\x36\x73\x3c\x14\x7d\x6d\x93\xcb",
  8738. .input = "\x4b\x55\x38\x4f\xe2\x59\xc9\xc8"
  8739. "\x4e\x79\x35\xa0\x03\xcb\xe9\x28",
  8740. .ilen = 16,
  8741. .result = "Single block msg",
  8742. .rlen = 16,
  8743. }, {
  8744. .key = "\x7c\x5c\xb2\x40\x1b\x3d\xc3\x3c"
  8745. "\x19\xe7\x34\x08\x19\xe0\xf6\x9c"
  8746. "\x67\x8c\x3d\xb8\xe6\xf6\xa9\x1a"
  8747. "\x00\x96\xb0\x3b",
  8748. .klen = 28,
  8749. .iv = "\x02\x0c\x6e\xad\xc2\xcb\x50\x0d",
  8750. .input = "\x45\x32\x43\xfc\x60\x9b\x23\x32"
  8751. "\x7e\xdf\xaa\xfa\x71\x31\xcd\x9f"
  8752. "\x84\x90\x70\x1c\x5a\xd4\xa7\x9c"
  8753. "\xfc\x1f\xe0\xff\x42\xf4\xfb\x00",
  8754. .ilen = 32,
  8755. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  8756. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  8757. "\x10\x11\x12\x13\x14\x15\x16\x17"
  8758. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  8759. .rlen = 32,
  8760. }, {
  8761. .key = "\x77\x6b\xef\xf2\x85\x1d\xb0\x6f"
  8762. "\x4c\x8a\x05\x42\xc8\x69\x6f\x6c"
  8763. "\x6a\x81\xaf\x1e\xec\x96\xb4\xd3"
  8764. "\x7f\xc1\xd6\x89\xe6\xc1\xc1\x04"
  8765. "\x00\x00\x00\x60",
  8766. .klen = 36,
  8767. .iv = "\xdb\x56\x72\xc9\x7a\xa8\xf0\xb2",
  8768. .input = "\x14\x5a\xd0\x1d\xbf\x82\x4e\xc7"
  8769. "\x56\x08\x63\xdc\x71\xe3\xe0\xc0",
  8770. .ilen = 16,
  8771. .result = "Single block msg",
  8772. .rlen = 16,
  8773. }, {
  8774. .key = "\xf6\xd6\x6d\x6b\xd5\x2d\x59\xbb"
  8775. "\x07\x96\x36\x58\x79\xef\xf8\x86"
  8776. "\xc6\x6d\xd5\x1a\x5b\x6a\x99\x74"
  8777. "\x4b\x50\x59\x0c\x87\xa2\x38\x84"
  8778. "\x00\xfa\xac\x24",
  8779. .klen = 36,
  8780. .iv = "\xc1\x58\x5e\xf1\x5a\x43\xd8\x75",
  8781. .input = "\xf0\x5e\x23\x1b\x38\x94\x61\x2c"
  8782. "\x49\xee\x00\x0b\x80\x4e\xb2\xa9"
  8783. "\xb8\x30\x6b\x50\x8f\x83\x9d\x6a"
  8784. "\x55\x30\x83\x1d\x93\x44\xaf\x1c",
  8785. .ilen = 32,
  8786. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  8787. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  8788. "\x10\x11\x12\x13\x14\x15\x16\x17"
  8789. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  8790. .rlen = 32,
  8791. },
  8792. };
  8793. static struct cipher_testvec aes_ofb_enc_tv_template[] = {
  8794. /* From NIST Special Publication 800-38A, Appendix F.5 */
  8795. {
  8796. .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
  8797. "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
  8798. .klen = 16,
  8799. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07\x08"
  8800. "\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  8801. .input = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  8802. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  8803. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  8804. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  8805. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  8806. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  8807. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  8808. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  8809. .ilen = 64,
  8810. .result = "\x3b\x3f\xd9\x2e\xb7\x2d\xad\x20"
  8811. "\x33\x34\x49\xf8\xe8\x3c\xfb\x4a"
  8812. "\x77\x89\x50\x8d\x16\x91\x8f\x03\xf5"
  8813. "\x3c\x52\xda\xc5\x4e\xd8\x25"
  8814. "\x97\x40\x05\x1e\x9c\x5f\xec\xf6\x43"
  8815. "\x44\xf7\xa8\x22\x60\xed\xcc"
  8816. "\x30\x4c\x65\x28\xf6\x59\xc7\x78"
  8817. "\x66\xa5\x10\xd9\xc1\xd6\xae\x5e",
  8818. .rlen = 64,
  8819. }
  8820. };
  8821. static struct cipher_testvec aes_ofb_dec_tv_template[] = {
  8822. /* From NIST Special Publication 800-38A, Appendix F.5 */
  8823. {
  8824. .key = "\x2b\x7e\x15\x16\x28\xae\xd2\xa6"
  8825. "\xab\xf7\x15\x88\x09\xcf\x4f\x3c",
  8826. .klen = 16,
  8827. .iv = "\x00\x01\x02\x03\x04\x05\x06\x07\x08"
  8828. "\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  8829. .input = "\x3b\x3f\xd9\x2e\xb7\x2d\xad\x20"
  8830. "\x33\x34\x49\xf8\xe8\x3c\xfb\x4a"
  8831. "\x77\x89\x50\x8d\x16\x91\x8f\x03\xf5"
  8832. "\x3c\x52\xda\xc5\x4e\xd8\x25"
  8833. "\x97\x40\x05\x1e\x9c\x5f\xec\xf6\x43"
  8834. "\x44\xf7\xa8\x22\x60\xed\xcc"
  8835. "\x30\x4c\x65\x28\xf6\x59\xc7\x78"
  8836. "\x66\xa5\x10\xd9\xc1\xd6\xae\x5e",
  8837. .ilen = 64,
  8838. .result = "\x6b\xc1\xbe\xe2\x2e\x40\x9f\x96"
  8839. "\xe9\x3d\x7e\x11\x73\x93\x17\x2a"
  8840. "\xae\x2d\x8a\x57\x1e\x03\xac\x9c"
  8841. "\x9e\xb7\x6f\xac\x45\xaf\x8e\x51"
  8842. "\x30\xc8\x1c\x46\xa3\x5c\xe4\x11"
  8843. "\xe5\xfb\xc1\x19\x1a\x0a\x52\xef"
  8844. "\xf6\x9f\x24\x45\xdf\x4f\x9b\x17"
  8845. "\xad\x2b\x41\x7b\xe6\x6c\x37\x10",
  8846. .rlen = 64,
  8847. }
  8848. };
  8849. static struct aead_testvec aes_gcm_enc_tv_template[] = {
  8850. { /* From McGrew & Viega - http://citeseer.ist.psu.edu/656989.html */
  8851. .key = zeroed_string,
  8852. .klen = 16,
  8853. .result = "\x58\xe2\xfc\xce\xfa\x7e\x30\x61"
  8854. "\x36\x7f\x1d\x57\xa4\xe7\x45\x5a",
  8855. .rlen = 16,
  8856. }, {
  8857. .key = zeroed_string,
  8858. .klen = 16,
  8859. .input = zeroed_string,
  8860. .ilen = 16,
  8861. .result = "\x03\x88\xda\xce\x60\xb6\xa3\x92"
  8862. "\xf3\x28\xc2\xb9\x71\xb2\xfe\x78"
  8863. "\xab\x6e\x47\xd4\x2c\xec\x13\xbd"
  8864. "\xf5\x3a\x67\xb2\x12\x57\xbd\xdf",
  8865. .rlen = 32,
  8866. }, {
  8867. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  8868. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  8869. .klen = 16,
  8870. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  8871. "\xde\xca\xf8\x88",
  8872. .input = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  8873. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  8874. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  8875. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  8876. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  8877. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  8878. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  8879. "\xba\x63\x7b\x39\x1a\xaf\xd2\x55",
  8880. .ilen = 64,
  8881. .result = "\x42\x83\x1e\xc2\x21\x77\x74\x24"
  8882. "\x4b\x72\x21\xb7\x84\xd0\xd4\x9c"
  8883. "\xe3\xaa\x21\x2f\x2c\x02\xa4\xe0"
  8884. "\x35\xc1\x7e\x23\x29\xac\xa1\x2e"
  8885. "\x21\xd5\x14\xb2\x54\x66\x93\x1c"
  8886. "\x7d\x8f\x6a\x5a\xac\x84\xaa\x05"
  8887. "\x1b\xa3\x0b\x39\x6a\x0a\xac\x97"
  8888. "\x3d\x58\xe0\x91\x47\x3f\x59\x85"
  8889. "\x4d\x5c\x2a\xf3\x27\xcd\x64\xa6"
  8890. "\x2c\xf3\x5a\xbd\x2b\xa6\xfa\xb4",
  8891. .rlen = 80,
  8892. }, {
  8893. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  8894. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  8895. .klen = 16,
  8896. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  8897. "\xde\xca\xf8\x88",
  8898. .input = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  8899. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  8900. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  8901. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  8902. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  8903. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  8904. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  8905. "\xba\x63\x7b\x39",
  8906. .ilen = 60,
  8907. .assoc = "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  8908. "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  8909. "\xab\xad\xda\xd2",
  8910. .alen = 20,
  8911. .result = "\x42\x83\x1e\xc2\x21\x77\x74\x24"
  8912. "\x4b\x72\x21\xb7\x84\xd0\xd4\x9c"
  8913. "\xe3\xaa\x21\x2f\x2c\x02\xa4\xe0"
  8914. "\x35\xc1\x7e\x23\x29\xac\xa1\x2e"
  8915. "\x21\xd5\x14\xb2\x54\x66\x93\x1c"
  8916. "\x7d\x8f\x6a\x5a\xac\x84\xaa\x05"
  8917. "\x1b\xa3\x0b\x39\x6a\x0a\xac\x97"
  8918. "\x3d\x58\xe0\x91"
  8919. "\x5b\xc9\x4f\xbc\x32\x21\xa5\xdb"
  8920. "\x94\xfa\xe9\x5a\xe7\x12\x1a\x47",
  8921. .rlen = 76,
  8922. }, {
  8923. .key = zeroed_string,
  8924. .klen = 24,
  8925. .result = "\xcd\x33\xb2\x8a\xc7\x73\xf7\x4b"
  8926. "\xa0\x0e\xd1\xf3\x12\x57\x24\x35",
  8927. .rlen = 16,
  8928. }, {
  8929. .key = zeroed_string,
  8930. .klen = 24,
  8931. .input = zeroed_string,
  8932. .ilen = 16,
  8933. .result = "\x98\xe7\x24\x7c\x07\xf0\xfe\x41"
  8934. "\x1c\x26\x7e\x43\x84\xb0\xf6\x00"
  8935. "\x2f\xf5\x8d\x80\x03\x39\x27\xab"
  8936. "\x8e\xf4\xd4\x58\x75\x14\xf0\xfb",
  8937. .rlen = 32,
  8938. }, {
  8939. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  8940. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  8941. "\xfe\xff\xe9\x92\x86\x65\x73\x1c",
  8942. .klen = 24,
  8943. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  8944. "\xde\xca\xf8\x88",
  8945. .input = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  8946. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  8947. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  8948. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  8949. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  8950. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  8951. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  8952. "\xba\x63\x7b\x39\x1a\xaf\xd2\x55",
  8953. .ilen = 64,
  8954. .result = "\x39\x80\xca\x0b\x3c\x00\xe8\x41"
  8955. "\xeb\x06\xfa\xc4\x87\x2a\x27\x57"
  8956. "\x85\x9e\x1c\xea\xa6\xef\xd9\x84"
  8957. "\x62\x85\x93\xb4\x0c\xa1\xe1\x9c"
  8958. "\x7d\x77\x3d\x00\xc1\x44\xc5\x25"
  8959. "\xac\x61\x9d\x18\xc8\x4a\x3f\x47"
  8960. "\x18\xe2\x44\x8b\x2f\xe3\x24\xd9"
  8961. "\xcc\xda\x27\x10\xac\xad\xe2\x56"
  8962. "\x99\x24\xa7\xc8\x58\x73\x36\xbf"
  8963. "\xb1\x18\x02\x4d\xb8\x67\x4a\x14",
  8964. .rlen = 80,
  8965. }, {
  8966. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  8967. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  8968. "\xfe\xff\xe9\x92\x86\x65\x73\x1c",
  8969. .klen = 24,
  8970. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  8971. "\xde\xca\xf8\x88",
  8972. .input = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  8973. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  8974. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  8975. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  8976. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  8977. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  8978. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  8979. "\xba\x63\x7b\x39",
  8980. .ilen = 60,
  8981. .assoc = "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  8982. "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  8983. "\xab\xad\xda\xd2",
  8984. .alen = 20,
  8985. .result = "\x39\x80\xca\x0b\x3c\x00\xe8\x41"
  8986. "\xeb\x06\xfa\xc4\x87\x2a\x27\x57"
  8987. "\x85\x9e\x1c\xea\xa6\xef\xd9\x84"
  8988. "\x62\x85\x93\xb4\x0c\xa1\xe1\x9c"
  8989. "\x7d\x77\x3d\x00\xc1\x44\xc5\x25"
  8990. "\xac\x61\x9d\x18\xc8\x4a\x3f\x47"
  8991. "\x18\xe2\x44\x8b\x2f\xe3\x24\xd9"
  8992. "\xcc\xda\x27\x10"
  8993. "\x25\x19\x49\x8e\x80\xf1\x47\x8f"
  8994. "\x37\xba\x55\xbd\x6d\x27\x61\x8c",
  8995. .rlen = 76,
  8996. .np = 2,
  8997. .tap = { 32, 28 },
  8998. .anp = 2,
  8999. .atap = { 8, 12 }
  9000. }, {
  9001. .key = zeroed_string,
  9002. .klen = 32,
  9003. .result = "\x53\x0f\x8a\xfb\xc7\x45\x36\xb9"
  9004. "\xa9\x63\xb4\xf1\xc4\xcb\x73\x8b",
  9005. .rlen = 16,
  9006. }
  9007. };
  9008. static struct aead_testvec aes_gcm_dec_tv_template[] = {
  9009. { /* From McGrew & Viega - http://citeseer.ist.psu.edu/656989.html */
  9010. .key = zeroed_string,
  9011. .klen = 32,
  9012. .input = "\xce\xa7\x40\x3d\x4d\x60\x6b\x6e"
  9013. "\x07\x4e\xc5\xd3\xba\xf3\x9d\x18"
  9014. "\xd0\xd1\xc8\xa7\x99\x99\x6b\xf0"
  9015. "\x26\x5b\x98\xb5\xd4\x8a\xb9\x19",
  9016. .ilen = 32,
  9017. .result = zeroed_string,
  9018. .rlen = 16,
  9019. }, {
  9020. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9021. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9022. "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9023. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  9024. .klen = 32,
  9025. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9026. "\xde\xca\xf8\x88",
  9027. .input = "\x52\x2d\xc1\xf0\x99\x56\x7d\x07"
  9028. "\xf4\x7f\x37\xa3\x2a\x84\x42\x7d"
  9029. "\x64\x3a\x8c\xdc\xbf\xe5\xc0\xc9"
  9030. "\x75\x98\xa2\xbd\x25\x55\xd1\xaa"
  9031. "\x8c\xb0\x8e\x48\x59\x0d\xbb\x3d"
  9032. "\xa7\xb0\x8b\x10\x56\x82\x88\x38"
  9033. "\xc5\xf6\x1e\x63\x93\xba\x7a\x0a"
  9034. "\xbc\xc9\xf6\x62\x89\x80\x15\xad"
  9035. "\xb0\x94\xda\xc5\xd9\x34\x71\xbd"
  9036. "\xec\x1a\x50\x22\x70\xe3\xcc\x6c",
  9037. .ilen = 80,
  9038. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9039. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9040. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9041. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9042. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9043. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9044. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9045. "\xba\x63\x7b\x39\x1a\xaf\xd2\x55",
  9046. .rlen = 64,
  9047. }, {
  9048. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9049. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9050. "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9051. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  9052. .klen = 32,
  9053. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9054. "\xde\xca\xf8\x88",
  9055. .input = "\x52\x2d\xc1\xf0\x99\x56\x7d\x07"
  9056. "\xf4\x7f\x37\xa3\x2a\x84\x42\x7d"
  9057. "\x64\x3a\x8c\xdc\xbf\xe5\xc0\xc9"
  9058. "\x75\x98\xa2\xbd\x25\x55\xd1\xaa"
  9059. "\x8c\xb0\x8e\x48\x59\x0d\xbb\x3d"
  9060. "\xa7\xb0\x8b\x10\x56\x82\x88\x38"
  9061. "\xc5\xf6\x1e\x63\x93\xba\x7a\x0a"
  9062. "\xbc\xc9\xf6\x62"
  9063. "\x76\xfc\x6e\xce\x0f\x4e\x17\x68"
  9064. "\xcd\xdf\x88\x53\xbb\x2d\x55\x1b",
  9065. .ilen = 76,
  9066. .assoc = "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9067. "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9068. "\xab\xad\xda\xd2",
  9069. .alen = 20,
  9070. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9071. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9072. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9073. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9074. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9075. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9076. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9077. "\xba\x63\x7b\x39",
  9078. .rlen = 60,
  9079. .np = 2,
  9080. .tap = { 48, 28 },
  9081. .anp = 3,
  9082. .atap = { 8, 8, 4 }
  9083. }, {
  9084. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9085. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  9086. .klen = 16,
  9087. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9088. "\xde\xca\xf8\x88",
  9089. .input = "\x42\x83\x1e\xc2\x21\x77\x74\x24"
  9090. "\x4b\x72\x21\xb7\x84\xd0\xd4\x9c"
  9091. "\xe3\xaa\x21\x2f\x2c\x02\xa4\xe0"
  9092. "\x35\xc1\x7e\x23\x29\xac\xa1\x2e"
  9093. "\x21\xd5\x14\xb2\x54\x66\x93\x1c"
  9094. "\x7d\x8f\x6a\x5a\xac\x84\xaa\x05"
  9095. "\x1b\xa3\x0b\x39\x6a\x0a\xac\x97"
  9096. "\x3d\x58\xe0\x91\x47\x3f\x59\x85"
  9097. "\x4d\x5c\x2a\xf3\x27\xcd\x64\xa6"
  9098. "\x2c\xf3\x5a\xbd\x2b\xa6\xfa\xb4",
  9099. .ilen = 80,
  9100. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9101. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9102. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9103. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9104. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9105. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9106. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9107. "\xba\x63\x7b\x39\x1a\xaf\xd2\x55",
  9108. .rlen = 64,
  9109. }, {
  9110. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9111. "\x6d\x6a\x8f\x94\x67\x30\x83\x08",
  9112. .klen = 16,
  9113. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9114. "\xde\xca\xf8\x88",
  9115. .input = "\x42\x83\x1e\xc2\x21\x77\x74\x24"
  9116. "\x4b\x72\x21\xb7\x84\xd0\xd4\x9c"
  9117. "\xe3\xaa\x21\x2f\x2c\x02\xa4\xe0"
  9118. "\x35\xc1\x7e\x23\x29\xac\xa1\x2e"
  9119. "\x21\xd5\x14\xb2\x54\x66\x93\x1c"
  9120. "\x7d\x8f\x6a\x5a\xac\x84\xaa\x05"
  9121. "\x1b\xa3\x0b\x39\x6a\x0a\xac\x97"
  9122. "\x3d\x58\xe0\x91"
  9123. "\x5b\xc9\x4f\xbc\x32\x21\xa5\xdb"
  9124. "\x94\xfa\xe9\x5a\xe7\x12\x1a\x47",
  9125. .ilen = 76,
  9126. .assoc = "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9127. "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9128. "\xab\xad\xda\xd2",
  9129. .alen = 20,
  9130. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9131. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9132. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9133. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9134. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9135. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9136. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9137. "\xba\x63\x7b\x39",
  9138. .rlen = 60,
  9139. }, {
  9140. .key = zeroed_string,
  9141. .klen = 24,
  9142. .input = "\x98\xe7\x24\x7c\x07\xf0\xfe\x41"
  9143. "\x1c\x26\x7e\x43\x84\xb0\xf6\x00"
  9144. "\x2f\xf5\x8d\x80\x03\x39\x27\xab"
  9145. "\x8e\xf4\xd4\x58\x75\x14\xf0\xfb",
  9146. .ilen = 32,
  9147. .result = zeroed_string,
  9148. .rlen = 16,
  9149. }, {
  9150. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9151. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9152. "\xfe\xff\xe9\x92\x86\x65\x73\x1c",
  9153. .klen = 24,
  9154. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9155. "\xde\xca\xf8\x88",
  9156. .input = "\x39\x80\xca\x0b\x3c\x00\xe8\x41"
  9157. "\xeb\x06\xfa\xc4\x87\x2a\x27\x57"
  9158. "\x85\x9e\x1c\xea\xa6\xef\xd9\x84"
  9159. "\x62\x85\x93\xb4\x0c\xa1\xe1\x9c"
  9160. "\x7d\x77\x3d\x00\xc1\x44\xc5\x25"
  9161. "\xac\x61\x9d\x18\xc8\x4a\x3f\x47"
  9162. "\x18\xe2\x44\x8b\x2f\xe3\x24\xd9"
  9163. "\xcc\xda\x27\x10\xac\xad\xe2\x56"
  9164. "\x99\x24\xa7\xc8\x58\x73\x36\xbf"
  9165. "\xb1\x18\x02\x4d\xb8\x67\x4a\x14",
  9166. .ilen = 80,
  9167. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9168. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9169. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9170. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9171. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9172. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9173. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9174. "\xba\x63\x7b\x39\x1a\xaf\xd2\x55",
  9175. .rlen = 64,
  9176. }, {
  9177. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9178. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9179. "\xfe\xff\xe9\x92\x86\x65\x73\x1c",
  9180. .klen = 24,
  9181. .iv = "\xca\xfe\xba\xbe\xfa\xce\xdb\xad"
  9182. "\xde\xca\xf8\x88",
  9183. .input = "\x39\x80\xca\x0b\x3c\x00\xe8\x41"
  9184. "\xeb\x06\xfa\xc4\x87\x2a\x27\x57"
  9185. "\x85\x9e\x1c\xea\xa6\xef\xd9\x84"
  9186. "\x62\x85\x93\xb4\x0c\xa1\xe1\x9c"
  9187. "\x7d\x77\x3d\x00\xc1\x44\xc5\x25"
  9188. "\xac\x61\x9d\x18\xc8\x4a\x3f\x47"
  9189. "\x18\xe2\x44\x8b\x2f\xe3\x24\xd9"
  9190. "\xcc\xda\x27\x10"
  9191. "\x25\x19\x49\x8e\x80\xf1\x47\x8f"
  9192. "\x37\xba\x55\xbd\x6d\x27\x61\x8c",
  9193. .ilen = 76,
  9194. .assoc = "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9195. "\xfe\xed\xfa\xce\xde\xad\xbe\xef"
  9196. "\xab\xad\xda\xd2",
  9197. .alen = 20,
  9198. .result = "\xd9\x31\x32\x25\xf8\x84\x06\xe5"
  9199. "\xa5\x59\x09\xc5\xaf\xf5\x26\x9a"
  9200. "\x86\xa7\xa9\x53\x15\x34\xf7\xda"
  9201. "\x2e\x4c\x30\x3d\x8a\x31\x8a\x72"
  9202. "\x1c\x3c\x0c\x95\x95\x68\x09\x53"
  9203. "\x2f\xcf\x0e\x24\x49\xa6\xb5\x25"
  9204. "\xb1\x6a\xed\xf5\xaa\x0d\xe6\x57"
  9205. "\xba\x63\x7b\x39",
  9206. .rlen = 60,
  9207. }
  9208. };
  9209. static struct aead_testvec aes_gcm_rfc4106_enc_tv_template[] = {
  9210. { /* Generated using Crypto++ */
  9211. .key = zeroed_string,
  9212. .klen = 20,
  9213. .iv = zeroed_string,
  9214. .input = zeroed_string,
  9215. .ilen = 16,
  9216. .assoc = zeroed_string,
  9217. .alen = 8,
  9218. .result = "\x03\x88\xDA\xCE\x60\xB6\xA3\x92"
  9219. "\xF3\x28\xC2\xB9\x71\xB2\xFE\x78"
  9220. "\x97\xFE\x4C\x23\x37\x42\x01\xE0"
  9221. "\x81\x9F\x8D\xC5\xD7\x41\xA0\x1B",
  9222. .rlen = 32,
  9223. },{
  9224. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9225. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9226. "\x00\x00\x00\x00",
  9227. .klen = 20,
  9228. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9229. "\x00\x00\x00\x00",
  9230. .input = zeroed_string,
  9231. .ilen = 16,
  9232. .assoc = zeroed_string,
  9233. .alen = 8,
  9234. .result = "\xC0\x0D\x8B\x42\x0F\x8F\x34\x18"
  9235. "\x88\xB1\xC5\xBC\xC5\xB6\xD6\x28"
  9236. "\x6A\x9D\xDF\x11\x5E\xFE\x5E\x9D"
  9237. "\x2F\x70\x44\x92\xF7\xF2\xE3\xEF",
  9238. .rlen = 32,
  9239. }, {
  9240. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9241. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9242. "\x00\x00\x00\x00",
  9243. .klen = 20,
  9244. .iv = zeroed_string,
  9245. .input = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9246. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9247. .ilen = 16,
  9248. .assoc = zeroed_string,
  9249. .alen = 8,
  9250. .result = "\x4B\xB1\xB5\xE3\x25\x71\x70\xDE"
  9251. "\x7F\xC9\x9C\xA5\x14\x19\xF2\xAC"
  9252. "\x0B\x8F\x88\x69\x17\xE6\xB4\x3C"
  9253. "\xB1\x68\xFD\x14\x52\x64\x61\xB2",
  9254. .rlen = 32,
  9255. }, {
  9256. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9257. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9258. "\x00\x00\x00\x00",
  9259. .klen = 20,
  9260. .iv = zeroed_string,
  9261. .input = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9262. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9263. .ilen = 16,
  9264. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9265. .alen = 8,
  9266. .result = "\x4B\xB1\xB5\xE3\x25\x71\x70\xDE"
  9267. "\x7F\xC9\x9C\xA5\x14\x19\xF2\xAC"
  9268. "\x90\x92\xB7\xE3\x5F\xA3\x9A\x63"
  9269. "\x7E\xD7\x1F\xD8\xD3\x7C\x4B\xF5",
  9270. .rlen = 32,
  9271. }, {
  9272. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9273. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9274. "\x00\x00\x00\x00",
  9275. .klen = 20,
  9276. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9277. "\x00\x00\x00\x00",
  9278. .input = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9279. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9280. .ilen = 16,
  9281. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9282. .alen = 8,
  9283. .result = "\xC1\x0C\x8A\x43\x0E\x8E\x35\x19"
  9284. "\x89\xB0\xC4\xBD\xC4\xB7\xD7\x29"
  9285. "\x64\x50\xF9\x32\x13\xFB\x74\x61"
  9286. "\xF4\xED\x52\xD3\xC5\x10\x55\x3C",
  9287. .rlen = 32,
  9288. }, {
  9289. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9290. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9291. "\x00\x00\x00\x00",
  9292. .klen = 20,
  9293. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9294. "\x00\x00\x00\x00",
  9295. .input = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9296. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9297. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9298. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9299. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9300. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9301. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9302. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9303. .ilen = 64,
  9304. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9305. .alen = 8,
  9306. .result = "\xC1\x0C\x8A\x43\x0E\x8E\x35\x19"
  9307. "\x89\xB0\xC4\xBD\xC4\xB7\xD7\x29"
  9308. "\x98\x14\xA1\x42\x37\x80\xFD\x90"
  9309. "\x68\x12\x01\xA8\x91\x89\xB9\x83"
  9310. "\x5B\x11\x77\x12\x9B\xFF\x24\x89"
  9311. "\x94\x5F\x18\x12\xBA\x27\x09\x39"
  9312. "\x99\x96\x76\x42\x15\x1C\xCD\xCB"
  9313. "\xDC\xD3\xDA\x65\x73\xAF\x80\xCD"
  9314. "\xD2\xB6\xC2\x4A\x76\xC2\x92\x85"
  9315. "\xBD\xCF\x62\x98\x58\x14\xE5\xBD",
  9316. .rlen = 80,
  9317. }, {
  9318. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9319. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9320. "\x00\x00\x00\x00",
  9321. .klen = 20,
  9322. .iv = "\x00\x00\x45\x67\x89\xab\xcd\xef"
  9323. "\x00\x00\x00\x00",
  9324. .input = "\xff\xff\xff\xff\xff\xff\xff\xff"
  9325. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9326. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9327. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9328. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9329. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9330. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9331. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9332. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9333. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9334. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9335. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9336. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9337. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9338. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9339. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9340. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9341. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9342. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9343. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9344. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9345. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9346. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9347. "\xff\xff\xff\xff\xff\xff\xff\xff",
  9348. .ilen = 192,
  9349. .assoc = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  9350. "\xaa\xaa\xaa\xaa",
  9351. .alen = 12,
  9352. .result = "\xC1\x76\x33\x85\xE2\x9B\x5F\xDE"
  9353. "\xDE\x89\x3D\x42\xE7\xC9\x69\x8A"
  9354. "\x44\x6D\xC3\x88\x46\x2E\xC2\x01"
  9355. "\x5E\xF6\x0C\x39\xF0\xC4\xA5\x82"
  9356. "\xCD\xE8\x31\xCC\x0A\x4C\xE4\x44"
  9357. "\x41\xA9\x82\x6F\x22\xA1\x23\x1A"
  9358. "\xA8\xE3\x16\xFD\x31\x5C\x27\x31"
  9359. "\xF1\x7F\x01\x63\xA3\xAF\x70\xA1"
  9360. "\xCF\x07\x57\x41\x67\xD0\xC4\x42"
  9361. "\xDB\x18\xC6\x4C\x4C\xE0\x3D\x9F"
  9362. "\x05\x07\xFB\x13\x7D\x4A\xCA\x5B"
  9363. "\xF0\xBF\x64\x7E\x05\xB1\x72\xEE"
  9364. "\x7C\x3B\xD4\xCD\x14\x03\xB2\x2C"
  9365. "\xD3\xA9\xEE\xFA\x17\xFC\x9C\xDF"
  9366. "\xC7\x75\x40\xFF\xAE\xAD\x1E\x59"
  9367. "\x2F\x30\x24\xFB\xAD\x6B\x10\xFA"
  9368. "\x6C\x9F\x5B\xE7\x25\xD5\xD0\x25"
  9369. "\xAC\x4A\x4B\xDA\xFC\x7A\x85\x1B"
  9370. "\x7E\x13\x06\x82\x08\x17\xA4\x35"
  9371. "\xEC\xC5\x8D\x63\x96\x81\x0A\x8F"
  9372. "\xA3\x05\x38\x95\x20\x1A\x47\x04"
  9373. "\x6F\x6D\xDA\x8F\xEF\xC1\x76\x35"
  9374. "\x6B\xC7\x4D\x0F\x94\x12\xCA\x3E"
  9375. "\x2E\xD5\x03\x2E\x86\x7E\xAA\x3B"
  9376. "\x37\x08\x1C\xCF\xBA\x5D\x71\x46"
  9377. "\x80\x72\xB0\x4C\x82\x0D\x60\x3C",
  9378. .rlen = 208,
  9379. }
  9380. };
  9381. static struct aead_testvec aes_gcm_rfc4106_dec_tv_template[] = {
  9382. { /* Generated using Crypto++ */
  9383. .key = zeroed_string,
  9384. .klen = 20,
  9385. .iv = zeroed_string,
  9386. .input = "\x03\x88\xDA\xCE\x60\xB6\xA3\x92"
  9387. "\xF3\x28\xC2\xB9\x71\xB2\xFE\x78"
  9388. "\x97\xFE\x4C\x23\x37\x42\x01\xE0"
  9389. "\x81\x9F\x8D\xC5\xD7\x41\xA0\x1B",
  9390. .ilen = 32,
  9391. .assoc = zeroed_string,
  9392. .alen = 8,
  9393. .result = zeroed_string,
  9394. .rlen = 16,
  9395. },{
  9396. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9397. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9398. "\x00\x00\x00\x00",
  9399. .klen = 20,
  9400. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9401. "\x00\x00\x00\x00",
  9402. .input = "\xC0\x0D\x8B\x42\x0F\x8F\x34\x18"
  9403. "\x88\xB1\xC5\xBC\xC5\xB6\xD6\x28"
  9404. "\x6A\x9D\xDF\x11\x5E\xFE\x5E\x9D"
  9405. "\x2F\x70\x44\x92\xF7\xF2\xE3\xEF",
  9406. .ilen = 32,
  9407. .assoc = zeroed_string,
  9408. .alen = 8,
  9409. .result = zeroed_string,
  9410. .rlen = 16,
  9411. }, {
  9412. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9413. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9414. "\x00\x00\x00\x00",
  9415. .klen = 20,
  9416. .iv = zeroed_string,
  9417. .input = "\x4B\xB1\xB5\xE3\x25\x71\x70\xDE"
  9418. "\x7F\xC9\x9C\xA5\x14\x19\xF2\xAC"
  9419. "\x0B\x8F\x88\x69\x17\xE6\xB4\x3C"
  9420. "\xB1\x68\xFD\x14\x52\x64\x61\xB2",
  9421. .ilen = 32,
  9422. .assoc = zeroed_string,
  9423. .alen = 8,
  9424. .result = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9425. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9426. .rlen = 16,
  9427. }, {
  9428. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9429. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9430. "\x00\x00\x00\x00",
  9431. .klen = 20,
  9432. .iv = zeroed_string,
  9433. .input = "\x4B\xB1\xB5\xE3\x25\x71\x70\xDE"
  9434. "\x7F\xC9\x9C\xA5\x14\x19\xF2\xAC"
  9435. "\x90\x92\xB7\xE3\x5F\xA3\x9A\x63"
  9436. "\x7E\xD7\x1F\xD8\xD3\x7C\x4B\xF5",
  9437. .ilen = 32,
  9438. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9439. .alen = 8,
  9440. .result = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9441. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9442. .rlen = 16,
  9443. }, {
  9444. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9445. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9446. "\x00\x00\x00\x00",
  9447. .klen = 20,
  9448. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9449. "\x00\x00\x00\x00",
  9450. .input = "\xC1\x0C\x8A\x43\x0E\x8E\x35\x19"
  9451. "\x89\xB0\xC4\xBD\xC4\xB7\xD7\x29"
  9452. "\x64\x50\xF9\x32\x13\xFB\x74\x61"
  9453. "\xF4\xED\x52\xD3\xC5\x10\x55\x3C",
  9454. .ilen = 32,
  9455. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9456. .alen = 8,
  9457. .result = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9458. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9459. .rlen = 16,
  9460. }, {
  9461. .key = "\xfe\xff\xe9\x92\x86\x65\x73\x1c"
  9462. "\x6d\x6a\x8f\x94\x67\x30\x83\x08"
  9463. "\x00\x00\x00\x00",
  9464. .klen = 20,
  9465. .iv = "\x00\x00\x00\x00\x00\x00\x00\x01"
  9466. "\x00\x00\x00\x00",
  9467. .input = "\xC1\x0C\x8A\x43\x0E\x8E\x35\x19"
  9468. "\x89\xB0\xC4\xBD\xC4\xB7\xD7\x29"
  9469. "\x98\x14\xA1\x42\x37\x80\xFD\x90"
  9470. "\x68\x12\x01\xA8\x91\x89\xB9\x83"
  9471. "\x5B\x11\x77\x12\x9B\xFF\x24\x89"
  9472. "\x94\x5F\x18\x12\xBA\x27\x09\x39"
  9473. "\x99\x96\x76\x42\x15\x1C\xCD\xCB"
  9474. "\xDC\xD3\xDA\x65\x73\xAF\x80\xCD"
  9475. "\xD2\xB6\xC2\x4A\x76\xC2\x92\x85"
  9476. "\xBD\xCF\x62\x98\x58\x14\xE5\xBD",
  9477. .ilen = 80,
  9478. .assoc = "\x01\x01\x01\x01\x01\x01\x01\x01",
  9479. .alen = 8,
  9480. .result = "\x01\x01\x01\x01\x01\x01\x01\x01"
  9481. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9482. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9483. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9484. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9485. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9486. "\x01\x01\x01\x01\x01\x01\x01\x01"
  9487. "\x01\x01\x01\x01\x01\x01\x01\x01",
  9488. .rlen = 64,
  9489. }, {
  9490. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9491. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9492. "\x00\x00\x00\x00",
  9493. .klen = 20,
  9494. .iv = "\x00\x00\x45\x67\x89\xab\xcd\xef"
  9495. "\x00\x00\x00\x00",
  9496. .input = "\xC1\x76\x33\x85\xE2\x9B\x5F\xDE"
  9497. "\xDE\x89\x3D\x42\xE7\xC9\x69\x8A"
  9498. "\x44\x6D\xC3\x88\x46\x2E\xC2\x01"
  9499. "\x5E\xF6\x0C\x39\xF0\xC4\xA5\x82"
  9500. "\xCD\xE8\x31\xCC\x0A\x4C\xE4\x44"
  9501. "\x41\xA9\x82\x6F\x22\xA1\x23\x1A"
  9502. "\xA8\xE3\x16\xFD\x31\x5C\x27\x31"
  9503. "\xF1\x7F\x01\x63\xA3\xAF\x70\xA1"
  9504. "\xCF\x07\x57\x41\x67\xD0\xC4\x42"
  9505. "\xDB\x18\xC6\x4C\x4C\xE0\x3D\x9F"
  9506. "\x05\x07\xFB\x13\x7D\x4A\xCA\x5B"
  9507. "\xF0\xBF\x64\x7E\x05\xB1\x72\xEE"
  9508. "\x7C\x3B\xD4\xCD\x14\x03\xB2\x2C"
  9509. "\xD3\xA9\xEE\xFA\x17\xFC\x9C\xDF"
  9510. "\xC7\x75\x40\xFF\xAE\xAD\x1E\x59"
  9511. "\x2F\x30\x24\xFB\xAD\x6B\x10\xFA"
  9512. "\x6C\x9F\x5B\xE7\x25\xD5\xD0\x25"
  9513. "\xAC\x4A\x4B\xDA\xFC\x7A\x85\x1B"
  9514. "\x7E\x13\x06\x82\x08\x17\xA4\x35"
  9515. "\xEC\xC5\x8D\x63\x96\x81\x0A\x8F"
  9516. "\xA3\x05\x38\x95\x20\x1A\x47\x04"
  9517. "\x6F\x6D\xDA\x8F\xEF\xC1\x76\x35"
  9518. "\x6B\xC7\x4D\x0F\x94\x12\xCA\x3E"
  9519. "\x2E\xD5\x03\x2E\x86\x7E\xAA\x3B"
  9520. "\x37\x08\x1C\xCF\xBA\x5D\x71\x46"
  9521. "\x80\x72\xB0\x4C\x82\x0D\x60\x3C",
  9522. .ilen = 208,
  9523. .assoc = "\xaa\xaa\xaa\xaa\xaa\xaa\xaa\xaa"
  9524. "\xaa\xaa\xaa\xaa",
  9525. .alen = 12,
  9526. .result = "\xff\xff\xff\xff\xff\xff\xff\xff"
  9527. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9528. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9529. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9530. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9531. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9532. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9533. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9534. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9535. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9536. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9537. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9538. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9539. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9540. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9541. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9542. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9543. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9544. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9545. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9546. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9547. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9548. "\xff\xff\xff\xff\xff\xff\xff\xff"
  9549. "\xff\xff\xff\xff\xff\xff\xff\xff",
  9550. .rlen = 192,
  9551. }
  9552. };
  9553. static struct aead_testvec aes_ccm_enc_tv_template[] = {
  9554. { /* From RFC 3610 */
  9555. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9556. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9557. .klen = 16,
  9558. .iv = "\x01\x00\x00\x00\x03\x02\x01\x00"
  9559. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9560. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07",
  9561. .alen = 8,
  9562. .input = "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9563. "\x10\x11\x12\x13\x14\x15\x16\x17"
  9564. "\x18\x19\x1a\x1b\x1c\x1d\x1e",
  9565. .ilen = 23,
  9566. .result = "\x58\x8c\x97\x9a\x61\xc6\x63\xd2"
  9567. "\xf0\x66\xd0\xc2\xc0\xf9\x89\x80"
  9568. "\x6d\x5f\x6b\x61\xda\xc3\x84\x17"
  9569. "\xe8\xd1\x2c\xfd\xf9\x26\xe0",
  9570. .rlen = 31,
  9571. }, {
  9572. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9573. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9574. .klen = 16,
  9575. .iv = "\x01\x00\x00\x00\x07\x06\x05\x04"
  9576. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9577. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9578. "\x08\x09\x0a\x0b",
  9579. .alen = 12,
  9580. .input = "\x0c\x0d\x0e\x0f\x10\x11\x12\x13"
  9581. "\x14\x15\x16\x17\x18\x19\x1a\x1b"
  9582. "\x1c\x1d\x1e\x1f",
  9583. .ilen = 20,
  9584. .result = "\xdc\xf1\xfb\x7b\x5d\x9e\x23\xfb"
  9585. "\x9d\x4e\x13\x12\x53\x65\x8a\xd8"
  9586. "\x6e\xbd\xca\x3e\x51\xe8\x3f\x07"
  9587. "\x7d\x9c\x2d\x93",
  9588. .rlen = 28,
  9589. }, {
  9590. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9591. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9592. .klen = 16,
  9593. .iv = "\x01\x00\x00\x00\x0b\x0a\x09\x08"
  9594. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9595. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07",
  9596. .alen = 8,
  9597. .input = "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9598. "\x10\x11\x12\x13\x14\x15\x16\x17"
  9599. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  9600. "\x20",
  9601. .ilen = 25,
  9602. .result = "\x82\x53\x1a\x60\xcc\x24\x94\x5a"
  9603. "\x4b\x82\x79\x18\x1a\xb5\xc8\x4d"
  9604. "\xf2\x1c\xe7\xf9\xb7\x3f\x42\xe1"
  9605. "\x97\xea\x9c\x07\xe5\x6b\x5e\xb1"
  9606. "\x7e\x5f\x4e",
  9607. .rlen = 35,
  9608. }, {
  9609. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9610. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9611. .klen = 16,
  9612. .iv = "\x01\x00\x00\x00\x0c\x0b\x0a\x09"
  9613. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9614. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9615. "\x08\x09\x0a\x0b",
  9616. .alen = 12,
  9617. .input = "\x0c\x0d\x0e\x0f\x10\x11\x12\x13"
  9618. "\x14\x15\x16\x17\x18\x19\x1a\x1b"
  9619. "\x1c\x1d\x1e",
  9620. .ilen = 19,
  9621. .result = "\x07\x34\x25\x94\x15\x77\x85\x15"
  9622. "\x2b\x07\x40\x98\x33\x0a\xbb\x14"
  9623. "\x1b\x94\x7b\x56\x6a\xa9\x40\x6b"
  9624. "\x4d\x99\x99\x88\xdd",
  9625. .rlen = 29,
  9626. }, {
  9627. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9628. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9629. .klen = 16,
  9630. .iv = "\x01\x00\x33\x56\x8e\xf7\xb2\x63"
  9631. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9632. .assoc = "\x63\x01\x8f\x76\xdc\x8a\x1b\xcb",
  9633. .alen = 8,
  9634. .input = "\x90\x20\xea\x6f\x91\xbd\xd8\x5a"
  9635. "\xfa\x00\x39\xba\x4b\xaf\xf9\xbf"
  9636. "\xb7\x9c\x70\x28\x94\x9c\xd0\xec",
  9637. .ilen = 24,
  9638. .result = "\x4c\xcb\x1e\x7c\xa9\x81\xbe\xfa"
  9639. "\xa0\x72\x6c\x55\xd3\x78\x06\x12"
  9640. "\x98\xc8\x5c\x92\x81\x4a\xbc\x33"
  9641. "\xc5\x2e\xe8\x1d\x7d\x77\xc0\x8a",
  9642. .rlen = 32,
  9643. }, {
  9644. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9645. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9646. .klen = 16,
  9647. .iv = "\x01\x00\xd5\x60\x91\x2d\x3f\x70"
  9648. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9649. .assoc = "\xcd\x90\x44\xd2\xb7\x1f\xdb\x81"
  9650. "\x20\xea\x60\xc0",
  9651. .alen = 12,
  9652. .input = "\x64\x35\xac\xba\xfb\x11\xa8\x2e"
  9653. "\x2f\x07\x1d\x7c\xa4\xa5\xeb\xd9"
  9654. "\x3a\x80\x3b\xa8\x7f",
  9655. .ilen = 21,
  9656. .result = "\x00\x97\x69\xec\xab\xdf\x48\x62"
  9657. "\x55\x94\xc5\x92\x51\xe6\x03\x57"
  9658. "\x22\x67\x5e\x04\xc8\x47\x09\x9e"
  9659. "\x5a\xe0\x70\x45\x51",
  9660. .rlen = 29,
  9661. }, {
  9662. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9663. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9664. .klen = 16,
  9665. .iv = "\x01\x00\x42\xff\xf8\xf1\x95\x1c"
  9666. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9667. .assoc = "\xd8\x5b\xc7\xe6\x9f\x94\x4f\xb8",
  9668. .alen = 8,
  9669. .input = "\x8a\x19\xb9\x50\xbc\xf7\x1a\x01"
  9670. "\x8e\x5e\x67\x01\xc9\x17\x87\x65"
  9671. "\x98\x09\xd6\x7d\xbe\xdd\x18",
  9672. .ilen = 23,
  9673. .result = "\xbc\x21\x8d\xaa\x94\x74\x27\xb6"
  9674. "\xdb\x38\x6a\x99\xac\x1a\xef\x23"
  9675. "\xad\xe0\xb5\x29\x39\xcb\x6a\x63"
  9676. "\x7c\xf9\xbe\xc2\x40\x88\x97\xc6"
  9677. "\xba",
  9678. .rlen = 33,
  9679. },
  9680. };
  9681. static struct aead_testvec aes_ccm_dec_tv_template[] = {
  9682. { /* From RFC 3610 */
  9683. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9684. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9685. .klen = 16,
  9686. .iv = "\x01\x00\x00\x00\x03\x02\x01\x00"
  9687. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9688. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07",
  9689. .alen = 8,
  9690. .input = "\x58\x8c\x97\x9a\x61\xc6\x63\xd2"
  9691. "\xf0\x66\xd0\xc2\xc0\xf9\x89\x80"
  9692. "\x6d\x5f\x6b\x61\xda\xc3\x84\x17"
  9693. "\xe8\xd1\x2c\xfd\xf9\x26\xe0",
  9694. .ilen = 31,
  9695. .result = "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9696. "\x10\x11\x12\x13\x14\x15\x16\x17"
  9697. "\x18\x19\x1a\x1b\x1c\x1d\x1e",
  9698. .rlen = 23,
  9699. }, {
  9700. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9701. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9702. .klen = 16,
  9703. .iv = "\x01\x00\x00\x00\x07\x06\x05\x04"
  9704. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9705. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9706. "\x08\x09\x0a\x0b",
  9707. .alen = 12,
  9708. .input = "\xdc\xf1\xfb\x7b\x5d\x9e\x23\xfb"
  9709. "\x9d\x4e\x13\x12\x53\x65\x8a\xd8"
  9710. "\x6e\xbd\xca\x3e\x51\xe8\x3f\x07"
  9711. "\x7d\x9c\x2d\x93",
  9712. .ilen = 28,
  9713. .result = "\x0c\x0d\x0e\x0f\x10\x11\x12\x13"
  9714. "\x14\x15\x16\x17\x18\x19\x1a\x1b"
  9715. "\x1c\x1d\x1e\x1f",
  9716. .rlen = 20,
  9717. }, {
  9718. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9719. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9720. .klen = 16,
  9721. .iv = "\x01\x00\x00\x00\x0b\x0a\x09\x08"
  9722. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9723. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07",
  9724. .alen = 8,
  9725. .input = "\x82\x53\x1a\x60\xcc\x24\x94\x5a"
  9726. "\x4b\x82\x79\x18\x1a\xb5\xc8\x4d"
  9727. "\xf2\x1c\xe7\xf9\xb7\x3f\x42\xe1"
  9728. "\x97\xea\x9c\x07\xe5\x6b\x5e\xb1"
  9729. "\x7e\x5f\x4e",
  9730. .ilen = 35,
  9731. .result = "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  9732. "\x10\x11\x12\x13\x14\x15\x16\x17"
  9733. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  9734. "\x20",
  9735. .rlen = 25,
  9736. }, {
  9737. .key = "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  9738. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf",
  9739. .klen = 16,
  9740. .iv = "\x01\x00\x00\x00\x0c\x0b\x0a\x09"
  9741. "\xa0\xa1\xa2\xa3\xa4\xa5\x00\x00",
  9742. .assoc = "\x00\x01\x02\x03\x04\x05\x06\x07"
  9743. "\x08\x09\x0a\x0b",
  9744. .alen = 12,
  9745. .input = "\x07\x34\x25\x94\x15\x77\x85\x15"
  9746. "\x2b\x07\x40\x98\x33\x0a\xbb\x14"
  9747. "\x1b\x94\x7b\x56\x6a\xa9\x40\x6b"
  9748. "\x4d\x99\x99\x88\xdd",
  9749. .ilen = 29,
  9750. .result = "\x0c\x0d\x0e\x0f\x10\x11\x12\x13"
  9751. "\x14\x15\x16\x17\x18\x19\x1a\x1b"
  9752. "\x1c\x1d\x1e",
  9753. .rlen = 19,
  9754. }, {
  9755. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9756. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9757. .klen = 16,
  9758. .iv = "\x01\x00\x33\x56\x8e\xf7\xb2\x63"
  9759. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9760. .assoc = "\x63\x01\x8f\x76\xdc\x8a\x1b\xcb",
  9761. .alen = 8,
  9762. .input = "\x4c\xcb\x1e\x7c\xa9\x81\xbe\xfa"
  9763. "\xa0\x72\x6c\x55\xd3\x78\x06\x12"
  9764. "\x98\xc8\x5c\x92\x81\x4a\xbc\x33"
  9765. "\xc5\x2e\xe8\x1d\x7d\x77\xc0\x8a",
  9766. .ilen = 32,
  9767. .result = "\x90\x20\xea\x6f\x91\xbd\xd8\x5a"
  9768. "\xfa\x00\x39\xba\x4b\xaf\xf9\xbf"
  9769. "\xb7\x9c\x70\x28\x94\x9c\xd0\xec",
  9770. .rlen = 24,
  9771. }, {
  9772. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9773. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9774. .klen = 16,
  9775. .iv = "\x01\x00\xd5\x60\x91\x2d\x3f\x70"
  9776. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9777. .assoc = "\xcd\x90\x44\xd2\xb7\x1f\xdb\x81"
  9778. "\x20\xea\x60\xc0",
  9779. .alen = 12,
  9780. .input = "\x00\x97\x69\xec\xab\xdf\x48\x62"
  9781. "\x55\x94\xc5\x92\x51\xe6\x03\x57"
  9782. "\x22\x67\x5e\x04\xc8\x47\x09\x9e"
  9783. "\x5a\xe0\x70\x45\x51",
  9784. .ilen = 29,
  9785. .result = "\x64\x35\xac\xba\xfb\x11\xa8\x2e"
  9786. "\x2f\x07\x1d\x7c\xa4\xa5\xeb\xd9"
  9787. "\x3a\x80\x3b\xa8\x7f",
  9788. .rlen = 21,
  9789. }, {
  9790. .key = "\xd7\x82\x8d\x13\xb2\xb0\xbd\xc3"
  9791. "\x25\xa7\x62\x36\xdf\x93\xcc\x6b",
  9792. .klen = 16,
  9793. .iv = "\x01\x00\x42\xff\xf8\xf1\x95\x1c"
  9794. "\x3c\x96\x96\x76\x6c\xfa\x00\x00",
  9795. .assoc = "\xd8\x5b\xc7\xe6\x9f\x94\x4f\xb8",
  9796. .alen = 8,
  9797. .input = "\xbc\x21\x8d\xaa\x94\x74\x27\xb6"
  9798. "\xdb\x38\x6a\x99\xac\x1a\xef\x23"
  9799. "\xad\xe0\xb5\x29\x39\xcb\x6a\x63"
  9800. "\x7c\xf9\xbe\xc2\x40\x88\x97\xc6"
  9801. "\xba",
  9802. .ilen = 33,
  9803. .result = "\x8a\x19\xb9\x50\xbc\xf7\x1a\x01"
  9804. "\x8e\x5e\x67\x01\xc9\x17\x87\x65"
  9805. "\x98\x09\xd6\x7d\xbe\xdd\x18",
  9806. .rlen = 23,
  9807. },
  9808. };
  9809. /*
  9810. * rfc4309 refers to section 8 of rfc3610 for test vectors, but they all
  9811. * use a 13-byte nonce, we only support an 11-byte nonce. Similarly, all of
  9812. * Special Publication 800-38C's test vectors also use nonce lengths our
  9813. * implementation doesn't support. The following are taken from fips cavs
  9814. * fax files on hand at Red Hat.
  9815. *
  9816. * nb: actual key lengths are (klen - 3), the last 3 bytes are actually
  9817. * part of the nonce which combine w/the iv, but need to be input this way.
  9818. */
  9819. static struct aead_testvec aes_ccm_rfc4309_enc_tv_template[] = {
  9820. {
  9821. .key = "\x83\xac\x54\x66\xc2\xeb\xe5\x05"
  9822. "\x2e\x01\xd1\xfc\x5d\x82\x66\x2e"
  9823. "\x96\xac\x59",
  9824. .klen = 19,
  9825. .iv = "\x30\x07\xa1\xe2\xa2\xc7\x55\x24",
  9826. .alen = 0,
  9827. .input = "\x19\xc8\x81\xf6\xe9\x86\xff\x93"
  9828. "\x0b\x78\x67\xe5\xbb\xb7\xfc\x6e"
  9829. "\x83\x77\xb3\xa6\x0c\x8c\x9f\x9c"
  9830. "\x35\x2e\xad\xe0\x62\xf9\x91\xa1",
  9831. .ilen = 32,
  9832. .result = "\xab\x6f\xe1\x69\x1d\x19\x99\xa8"
  9833. "\x92\xa0\xc4\x6f\x7e\xe2\x8b\xb1"
  9834. "\x70\xbb\x8c\xa6\x4c\x6e\x97\x8a"
  9835. "\x57\x2b\xbe\x5d\x98\xa6\xb1\x32"
  9836. "\xda\x24\xea\xd9\xa1\x39\x98\xfd"
  9837. "\xa4\xbe\xd9\xf2\x1a\x6d\x22\xa8",
  9838. .rlen = 48,
  9839. }, {
  9840. .key = "\x1e\x2c\x7e\x01\x41\x9a\xef\xc0"
  9841. "\x0d\x58\x96\x6e\x5c\xa2\x4b\xd3"
  9842. "\x4f\xa3\x19",
  9843. .klen = 19,
  9844. .iv = "\xd3\x01\x5a\xd8\x30\x60\x15\x56",
  9845. .assoc = "\xda\xe6\x28\x9c\x45\x2d\xfd\x63"
  9846. "\x5e\xda\x4c\xb6\xe6\xfc\xf9\xb7"
  9847. "\x0c\x56\xcb\xe4\xe0\x05\x7a\xe1"
  9848. "\x0a\x63\x09\x78\xbc\x2c\x55\xde",
  9849. .alen = 32,
  9850. .input = "\x87\xa3\x36\xfd\x96\xb3\x93\x78"
  9851. "\xa9\x28\x63\xba\x12\xa3\x14\x85"
  9852. "\x57\x1e\x06\xc9\x7b\x21\xef\x76"
  9853. "\x7f\x38\x7e\x8e\x29\xa4\x3e\x7e",
  9854. .ilen = 32,
  9855. .result = "\x8a\x1e\x11\xf0\x02\x6b\xe2\x19"
  9856. "\xfc\x70\xc4\x6d\x8e\xb7\x99\xab"
  9857. "\xc5\x4b\xa2\xac\xd3\xf3\x48\xff"
  9858. "\x3b\xb5\xce\x53\xef\xde\xbb\x02"
  9859. "\xa9\x86\x15\x6c\x13\xfe\xda\x0a"
  9860. "\x22\xb8\x29\x3d\xd8\x39\x9a\x23",
  9861. .rlen = 48,
  9862. }, {
  9863. .key = "\xf4\x6b\xc2\x75\x62\xfe\xb4\xe1"
  9864. "\xa3\xf0\xff\xdd\x4e\x4b\x12\x75"
  9865. "\x53\x14\x73\x66\x8d\x88\xf6\x80"
  9866. "\xa0\x20\x35",
  9867. .klen = 27,
  9868. .iv = "\x26\xf2\x21\x8d\x50\x20\xda\xe2",
  9869. .assoc = "\x5b\x9e\x13\x67\x02\x5e\xef\xc1"
  9870. "\x6c\xf9\xd7\x1e\x52\x8f\x7a\x47"
  9871. "\xe9\xd4\xcf\x20\x14\x6e\xf0\x2d"
  9872. "\xd8\x9e\x2b\x56\x10\x23\x56\xe7",
  9873. .alen = 32,
  9874. .ilen = 0,
  9875. .result = "\x36\xea\x7a\x70\x08\xdc\x6a\xbc"
  9876. "\xad\x0c\x7a\x63\xf6\x61\xfd\x9b",
  9877. .rlen = 16,
  9878. }, {
  9879. .key = "\x56\xdf\x5c\x8f\x26\x3f\x0e\x42"
  9880. "\xef\x7a\xd3\xce\xfc\x84\x60\x62"
  9881. "\xca\xb4\x40\xaf\x5f\xc9\xc9\x01"
  9882. "\xd6\x3c\x8c",
  9883. .klen = 27,
  9884. .iv = "\x86\x84\xb6\xcd\xef\x09\x2e\x94",
  9885. .assoc = "\x02\x65\x78\x3c\xe9\x21\x30\x91"
  9886. "\xb1\xb9\xda\x76\x9a\x78\x6d\x95"
  9887. "\xf2\x88\x32\xa3\xf2\x50\xcb\x4c"
  9888. "\xe3\x00\x73\x69\x84\x69\x87\x79",
  9889. .alen = 32,
  9890. .input = "\x9f\xd2\x02\x4b\x52\x49\x31\x3c"
  9891. "\x43\x69\x3a\x2d\x8e\x70\xad\x7e"
  9892. "\xe0\xe5\x46\x09\x80\x89\x13\xb2"
  9893. "\x8c\x8b\xd9\x3f\x86\xfb\xb5\x6b",
  9894. .ilen = 32,
  9895. .result = "\x39\xdf\x7c\x3c\x5a\x29\xb9\x62"
  9896. "\x5d\x51\xc2\x16\xd8\xbd\x06\x9f"
  9897. "\x9b\x6a\x09\x70\xc1\x51\x83\xc2"
  9898. "\x66\x88\x1d\x4f\x9a\xda\xe0\x1e"
  9899. "\xc7\x79\x11\x58\xe5\x6b\x20\x40"
  9900. "\x7a\xea\x46\x42\x8b\xe4\x6f\xe1",
  9901. .rlen = 48,
  9902. }, {
  9903. .key = "\xe0\x8d\x99\x71\x60\xd7\x97\x1a"
  9904. "\xbd\x01\x99\xd5\x8a\xdf\x71\x3a"
  9905. "\xd3\xdf\x24\x4b\x5e\x3d\x4b\x4e"
  9906. "\x30\x7a\xb9\xd8\x53\x0a\x5e\x2b"
  9907. "\x1e\x29\x91",
  9908. .klen = 35,
  9909. .iv = "\xad\x8e\xc1\x53\x0a\xcf\x2d\xbe",
  9910. .assoc = "\x19\xb6\x1f\x57\xc4\xf3\xf0\x8b"
  9911. "\x78\x2b\x94\x02\x29\x0f\x42\x27"
  9912. "\x6b\x75\xcb\x98\x34\x08\x7e\x79"
  9913. "\xe4\x3e\x49\x0d\x84\x8b\x22\x87",
  9914. .alen = 32,
  9915. .input = "\xe1\xd9\xd8\x13\xeb\x3a\x75\x3f"
  9916. "\x9d\xbd\x5f\x66\xbe\xdc\xbb\x66"
  9917. "\xbf\x17\x99\x62\x4a\x39\x27\x1f"
  9918. "\x1d\xdc\x24\xae\x19\x2f\x98\x4c",
  9919. .ilen = 32,
  9920. .result = "\x19\xb8\x61\x33\x45\x2b\x43\x96"
  9921. "\x6f\x51\xd0\x20\x30\x7d\x9b\xc6"
  9922. "\x26\x3d\xf8\xc9\x65\x16\xa8\x9f"
  9923. "\xf0\x62\x17\x34\xf2\x1e\x8d\x75"
  9924. "\x4e\x13\xcc\xc0\xc3\x2a\x54\x2d",
  9925. .rlen = 40,
  9926. }, {
  9927. .key = "\x7c\xc8\x18\x3b\x8d\x99\xe0\x7c"
  9928. "\x45\x41\xb8\xbd\x5c\xa7\xc2\x32"
  9929. "\x8a\xb8\x02\x59\xa4\xfe\xa9\x2c"
  9930. "\x09\x75\x9a\x9b\x3c\x9b\x27\x39"
  9931. "\xf9\xd9\x4e",
  9932. .klen = 35,
  9933. .iv = "\x63\xb5\x3d\x9d\x43\xf6\x1e\x50",
  9934. .assoc = "\x57\xf5\x6b\x8b\x57\x5c\x3d\x3b"
  9935. "\x13\x02\x01\x0c\x83\x4c\x96\x35"
  9936. "\x8e\xd6\x39\xcf\x7d\x14\x9b\x94"
  9937. "\xb0\x39\x36\xe6\x8f\x57\xe0\x13",
  9938. .alen = 32,
  9939. .input = "\x3b\x6c\x29\x36\xb6\xef\x07\xa6"
  9940. "\x83\x72\x07\x4f\xcf\xfa\x66\x89"
  9941. "\x5f\xca\xb1\xba\xd5\x8f\x2c\x27"
  9942. "\x30\xdb\x75\x09\x93\xd4\x65\xe4",
  9943. .ilen = 32,
  9944. .result = "\xb0\x88\x5a\x33\xaa\xe5\xc7\x1d"
  9945. "\x85\x23\xc7\xc6\x2f\xf4\x1e\x3d"
  9946. "\xcc\x63\x44\x25\x07\x78\x4f\x9e"
  9947. "\x96\xb8\x88\xeb\xbc\x48\x1f\x06"
  9948. "\x39\xaf\x39\xac\xd8\x4a\x80\x39"
  9949. "\x7b\x72\x8a\xf7",
  9950. .rlen = 44,
  9951. }, {
  9952. .key = "\xab\xd0\xe9\x33\x07\x26\xe5\x83"
  9953. "\x8c\x76\x95\xd4\xb6\xdc\xf3\x46"
  9954. "\xf9\x8f\xad\xe3\x02\x13\x83\x77"
  9955. "\x3f\xb0\xf1\xa1\xa1\x22\x0f\x2b"
  9956. "\x24\xa7\x8b",
  9957. .klen = 35,
  9958. .iv = "\x07\xcb\xcc\x0e\xe6\x33\xbf\xf5",
  9959. .assoc = "\xd4\xdb\x30\x1d\x03\xfe\xfd\x5f"
  9960. "\x87\xd4\x8c\xb6\xb6\xf1\x7a\x5d"
  9961. "\xab\x90\x65\x8d\x8e\xca\x4d\x4f"
  9962. "\x16\x0c\x40\x90\x4b\xc7\x36\x73",
  9963. .alen = 32,
  9964. .input = "\xf5\xc6\x7d\x48\xc1\xb7\xe6\x92"
  9965. "\x97\x5a\xca\xc4\xa9\x6d\xf9\x3d"
  9966. "\x6c\xde\xbc\xf1\x90\xea\x6a\xb2"
  9967. "\x35\x86\x36\xaf\x5c\xfe\x4b\x3a",
  9968. .ilen = 32,
  9969. .result = "\x83\x6f\x40\x87\x72\xcf\xc1\x13"
  9970. "\xef\xbb\x80\x21\x04\x6c\x58\x09"
  9971. "\x07\x1b\xfc\xdf\xc0\x3f\x5b\xc7"
  9972. "\xe0\x79\xa8\x6e\x71\x7c\x3f\xcf"
  9973. "\x5c\xda\xb2\x33\xe5\x13\xe2\x0d"
  9974. "\x74\xd1\xef\xb5\x0f\x3a\xb5\xf8",
  9975. .rlen = 48,
  9976. },
  9977. };
  9978. static struct aead_testvec aes_ccm_rfc4309_dec_tv_template[] = {
  9979. {
  9980. .key = "\xab\x2f\x8a\x74\xb7\x1c\xd2\xb1"
  9981. "\xff\x80\x2e\x48\x7d\x82\xf8\xb9"
  9982. "\xc6\xfb\x7d",
  9983. .klen = 19,
  9984. .iv = "\x80\x0d\x13\xab\xd8\xa6\xb2\xd8",
  9985. .alen = 0,
  9986. .input = "\xd5\xe8\x93\x9f\xc7\x89\x2e\x2b",
  9987. .ilen = 8,
  9988. .result = "\x00",
  9989. .rlen = 0,
  9990. .novrfy = 1,
  9991. }, {
  9992. .key = "\xab\x2f\x8a\x74\xb7\x1c\xd2\xb1"
  9993. "\xff\x80\x2e\x48\x7d\x82\xf8\xb9"
  9994. "\xaf\x94\x87",
  9995. .klen = 19,
  9996. .iv = "\x78\x35\x82\x81\x7f\x88\x94\x68",
  9997. .alen = 0,
  9998. .input = "\x41\x3c\xb8\x87\x73\xcb\xf3\xf3",
  9999. .ilen = 8,
  10000. .result = "\x00",
  10001. .rlen = 0,
  10002. }, {
  10003. .key = "\x61\x0e\x8c\xae\xe3\x23\xb6\x38"
  10004. "\x76\x1c\xf6\x3a\x67\xa3\x9c\xd8"
  10005. "\xc6\xfb\x7d",
  10006. .klen = 19,
  10007. .iv = "\x80\x0d\x13\xab\xd8\xa6\xb2\xd8",
  10008. .assoc = "\xf3\x94\x87\x78\x35\x82\x81\x7f"
  10009. "\x88\x94\x68\xb1\x78\x6b\x2b\xd6"
  10010. "\x04\x1f\x4e\xed\x78\xd5\x33\x66"
  10011. "\xd8\x94\x99\x91\x81\x54\x62\x57",
  10012. .alen = 32,
  10013. .input = "\xf0\x7c\x29\x02\xae\x1c\x2f\x55"
  10014. "\xd0\xd1\x3d\x1a\xa3\x6d\xe4\x0a"
  10015. "\x86\xb0\x87\x6b\x62\x33\x8c\x34"
  10016. "\xce\xab\x57\xcc\x79\x0b\xe0\x6f"
  10017. "\x5c\x3e\x48\x1f\x6c\x46\xf7\x51"
  10018. "\x8b\x84\x83\x2a\xc1\x05\xb8\xc5",
  10019. .ilen = 48,
  10020. .result = "\x50\x82\x3e\x07\xe2\x1e\xb6\xfb"
  10021. "\x33\xe4\x73\xce\xd2\xfb\x95\x79"
  10022. "\xe8\xb4\xb5\x77\x11\x10\x62\x6f"
  10023. "\x6a\x82\xd1\x13\xec\xf5\xd0\x48",
  10024. .rlen = 32,
  10025. .novrfy = 1,
  10026. }, {
  10027. .key = "\x61\x0e\x8c\xae\xe3\x23\xb6\x38"
  10028. "\x76\x1c\xf6\x3a\x67\xa3\x9c\xd8"
  10029. "\x05\xe0\xc9",
  10030. .klen = 19,
  10031. .iv = "\x0f\xed\x34\xea\x97\xd4\x3b\xdf",
  10032. .assoc = "\x49\x5c\x50\x1f\x1d\x94\xcc\x81"
  10033. "\xba\xb7\xb6\x03\xaf\xa5\xc1\xa1"
  10034. "\xd8\x5c\x42\x68\xe0\x6c\xda\x89"
  10035. "\x05\xac\x56\xac\x1b\x2a\xd3\x86",
  10036. .alen = 32,
  10037. .input = "\x39\xbe\x7d\x15\x62\x77\xf3\x3c"
  10038. "\xad\x83\x52\x6d\x71\x03\x25\x1c"
  10039. "\xed\x81\x3a\x9a\x16\x7d\x19\x80"
  10040. "\x72\x04\x72\xd0\xf6\xff\x05\x0f"
  10041. "\xb7\x14\x30\x00\x32\x9e\xa0\xa6"
  10042. "\x9e\x5a\x18\xa1\xb8\xfe\xdb\xd3",
  10043. .ilen = 48,
  10044. .result = "\x75\x05\xbe\xc2\xd9\x1e\xde\x60"
  10045. "\x47\x3d\x8c\x7d\xbd\xb5\xd9\xb7"
  10046. "\xf2\xae\x61\x05\x8f\x82\x24\x3f"
  10047. "\x9c\x67\x91\xe1\x38\x4f\xe4\x0c",
  10048. .rlen = 32,
  10049. }, {
  10050. .key = "\x39\xbb\xa7\xbe\x59\x97\x9e\x73"
  10051. "\xa2\xbc\x6b\x98\xd7\x75\x7f\xe3"
  10052. "\xa4\x48\x93\x39\x26\x71\x4a\xc6"
  10053. "\xee\x49\x83",
  10054. .klen = 27,
  10055. .iv = "\xe9\xa9\xff\xe9\x57\xba\xfd\x9e",
  10056. .assoc = "\x44\xa6\x2c\x05\xe9\xe1\x43\xb1"
  10057. "\x58\x7c\xf2\x5c\x6d\x39\x0a\x64"
  10058. "\xa4\xf0\x13\x05\xd1\x77\x99\x67"
  10059. "\x11\xc4\xc6\xdb\x00\x56\x36\x61",
  10060. .alen = 32,
  10061. .input = "\x71\x99\xfa\xf4\x44\x12\x68\x9b",
  10062. .ilen = 8,
  10063. .result = "\x00",
  10064. .rlen = 0,
  10065. }, {
  10066. .key = "\x58\x5d\xa0\x96\x65\x1a\x04\xd7"
  10067. "\x96\xe5\xc5\x68\xaa\x95\x35\xe0"
  10068. "\x29\xa0\xba\x9e\x48\x78\xd1\xba"
  10069. "\xee\x49\x83",
  10070. .klen = 27,
  10071. .iv = "\xe9\xa9\xff\xe9\x57\xba\xfd\x9e",
  10072. .assoc = "\x44\xa6\x2c\x05\xe9\xe1\x43\xb1"
  10073. "\x58\x7c\xf2\x5c\x6d\x39\x0a\x64"
  10074. "\xa4\xf0\x13\x05\xd1\x77\x99\x67"
  10075. "\x11\xc4\xc6\xdb\x00\x56\x36\x61",
  10076. .alen = 32,
  10077. .input = "\xfb\xe5\x5d\x34\xbe\xe5\xe8\xe7"
  10078. "\x5a\xef\x2f\xbf\x1f\x7f\xd4\xb2"
  10079. "\x66\xca\x61\x1e\x96\x7a\x61\xb3"
  10080. "\x1c\x16\x45\x52\xba\x04\x9c\x9f"
  10081. "\xb1\xd2\x40\xbc\x52\x7c\x6f\xb1",
  10082. .ilen = 40,
  10083. .result = "\x85\x34\x66\x42\xc8\x92\x0f\x36"
  10084. "\x58\xe0\x6b\x91\x3c\x98\x5c\xbb"
  10085. "\x0a\x85\xcc\x02\xad\x7a\x96\xe9"
  10086. "\x65\x43\xa4\xc3\x0f\xdc\x55\x81",
  10087. .rlen = 32,
  10088. }, {
  10089. .key = "\x58\x5d\xa0\x96\x65\x1a\x04\xd7"
  10090. "\x96\xe5\xc5\x68\xaa\x95\x35\xe0"
  10091. "\x29\xa0\xba\x9e\x48\x78\xd1\xba"
  10092. "\xd1\xfc\x57",
  10093. .klen = 27,
  10094. .iv = "\x9c\xfe\xb8\x9c\xad\x71\xaa\x1f",
  10095. .assoc = "\x86\x67\xa5\xa9\x14\x5f\x0d\xc6"
  10096. "\xff\x14\xc7\x44\xbf\x6c\x3a\xc3"
  10097. "\xff\xb6\x81\xbd\xe2\xd5\x06\xc7"
  10098. "\x3c\xa1\x52\x13\x03\x8a\x23\x3a",
  10099. .alen = 32,
  10100. .input = "\x3f\x66\xb0\x9d\xe5\x4b\x38\x00"
  10101. "\xc6\x0e\x6e\xe5\xd6\x98\xa6\x37"
  10102. "\x8c\x26\x33\xc6\xb2\xa2\x17\xfa"
  10103. "\x64\x19\xc0\x30\xd7\xfc\x14\x6b"
  10104. "\xe3\x33\xc2\x04\xb0\x37\xbe\x3f"
  10105. "\xa9\xb4\x2d\x68\x03\xa3\x44\xef",
  10106. .ilen = 48,
  10107. .result = "\x02\x87\x4d\x28\x80\x6e\xb2\xed"
  10108. "\x99\x2a\xa8\xca\x04\x25\x45\x90"
  10109. "\x1d\xdd\x5a\xd9\xe4\xdb\x9c\x9c"
  10110. "\x49\xe9\x01\xfe\xa7\x80\x6d\x6b",
  10111. .rlen = 32,
  10112. .novrfy = 1,
  10113. }, {
  10114. .key = "\xa4\x4b\x54\x29\x0a\xb8\x6d\x01"
  10115. "\x5b\x80\x2a\xcf\x25\xc4\xb7\x5c"
  10116. "\x20\x2c\xad\x30\xc2\x2b\x41\xfb"
  10117. "\x0e\x85\xbc\x33\xad\x0f\x2b\xff"
  10118. "\xee\x49\x83",
  10119. .klen = 35,
  10120. .iv = "\xe9\xa9\xff\xe9\x57\xba\xfd\x9e",
  10121. .alen = 0,
  10122. .input = "\x1f\xb8\x8f\xa3\xdd\x54\x00\xf2",
  10123. .ilen = 8,
  10124. .result = "\x00",
  10125. .rlen = 0,
  10126. }, {
  10127. .key = "\x39\xbb\xa7\xbe\x59\x97\x9e\x73"
  10128. "\xa2\xbc\x6b\x98\xd7\x75\x7f\xe3"
  10129. "\xa4\x48\x93\x39\x26\x71\x4a\xc6"
  10130. "\xae\x8f\x11\x4c\xc2\x9c\x4a\xbb"
  10131. "\x85\x34\x66",
  10132. .klen = 35,
  10133. .iv = "\x42\xc8\x92\x0f\x36\x58\xe0\x6b",
  10134. .alen = 0,
  10135. .input = "\x48\x01\x5e\x02\x24\x04\x66\x47"
  10136. "\xa1\xea\x6f\xaf\xe8\xfc\xfb\xdd"
  10137. "\xa5\xa9\x87\x8d\x84\xee\x2e\x77"
  10138. "\xbb\x86\xb9\xf5\x5c\x6c\xff\xf6"
  10139. "\x72\xc3\x8e\xf7\x70\xb1\xb2\x07"
  10140. "\xbc\xa8\xa3\xbd\x83\x7c\x1d\x2a",
  10141. .ilen = 48,
  10142. .result = "\xdc\x56\xf2\x71\xb0\xb1\xa0\x6c"
  10143. "\xf0\x97\x3a\xfb\x6d\xe7\x32\x99"
  10144. "\x3e\xaf\x70\x5e\xb2\x4d\xea\x39"
  10145. "\x89\xd4\x75\x7a\x63\xb1\xda\x93",
  10146. .rlen = 32,
  10147. .novrfy = 1,
  10148. }, {
  10149. .key = "\x58\x5d\xa0\x96\x65\x1a\x04\xd7"
  10150. "\x96\xe5\xc5\x68\xaa\x95\x35\xe0"
  10151. "\x29\xa0\xba\x9e\x48\x78\xd1\xba"
  10152. "\x0d\x1a\x53\x3b\xb5\xe3\xf8\x8b"
  10153. "\xcf\x76\x3f",
  10154. .klen = 35,
  10155. .iv = "\xd9\x95\x75\x8f\x44\x89\x40\x7b",
  10156. .assoc = "\x8f\x86\x6c\x4d\x1d\xc5\x39\x88"
  10157. "\xc8\xf3\x5c\x52\x10\x63\x6f\x2b"
  10158. "\x8a\x2a\xc5\x6f\x30\x23\x58\x7b"
  10159. "\xfb\x36\x03\x11\xb4\xd9\xf2\xfe",
  10160. .alen = 32,
  10161. .input = "\x48\x58\xd6\xf3\xad\x63\x58\xbf"
  10162. "\xae\xc7\x5e\xae\x83\x8f\x7b\xe4"
  10163. "\x78\x5c\x4c\x67\x71\x89\x94\xbf"
  10164. "\x47\xf1\x63\x7e\x1c\x59\xbd\xc5"
  10165. "\x7f\x44\x0a\x0c\x01\x18\x07\x92"
  10166. "\xe1\xd3\x51\xce\x32\x6d\x0c\x5b",
  10167. .ilen = 48,
  10168. .result = "\xc2\x54\xc8\xde\x78\x87\x77\x40"
  10169. "\x49\x71\xe4\xb7\xe7\xcb\x76\x61"
  10170. "\x0a\x41\xb9\xe9\xc0\x76\x54\xab"
  10171. "\x04\x49\x3b\x19\x93\x57\x25\x5d",
  10172. .rlen = 32,
  10173. },
  10174. };
  10175. /*
  10176. * ANSI X9.31 Continuous Pseudo-Random Number Generator (AES mode)
  10177. * test vectors, taken from Appendix B.2.9 and B.2.10:
  10178. * http://csrc.nist.gov/groups/STM/cavp/documents/rng/RNGVS.pdf
  10179. * Only AES-128 is supported at this time.
  10180. */
  10181. #define ANSI_CPRNG_AES_TEST_VECTORS 6
  10182. static struct cprng_testvec ansi_cprng_aes_tv_template[] = {
  10183. {
  10184. .key = "\xf3\xb1\x66\x6d\x13\x60\x72\x42"
  10185. "\xed\x06\x1c\xab\xb8\xd4\x62\x02",
  10186. .klen = 16,
  10187. .dt = "\xe6\xb3\xbe\x78\x2a\x23\xfa\x62"
  10188. "\xd7\x1d\x4a\xfb\xb0\xe9\x22\xf9",
  10189. .dtlen = 16,
  10190. .v = "\x80\x00\x00\x00\x00\x00\x00\x00"
  10191. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10192. .vlen = 16,
  10193. .result = "\x59\x53\x1e\xd1\x3b\xb0\xc0\x55"
  10194. "\x84\x79\x66\x85\xc1\x2f\x76\x41",
  10195. .rlen = 16,
  10196. .loops = 1,
  10197. }, {
  10198. .key = "\xf3\xb1\x66\x6d\x13\x60\x72\x42"
  10199. "\xed\x06\x1c\xab\xb8\xd4\x62\x02",
  10200. .klen = 16,
  10201. .dt = "\xe6\xb3\xbe\x78\x2a\x23\xfa\x62"
  10202. "\xd7\x1d\x4a\xfb\xb0\xe9\x22\xfa",
  10203. .dtlen = 16,
  10204. .v = "\xc0\x00\x00\x00\x00\x00\x00\x00"
  10205. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10206. .vlen = 16,
  10207. .result = "\x7c\x22\x2c\xf4\xca\x8f\xa2\x4c"
  10208. "\x1c\x9c\xb6\x41\xa9\xf3\x22\x0d",
  10209. .rlen = 16,
  10210. .loops = 1,
  10211. }, {
  10212. .key = "\xf3\xb1\x66\x6d\x13\x60\x72\x42"
  10213. "\xed\x06\x1c\xab\xb8\xd4\x62\x02",
  10214. .klen = 16,
  10215. .dt = "\xe6\xb3\xbe\x78\x2a\x23\xfa\x62"
  10216. "\xd7\x1d\x4a\xfb\xb0\xe9\x22\xfb",
  10217. .dtlen = 16,
  10218. .v = "\xe0\x00\x00\x00\x00\x00\x00\x00"
  10219. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10220. .vlen = 16,
  10221. .result = "\x8a\xaa\x00\x39\x66\x67\x5b\xe5"
  10222. "\x29\x14\x28\x81\xa9\x4d\x4e\xc7",
  10223. .rlen = 16,
  10224. .loops = 1,
  10225. }, {
  10226. .key = "\xf3\xb1\x66\x6d\x13\x60\x72\x42"
  10227. "\xed\x06\x1c\xab\xb8\xd4\x62\x02",
  10228. .klen = 16,
  10229. .dt = "\xe6\xb3\xbe\x78\x2a\x23\xfa\x62"
  10230. "\xd7\x1d\x4a\xfb\xb0\xe9\x22\xfc",
  10231. .dtlen = 16,
  10232. .v = "\xf0\x00\x00\x00\x00\x00\x00\x00"
  10233. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10234. .vlen = 16,
  10235. .result = "\x88\xdd\xa4\x56\x30\x24\x23\xe5"
  10236. "\xf6\x9d\xa5\x7e\x7b\x95\xc7\x3a",
  10237. .rlen = 16,
  10238. .loops = 1,
  10239. }, {
  10240. .key = "\xf3\xb1\x66\x6d\x13\x60\x72\x42"
  10241. "\xed\x06\x1c\xab\xb8\xd4\x62\x02",
  10242. .klen = 16,
  10243. .dt = "\xe6\xb3\xbe\x78\x2a\x23\xfa\x62"
  10244. "\xd7\x1d\x4a\xfb\xb0\xe9\x22\xfd",
  10245. .dtlen = 16,
  10246. .v = "\xf8\x00\x00\x00\x00\x00\x00\x00"
  10247. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10248. .vlen = 16,
  10249. .result = "\x05\x25\x92\x46\x61\x79\xd2\xcb"
  10250. "\x78\xc4\x0b\x14\x0a\x5a\x9a\xc8",
  10251. .rlen = 16,
  10252. .loops = 1,
  10253. }, { /* Monte Carlo Test */
  10254. .key = "\x9f\x5b\x51\x20\x0b\xf3\x34\xb5"
  10255. "\xd8\x2b\xe8\xc3\x72\x55\xc8\x48",
  10256. .klen = 16,
  10257. .dt = "\x63\x76\xbb\xe5\x29\x02\xba\x3b"
  10258. "\x67\xc9\x25\xfa\x70\x1f\x11\xac",
  10259. .dtlen = 16,
  10260. .v = "\x57\x2c\x8e\x76\x87\x26\x47\x97"
  10261. "\x7e\x74\xfb\xdd\xc4\x95\x01\xd1",
  10262. .vlen = 16,
  10263. .result = "\x48\xe9\xbd\x0d\x06\xee\x18\xfb"
  10264. "\xe4\x57\x90\xd5\xc3\xfc\x9b\x73",
  10265. .rlen = 16,
  10266. .loops = 10000,
  10267. },
  10268. };
  10269. /* Cast5 test vectors from RFC 2144 */
  10270. #define CAST5_ENC_TEST_VECTORS 3
  10271. #define CAST5_DEC_TEST_VECTORS 3
  10272. static struct cipher_testvec cast5_enc_tv_template[] = {
  10273. {
  10274. .key = "\x01\x23\x45\x67\x12\x34\x56\x78"
  10275. "\x23\x45\x67\x89\x34\x56\x78\x9a",
  10276. .klen = 16,
  10277. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10278. .ilen = 8,
  10279. .result = "\x23\x8b\x4f\xe5\x84\x7e\x44\xb2",
  10280. .rlen = 8,
  10281. }, {
  10282. .key = "\x01\x23\x45\x67\x12\x34\x56\x78"
  10283. "\x23\x45",
  10284. .klen = 10,
  10285. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10286. .ilen = 8,
  10287. .result = "\xeb\x6a\x71\x1a\x2c\x02\x27\x1b",
  10288. .rlen = 8,
  10289. }, {
  10290. .key = "\x01\x23\x45\x67\x12",
  10291. .klen = 5,
  10292. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10293. .ilen = 8,
  10294. .result = "\x7a\xc8\x16\xd1\x6e\x9b\x30\x2e",
  10295. .rlen = 8,
  10296. },
  10297. };
  10298. static struct cipher_testvec cast5_dec_tv_template[] = {
  10299. {
  10300. .key = "\x01\x23\x45\x67\x12\x34\x56\x78"
  10301. "\x23\x45\x67\x89\x34\x56\x78\x9a",
  10302. .klen = 16,
  10303. .input = "\x23\x8b\x4f\xe5\x84\x7e\x44\xb2",
  10304. .ilen = 8,
  10305. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10306. .rlen = 8,
  10307. }, {
  10308. .key = "\x01\x23\x45\x67\x12\x34\x56\x78"
  10309. "\x23\x45",
  10310. .klen = 10,
  10311. .input = "\xeb\x6a\x71\x1a\x2c\x02\x27\x1b",
  10312. .ilen = 8,
  10313. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10314. .rlen = 8,
  10315. }, {
  10316. .key = "\x01\x23\x45\x67\x12",
  10317. .klen = 5,
  10318. .input = "\x7a\xc8\x16\xd1\x6e\x9b\x30\x2e",
  10319. .ilen = 8,
  10320. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10321. .rlen = 8,
  10322. },
  10323. };
  10324. /*
  10325. * ARC4 test vectors from OpenSSL
  10326. */
  10327. #define ARC4_ENC_TEST_VECTORS 7
  10328. #define ARC4_DEC_TEST_VECTORS 7
  10329. static struct cipher_testvec arc4_enc_tv_template[] = {
  10330. {
  10331. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10332. .klen = 8,
  10333. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10334. .ilen = 8,
  10335. .result = "\x75\xb7\x87\x80\x99\xe0\xc5\x96",
  10336. .rlen = 8,
  10337. }, {
  10338. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10339. .klen = 8,
  10340. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10341. .ilen = 8,
  10342. .result = "\x74\x94\xc2\xe7\x10\x4b\x08\x79",
  10343. .rlen = 8,
  10344. }, {
  10345. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10346. .klen = 8,
  10347. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10348. .ilen = 8,
  10349. .result = "\xde\x18\x89\x41\xa3\x37\x5d\x3a",
  10350. .rlen = 8,
  10351. }, {
  10352. .key = "\xef\x01\x23\x45",
  10353. .klen = 4,
  10354. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  10355. "\x00\x00\x00\x00\x00\x00\x00\x00"
  10356. "\x00\x00\x00\x00",
  10357. .ilen = 20,
  10358. .result = "\xd6\xa1\x41\xa7\xec\x3c\x38\xdf"
  10359. "\xbd\x61\x5a\x11\x62\xe1\xc7\xba"
  10360. "\x36\xb6\x78\x58",
  10361. .rlen = 20,
  10362. }, {
  10363. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10364. .klen = 8,
  10365. .input = "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10366. "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10367. "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10368. "\x12\x34\x56\x78",
  10369. .ilen = 28,
  10370. .result = "\x66\xa0\x94\x9f\x8a\xf7\xd6\x89"
  10371. "\x1f\x7f\x83\x2b\xa8\x33\xc0\x0c"
  10372. "\x89\x2e\xbe\x30\x14\x3c\xe2\x87"
  10373. "\x40\x01\x1e\xcf",
  10374. .rlen = 28,
  10375. }, {
  10376. .key = "\xef\x01\x23\x45",
  10377. .klen = 4,
  10378. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  10379. "\x00\x00",
  10380. .ilen = 10,
  10381. .result = "\xd6\xa1\x41\xa7\xec\x3c\x38\xdf"
  10382. "\xbd\x61",
  10383. .rlen = 10,
  10384. }, {
  10385. .key = "\x01\x23\x45\x67\x89\xAB\xCD\xEF"
  10386. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10387. .klen = 16,
  10388. .input = "\x01\x23\x45\x67\x89\xAB\xCD\xEF",
  10389. .ilen = 8,
  10390. .result = "\x69\x72\x36\x59\x1B\x52\x42\xB1",
  10391. .rlen = 8,
  10392. },
  10393. };
  10394. static struct cipher_testvec arc4_dec_tv_template[] = {
  10395. {
  10396. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10397. .klen = 8,
  10398. .input = "\x75\xb7\x87\x80\x99\xe0\xc5\x96",
  10399. .ilen = 8,
  10400. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10401. .rlen = 8,
  10402. }, {
  10403. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10404. .klen = 8,
  10405. .input = "\x74\x94\xc2\xe7\x10\x4b\x08\x79",
  10406. .ilen = 8,
  10407. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10408. .rlen = 8,
  10409. }, {
  10410. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10411. .klen = 8,
  10412. .input = "\xde\x18\x89\x41\xa3\x37\x5d\x3a",
  10413. .ilen = 8,
  10414. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10415. .rlen = 8,
  10416. }, {
  10417. .key = "\xef\x01\x23\x45",
  10418. .klen = 4,
  10419. .input = "\xd6\xa1\x41\xa7\xec\x3c\x38\xdf"
  10420. "\xbd\x61\x5a\x11\x62\xe1\xc7\xba"
  10421. "\x36\xb6\x78\x58",
  10422. .ilen = 20,
  10423. .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
  10424. "\x00\x00\x00\x00\x00\x00\x00\x00"
  10425. "\x00\x00\x00\x00",
  10426. .rlen = 20,
  10427. }, {
  10428. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef",
  10429. .klen = 8,
  10430. .input = "\x66\xa0\x94\x9f\x8a\xf7\xd6\x89"
  10431. "\x1f\x7f\x83\x2b\xa8\x33\xc0\x0c"
  10432. "\x89\x2e\xbe\x30\x14\x3c\xe2\x87"
  10433. "\x40\x01\x1e\xcf",
  10434. .ilen = 28,
  10435. .result = "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10436. "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10437. "\x12\x34\x56\x78\x9A\xBC\xDE\xF0"
  10438. "\x12\x34\x56\x78",
  10439. .rlen = 28,
  10440. }, {
  10441. .key = "\xef\x01\x23\x45",
  10442. .klen = 4,
  10443. .input = "\xd6\xa1\x41\xa7\xec\x3c\x38\xdf"
  10444. "\xbd\x61",
  10445. .ilen = 10,
  10446. .result = "\x00\x00\x00\x00\x00\x00\x00\x00"
  10447. "\x00\x00",
  10448. .rlen = 10,
  10449. }, {
  10450. .key = "\x01\x23\x45\x67\x89\xAB\xCD\xEF"
  10451. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10452. .klen = 16,
  10453. .input = "\x69\x72\x36\x59\x1B\x52\x42\xB1",
  10454. .ilen = 8,
  10455. .result = "\x01\x23\x45\x67\x89\xAB\xCD\xEF",
  10456. .rlen = 8,
  10457. },
  10458. };
  10459. /*
  10460. * TEA test vectors
  10461. */
  10462. #define TEA_ENC_TEST_VECTORS 4
  10463. #define TEA_DEC_TEST_VECTORS 4
  10464. static struct cipher_testvec tea_enc_tv_template[] = {
  10465. {
  10466. .key = zeroed_string,
  10467. .klen = 16,
  10468. .input = zeroed_string,
  10469. .ilen = 8,
  10470. .result = "\x0a\x3a\xea\x41\x40\xa9\xba\x94",
  10471. .rlen = 8,
  10472. }, {
  10473. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10474. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10475. .klen = 16,
  10476. .input = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10477. .ilen = 8,
  10478. .result = "\x77\x5d\x2a\x6a\xf6\xce\x92\x09",
  10479. .rlen = 8,
  10480. }, {
  10481. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10482. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10483. .klen = 16,
  10484. .input = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  10485. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  10486. .ilen = 16,
  10487. .result = "\xbe\x7a\xbb\x81\x95\x2d\x1f\x1e"
  10488. "\xdd\x89\xa1\x25\x04\x21\xdf\x95",
  10489. .rlen = 16,
  10490. }, {
  10491. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  10492. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  10493. .klen = 16,
  10494. .input = "\x54\x65\x61\x20\x69\x73\x20\x67"
  10495. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  10496. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  10497. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  10498. .ilen = 32,
  10499. .result = "\xe0\x4d\x5d\x3c\xb7\x8c\x36\x47"
  10500. "\x94\x18\x95\x91\xa9\xfc\x49\xf8"
  10501. "\x44\xd1\x2d\xc2\x99\xb8\x08\x2a"
  10502. "\x07\x89\x73\xc2\x45\x92\xc6\x90",
  10503. .rlen = 32,
  10504. }
  10505. };
  10506. static struct cipher_testvec tea_dec_tv_template[] = {
  10507. {
  10508. .key = zeroed_string,
  10509. .klen = 16,
  10510. .input = "\x0a\x3a\xea\x41\x40\xa9\xba\x94",
  10511. .ilen = 8,
  10512. .result = zeroed_string,
  10513. .rlen = 8,
  10514. }, {
  10515. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10516. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10517. .klen = 16,
  10518. .input = "\x77\x5d\x2a\x6a\xf6\xce\x92\x09",
  10519. .ilen = 8,
  10520. .result = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10521. .rlen = 8,
  10522. }, {
  10523. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10524. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10525. .klen = 16,
  10526. .input = "\xbe\x7a\xbb\x81\x95\x2d\x1f\x1e"
  10527. "\xdd\x89\xa1\x25\x04\x21\xdf\x95",
  10528. .ilen = 16,
  10529. .result = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  10530. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  10531. .rlen = 16,
  10532. }, {
  10533. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  10534. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  10535. .klen = 16,
  10536. .input = "\xe0\x4d\x5d\x3c\xb7\x8c\x36\x47"
  10537. "\x94\x18\x95\x91\xa9\xfc\x49\xf8"
  10538. "\x44\xd1\x2d\xc2\x99\xb8\x08\x2a"
  10539. "\x07\x89\x73\xc2\x45\x92\xc6\x90",
  10540. .ilen = 32,
  10541. .result = "\x54\x65\x61\x20\x69\x73\x20\x67"
  10542. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  10543. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  10544. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  10545. .rlen = 32,
  10546. }
  10547. };
  10548. /*
  10549. * XTEA test vectors
  10550. */
  10551. #define XTEA_ENC_TEST_VECTORS 4
  10552. #define XTEA_DEC_TEST_VECTORS 4
  10553. static struct cipher_testvec xtea_enc_tv_template[] = {
  10554. {
  10555. .key = zeroed_string,
  10556. .klen = 16,
  10557. .input = zeroed_string,
  10558. .ilen = 8,
  10559. .result = "\xd8\xd4\xe9\xde\xd9\x1e\x13\xf7",
  10560. .rlen = 8,
  10561. }, {
  10562. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10563. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10564. .klen = 16,
  10565. .input = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10566. .ilen = 8,
  10567. .result = "\x94\xeb\xc8\x96\x84\x6a\x49\xa8",
  10568. .rlen = 8,
  10569. }, {
  10570. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10571. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10572. .klen = 16,
  10573. .input = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  10574. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  10575. .ilen = 16,
  10576. .result = "\x3e\xce\xae\x22\x60\x56\xa8\x9d"
  10577. "\x77\x4d\xd4\xb4\x87\x24\xe3\x9a",
  10578. .rlen = 16,
  10579. }, {
  10580. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  10581. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  10582. .klen = 16,
  10583. .input = "\x54\x65\x61\x20\x69\x73\x20\x67"
  10584. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  10585. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  10586. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  10587. .ilen = 32,
  10588. .result = "\x99\x81\x9f\x5d\x6f\x4b\x31\x3a"
  10589. "\x86\xff\x6f\xd0\xe3\x87\x70\x07"
  10590. "\x4d\xb8\xcf\xf3\x99\x50\xb3\xd4"
  10591. "\x73\xa2\xfa\xc9\x16\x59\x5d\x81",
  10592. .rlen = 32,
  10593. }
  10594. };
  10595. static struct cipher_testvec xtea_dec_tv_template[] = {
  10596. {
  10597. .key = zeroed_string,
  10598. .klen = 16,
  10599. .input = "\xd8\xd4\xe9\xde\xd9\x1e\x13\xf7",
  10600. .ilen = 8,
  10601. .result = zeroed_string,
  10602. .rlen = 8,
  10603. }, {
  10604. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10605. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10606. .klen = 16,
  10607. .input = "\x94\xeb\xc8\x96\x84\x6a\x49\xa8",
  10608. .ilen = 8,
  10609. .result = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10610. .rlen = 8,
  10611. }, {
  10612. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10613. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10614. .klen = 16,
  10615. .input = "\x3e\xce\xae\x22\x60\x56\xa8\x9d"
  10616. "\x77\x4d\xd4\xb4\x87\x24\xe3\x9a",
  10617. .ilen = 16,
  10618. .result = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  10619. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  10620. .rlen = 16,
  10621. }, {
  10622. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  10623. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  10624. .klen = 16,
  10625. .input = "\x99\x81\x9f\x5d\x6f\x4b\x31\x3a"
  10626. "\x86\xff\x6f\xd0\xe3\x87\x70\x07"
  10627. "\x4d\xb8\xcf\xf3\x99\x50\xb3\xd4"
  10628. "\x73\xa2\xfa\xc9\x16\x59\x5d\x81",
  10629. .ilen = 32,
  10630. .result = "\x54\x65\x61\x20\x69\x73\x20\x67"
  10631. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  10632. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  10633. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  10634. .rlen = 32,
  10635. }
  10636. };
  10637. /*
  10638. * KHAZAD test vectors.
  10639. */
  10640. #define KHAZAD_ENC_TEST_VECTORS 5
  10641. #define KHAZAD_DEC_TEST_VECTORS 5
  10642. static struct cipher_testvec khazad_enc_tv_template[] = {
  10643. {
  10644. .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
  10645. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10646. .klen = 16,
  10647. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10648. .ilen = 8,
  10649. .result = "\x49\xa4\xce\x32\xac\x19\x0e\x3f",
  10650. .rlen = 8,
  10651. }, {
  10652. .key = "\x38\x38\x38\x38\x38\x38\x38\x38"
  10653. "\x38\x38\x38\x38\x38\x38\x38\x38",
  10654. .klen = 16,
  10655. .input = "\x38\x38\x38\x38\x38\x38\x38\x38",
  10656. .ilen = 8,
  10657. .result = "\x7e\x82\x12\xa1\xd9\x5b\xe4\xf9",
  10658. .rlen = 8,
  10659. }, {
  10660. .key = "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2"
  10661. "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2",
  10662. .klen = 16,
  10663. .input = "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2",
  10664. .ilen = 8,
  10665. .result = "\xaa\xbe\xc1\x95\xc5\x94\x1a\x9c",
  10666. .rlen = 8,
  10667. }, {
  10668. .key = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10669. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10670. .klen = 16,
  10671. .input = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10672. .ilen = 8,
  10673. .result = "\x04\x74\xf5\x70\x50\x16\xd3\xb8",
  10674. .rlen = 8,
  10675. }, {
  10676. .key = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10677. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10678. .klen = 16,
  10679. .input = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10680. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10681. .ilen = 16,
  10682. .result = "\x04\x74\xf5\x70\x50\x16\xd3\xb8"
  10683. "\x04\x74\xf5\x70\x50\x16\xd3\xb8",
  10684. .rlen = 16,
  10685. },
  10686. };
  10687. static struct cipher_testvec khazad_dec_tv_template[] = {
  10688. {
  10689. .key = "\x80\x00\x00\x00\x00\x00\x00\x00"
  10690. "\x00\x00\x00\x00\x00\x00\x00\x00",
  10691. .klen = 16,
  10692. .input = "\x49\xa4\xce\x32\xac\x19\x0e\x3f",
  10693. .ilen = 8,
  10694. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  10695. .rlen = 8,
  10696. }, {
  10697. .key = "\x38\x38\x38\x38\x38\x38\x38\x38"
  10698. "\x38\x38\x38\x38\x38\x38\x38\x38",
  10699. .klen = 16,
  10700. .input = "\x7e\x82\x12\xa1\xd9\x5b\xe4\xf9",
  10701. .ilen = 8,
  10702. .result = "\x38\x38\x38\x38\x38\x38\x38\x38",
  10703. .rlen = 8,
  10704. }, {
  10705. .key = "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2"
  10706. "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2",
  10707. .klen = 16,
  10708. .input = "\xaa\xbe\xc1\x95\xc5\x94\x1a\x9c",
  10709. .ilen = 8,
  10710. .result = "\xa2\xa2\xa2\xa2\xa2\xa2\xa2\xa2",
  10711. .rlen = 8,
  10712. }, {
  10713. .key = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10714. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10715. .klen = 16,
  10716. .input = "\x04\x74\xf5\x70\x50\x16\xd3\xb8",
  10717. .ilen = 8,
  10718. .result = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10719. .rlen = 8,
  10720. }, {
  10721. .key = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10722. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10723. .klen = 16,
  10724. .input = "\x04\x74\xf5\x70\x50\x16\xd3\xb8"
  10725. "\x04\x74\xf5\x70\x50\x16\xd3\xb8",
  10726. .ilen = 16,
  10727. .result = "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f"
  10728. "\x2f\x2f\x2f\x2f\x2f\x2f\x2f\x2f",
  10729. .rlen = 16,
  10730. },
  10731. };
  10732. /*
  10733. * Anubis test vectors.
  10734. */
  10735. #define ANUBIS_ENC_TEST_VECTORS 5
  10736. #define ANUBIS_DEC_TEST_VECTORS 5
  10737. #define ANUBIS_CBC_ENC_TEST_VECTORS 2
  10738. #define ANUBIS_CBC_DEC_TEST_VECTORS 2
  10739. static struct cipher_testvec anubis_enc_tv_template[] = {
  10740. {
  10741. .key = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10742. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10743. .klen = 16,
  10744. .input = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10745. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10746. .ilen = 16,
  10747. .result = "\x6d\xc5\xda\xa2\x26\x7d\x62\x6f"
  10748. "\x08\xb7\x52\x8e\x6e\x6e\x86\x90",
  10749. .rlen = 16,
  10750. }, {
  10751. .key = "\x03\x03\x03\x03\x03\x03\x03\x03"
  10752. "\x03\x03\x03\x03\x03\x03\x03\x03"
  10753. "\x03\x03\x03\x03",
  10754. .klen = 20,
  10755. .input = "\x03\x03\x03\x03\x03\x03\x03\x03"
  10756. "\x03\x03\x03\x03\x03\x03\x03\x03",
  10757. .ilen = 16,
  10758. .result = "\xdb\xf1\x42\xf4\xd1\x8a\xc7\x49"
  10759. "\x87\x41\x6f\x82\x0a\x98\x64\xae",
  10760. .rlen = 16,
  10761. }, {
  10762. .key = "\x24\x24\x24\x24\x24\x24\x24\x24"
  10763. "\x24\x24\x24\x24\x24\x24\x24\x24"
  10764. "\x24\x24\x24\x24\x24\x24\x24\x24"
  10765. "\x24\x24\x24\x24",
  10766. .klen = 28,
  10767. .input = "\x24\x24\x24\x24\x24\x24\x24\x24"
  10768. "\x24\x24\x24\x24\x24\x24\x24\x24",
  10769. .ilen = 16,
  10770. .result = "\xfd\x1b\x4a\xe3\xbf\xf0\xad\x3d"
  10771. "\x06\xd3\x61\x27\xfd\x13\x9e\xde",
  10772. .rlen = 16,
  10773. }, {
  10774. .key = "\x25\x25\x25\x25\x25\x25\x25\x25"
  10775. "\x25\x25\x25\x25\x25\x25\x25\x25"
  10776. "\x25\x25\x25\x25\x25\x25\x25\x25"
  10777. "\x25\x25\x25\x25\x25\x25\x25\x25",
  10778. .klen = 32,
  10779. .input = "\x25\x25\x25\x25\x25\x25\x25\x25"
  10780. "\x25\x25\x25\x25\x25\x25\x25\x25",
  10781. .ilen = 16,
  10782. .result = "\x1a\x91\xfb\x2b\xb7\x78\x6b\xc4"
  10783. "\x17\xd9\xff\x40\x3b\x0e\xe5\xfe",
  10784. .rlen = 16,
  10785. }, {
  10786. .key = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10787. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10788. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10789. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10790. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10791. .klen = 40,
  10792. .input = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10793. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10794. .ilen = 16,
  10795. .result = "\xa5\x2c\x85\x6f\x9c\xba\xa0\x97"
  10796. "\x9e\xc6\x84\x0f\x17\x21\x07\xee",
  10797. .rlen = 16,
  10798. },
  10799. };
  10800. static struct cipher_testvec anubis_dec_tv_template[] = {
  10801. {
  10802. .key = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10803. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10804. .klen = 16,
  10805. .input = "\x6d\xc5\xda\xa2\x26\x7d\x62\x6f"
  10806. "\x08\xb7\x52\x8e\x6e\x6e\x86\x90",
  10807. .ilen = 16,
  10808. .result = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10809. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10810. .rlen = 16,
  10811. }, {
  10812. .key = "\x03\x03\x03\x03\x03\x03\x03\x03"
  10813. "\x03\x03\x03\x03\x03\x03\x03\x03"
  10814. "\x03\x03\x03\x03",
  10815. .klen = 20,
  10816. .input = "\xdb\xf1\x42\xf4\xd1\x8a\xc7\x49"
  10817. "\x87\x41\x6f\x82\x0a\x98\x64\xae",
  10818. .ilen = 16,
  10819. .result = "\x03\x03\x03\x03\x03\x03\x03\x03"
  10820. "\x03\x03\x03\x03\x03\x03\x03\x03",
  10821. .rlen = 16,
  10822. }, {
  10823. .key = "\x24\x24\x24\x24\x24\x24\x24\x24"
  10824. "\x24\x24\x24\x24\x24\x24\x24\x24"
  10825. "\x24\x24\x24\x24\x24\x24\x24\x24"
  10826. "\x24\x24\x24\x24",
  10827. .klen = 28,
  10828. .input = "\xfd\x1b\x4a\xe3\xbf\xf0\xad\x3d"
  10829. "\x06\xd3\x61\x27\xfd\x13\x9e\xde",
  10830. .ilen = 16,
  10831. .result = "\x24\x24\x24\x24\x24\x24\x24\x24"
  10832. "\x24\x24\x24\x24\x24\x24\x24\x24",
  10833. .rlen = 16,
  10834. }, {
  10835. .key = "\x25\x25\x25\x25\x25\x25\x25\x25"
  10836. "\x25\x25\x25\x25\x25\x25\x25\x25"
  10837. "\x25\x25\x25\x25\x25\x25\x25\x25"
  10838. "\x25\x25\x25\x25\x25\x25\x25\x25",
  10839. .klen = 32,
  10840. .input = "\x1a\x91\xfb\x2b\xb7\x78\x6b\xc4"
  10841. "\x17\xd9\xff\x40\x3b\x0e\xe5\xfe",
  10842. .ilen = 16,
  10843. .result = "\x25\x25\x25\x25\x25\x25\x25\x25"
  10844. "\x25\x25\x25\x25\x25\x25\x25\x25",
  10845. .rlen = 16,
  10846. }, {
  10847. .key = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10848. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10849. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10850. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10851. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10852. .input = "\xa5\x2c\x85\x6f\x9c\xba\xa0\x97"
  10853. "\x9e\xc6\x84\x0f\x17\x21\x07\xee",
  10854. .klen = 40,
  10855. .ilen = 16,
  10856. .result = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10857. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10858. .rlen = 16,
  10859. },
  10860. };
  10861. static struct cipher_testvec anubis_cbc_enc_tv_template[] = {
  10862. {
  10863. .key = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10864. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10865. .klen = 16,
  10866. .input = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10867. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10868. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10869. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10870. .ilen = 32,
  10871. .result = "\x6d\xc5\xda\xa2\x26\x7d\x62\x6f"
  10872. "\x08\xb7\x52\x8e\x6e\x6e\x86\x90"
  10873. "\x86\xd8\xb5\x6f\x98\x5e\x8a\x66"
  10874. "\x4f\x1f\x78\xa1\xbb\x37\xf1\xbe",
  10875. .rlen = 32,
  10876. }, {
  10877. .key = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10878. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10879. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10880. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10881. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10882. .klen = 40,
  10883. .input = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10884. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10885. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10886. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10887. .ilen = 32,
  10888. .result = "\xa5\x2c\x85\x6f\x9c\xba\xa0\x97"
  10889. "\x9e\xc6\x84\x0f\x17\x21\x07\xee"
  10890. "\xa2\xbc\x06\x98\xc6\x4b\xda\x75"
  10891. "\x2e\xaa\xbe\x58\xce\x01\x5b\xc7",
  10892. .rlen = 32,
  10893. },
  10894. };
  10895. static struct cipher_testvec anubis_cbc_dec_tv_template[] = {
  10896. {
  10897. .key = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10898. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10899. .klen = 16,
  10900. .input = "\x6d\xc5\xda\xa2\x26\x7d\x62\x6f"
  10901. "\x08\xb7\x52\x8e\x6e\x6e\x86\x90"
  10902. "\x86\xd8\xb5\x6f\x98\x5e\x8a\x66"
  10903. "\x4f\x1f\x78\xa1\xbb\x37\xf1\xbe",
  10904. .ilen = 32,
  10905. .result = "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10906. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10907. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe"
  10908. "\xfe\xfe\xfe\xfe\xfe\xfe\xfe\xfe",
  10909. .rlen = 32,
  10910. }, {
  10911. .key = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10912. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10913. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10914. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10915. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10916. .klen = 40,
  10917. .input = "\xa5\x2c\x85\x6f\x9c\xba\xa0\x97"
  10918. "\x9e\xc6\x84\x0f\x17\x21\x07\xee"
  10919. "\xa2\xbc\x06\x98\xc6\x4b\xda\x75"
  10920. "\x2e\xaa\xbe\x58\xce\x01\x5b\xc7",
  10921. .ilen = 32,
  10922. .result = "\x35\x35\x35\x35\x35\x35\x35\x35"
  10923. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10924. "\x35\x35\x35\x35\x35\x35\x35\x35"
  10925. "\x35\x35\x35\x35\x35\x35\x35\x35",
  10926. .rlen = 32,
  10927. },
  10928. };
  10929. /*
  10930. * XETA test vectors
  10931. */
  10932. #define XETA_ENC_TEST_VECTORS 4
  10933. #define XETA_DEC_TEST_VECTORS 4
  10934. static struct cipher_testvec xeta_enc_tv_template[] = {
  10935. {
  10936. .key = zeroed_string,
  10937. .klen = 16,
  10938. .input = zeroed_string,
  10939. .ilen = 8,
  10940. .result = "\xaa\x22\x96\xe5\x6c\x61\xf3\x45",
  10941. .rlen = 8,
  10942. }, {
  10943. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10944. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10945. .klen = 16,
  10946. .input = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10947. .ilen = 8,
  10948. .result = "\x82\x3e\xeb\x35\xdc\xdd\xd9\xc3",
  10949. .rlen = 8,
  10950. }, {
  10951. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10952. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10953. .klen = 16,
  10954. .input = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  10955. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  10956. .ilen = 16,
  10957. .result = "\xe2\x04\xdb\xf2\x89\x85\x9e\xea"
  10958. "\x61\x35\xaa\xed\xb5\xcb\x71\x2c",
  10959. .rlen = 16,
  10960. }, {
  10961. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  10962. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  10963. .klen = 16,
  10964. .input = "\x54\x65\x61\x20\x69\x73\x20\x67"
  10965. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  10966. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  10967. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  10968. .ilen = 32,
  10969. .result = "\x0b\x03\xcd\x8a\xbe\x95\xfd\xb1"
  10970. "\xc1\x44\x91\x0b\xa5\xc9\x1b\xb4"
  10971. "\xa9\xda\x1e\x9e\xb1\x3e\x2a\x8f"
  10972. "\xea\xa5\x6a\x85\xd1\xf4\xa8\xa5",
  10973. .rlen = 32,
  10974. }
  10975. };
  10976. static struct cipher_testvec xeta_dec_tv_template[] = {
  10977. {
  10978. .key = zeroed_string,
  10979. .klen = 16,
  10980. .input = "\xaa\x22\x96\xe5\x6c\x61\xf3\x45",
  10981. .ilen = 8,
  10982. .result = zeroed_string,
  10983. .rlen = 8,
  10984. }, {
  10985. .key = "\x2b\x02\x05\x68\x06\x14\x49\x76"
  10986. "\x77\x5d\x0e\x26\x6c\x28\x78\x43",
  10987. .klen = 16,
  10988. .input = "\x82\x3e\xeb\x35\xdc\xdd\xd9\xc3",
  10989. .ilen = 8,
  10990. .result = "\x74\x65\x73\x74\x20\x6d\x65\x2e",
  10991. .rlen = 8,
  10992. }, {
  10993. .key = "\x09\x65\x43\x11\x66\x44\x39\x25"
  10994. "\x51\x3a\x16\x10\x0a\x08\x12\x6e",
  10995. .klen = 16,
  10996. .input = "\xe2\x04\xdb\xf2\x89\x85\x9e\xea"
  10997. "\x61\x35\xaa\xed\xb5\xcb\x71\x2c",
  10998. .ilen = 16,
  10999. .result = "\x6c\x6f\x6e\x67\x65\x72\x5f\x74"
  11000. "\x65\x73\x74\x5f\x76\x65\x63\x74",
  11001. .rlen = 16,
  11002. }, {
  11003. .key = "\x4d\x76\x32\x17\x05\x3f\x75\x2c"
  11004. "\x5d\x04\x16\x36\x15\x72\x63\x2f",
  11005. .klen = 16,
  11006. .input = "\x0b\x03\xcd\x8a\xbe\x95\xfd\xb1"
  11007. "\xc1\x44\x91\x0b\xa5\xc9\x1b\xb4"
  11008. "\xa9\xda\x1e\x9e\xb1\x3e\x2a\x8f"
  11009. "\xea\xa5\x6a\x85\xd1\xf4\xa8\xa5",
  11010. .ilen = 32,
  11011. .result = "\x54\x65\x61\x20\x69\x73\x20\x67"
  11012. "\x6f\x6f\x64\x20\x66\x6f\x72\x20"
  11013. "\x79\x6f\x75\x21\x21\x21\x20\x72"
  11014. "\x65\x61\x6c\x6c\x79\x21\x21\x21",
  11015. .rlen = 32,
  11016. }
  11017. };
  11018. /*
  11019. * FCrypt test vectors
  11020. */
  11021. #define FCRYPT_ENC_TEST_VECTORS ARRAY_SIZE(fcrypt_pcbc_enc_tv_template)
  11022. #define FCRYPT_DEC_TEST_VECTORS ARRAY_SIZE(fcrypt_pcbc_dec_tv_template)
  11023. static struct cipher_testvec fcrypt_pcbc_enc_tv_template[] = {
  11024. { /* http://www.openafs.org/pipermail/openafs-devel/2000-December/005320.html */
  11025. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11026. .klen = 8,
  11027. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11028. .input = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11029. .ilen = 8,
  11030. .result = "\x0E\x09\x00\xC7\x3E\xF7\xED\x41",
  11031. .rlen = 8,
  11032. }, {
  11033. .key = "\x11\x44\x77\xAA\xDD\x00\x33\x66",
  11034. .klen = 8,
  11035. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11036. .input = "\x12\x34\x56\x78\x9A\xBC\xDE\xF0",
  11037. .ilen = 8,
  11038. .result = "\xD8\xED\x78\x74\x77\xEC\x06\x80",
  11039. .rlen = 8,
  11040. }, { /* From Arla */
  11041. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11042. .klen = 8,
  11043. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11044. .input = "The quick brown fox jumps over the lazy dogs.\0\0",
  11045. .ilen = 48,
  11046. .result = "\x00\xf0\x0e\x11\x75\xe6\x23\x82"
  11047. "\xee\xac\x98\x62\x44\x51\xe4\x84"
  11048. "\xc3\x59\xd8\xaa\x64\x60\xae\xf7"
  11049. "\xd2\xd9\x13\x79\x72\xa3\x45\x03"
  11050. "\x23\xb5\x62\xd7\x0c\xf5\x27\xd1"
  11051. "\xf8\x91\x3c\xac\x44\x22\x92\xef",
  11052. .rlen = 48,
  11053. }, {
  11054. .key = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11055. .klen = 8,
  11056. .iv = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11057. .input = "The quick brown fox jumps over the lazy dogs.\0\0",
  11058. .ilen = 48,
  11059. .result = "\xca\x90\xf5\x9d\xcb\xd4\xd2\x3c"
  11060. "\x01\x88\x7f\x3e\x31\x6e\x62\x9d"
  11061. "\xd8\xe0\x57\xa3\x06\x3a\x42\x58"
  11062. "\x2a\x28\xfe\x72\x52\x2f\xdd\xe0"
  11063. "\x19\x89\x09\x1c\x2a\x8e\x8c\x94"
  11064. "\xfc\xc7\x68\xe4\x88\xaa\xde\x0f",
  11065. .rlen = 48,
  11066. }, { /* split-page version */
  11067. .key = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11068. .klen = 8,
  11069. .iv = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11070. .input = "The quick brown fox jumps over the lazy dogs.\0\0",
  11071. .ilen = 48,
  11072. .result = "\xca\x90\xf5\x9d\xcb\xd4\xd2\x3c"
  11073. "\x01\x88\x7f\x3e\x31\x6e\x62\x9d"
  11074. "\xd8\xe0\x57\xa3\x06\x3a\x42\x58"
  11075. "\x2a\x28\xfe\x72\x52\x2f\xdd\xe0"
  11076. "\x19\x89\x09\x1c\x2a\x8e\x8c\x94"
  11077. "\xfc\xc7\x68\xe4\x88\xaa\xde\x0f",
  11078. .rlen = 48,
  11079. .np = 2,
  11080. .tap = { 20, 28 },
  11081. }
  11082. };
  11083. static struct cipher_testvec fcrypt_pcbc_dec_tv_template[] = {
  11084. { /* http://www.openafs.org/pipermail/openafs-devel/2000-December/005320.html */
  11085. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11086. .klen = 8,
  11087. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11088. .input = "\x0E\x09\x00\xC7\x3E\xF7\xED\x41",
  11089. .ilen = 8,
  11090. .result = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11091. .rlen = 8,
  11092. }, {
  11093. .key = "\x11\x44\x77\xAA\xDD\x00\x33\x66",
  11094. .klen = 8,
  11095. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11096. .input = "\xD8\xED\x78\x74\x77\xEC\x06\x80",
  11097. .ilen = 8,
  11098. .result = "\x12\x34\x56\x78\x9A\xBC\xDE\xF0",
  11099. .rlen = 8,
  11100. }, { /* From Arla */
  11101. .key = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11102. .klen = 8,
  11103. .iv = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11104. .input = "\x00\xf0\x0e\x11\x75\xe6\x23\x82"
  11105. "\xee\xac\x98\x62\x44\x51\xe4\x84"
  11106. "\xc3\x59\xd8\xaa\x64\x60\xae\xf7"
  11107. "\xd2\xd9\x13\x79\x72\xa3\x45\x03"
  11108. "\x23\xb5\x62\xd7\x0c\xf5\x27\xd1"
  11109. "\xf8\x91\x3c\xac\x44\x22\x92\xef",
  11110. .ilen = 48,
  11111. .result = "The quick brown fox jumps over the lazy dogs.\0\0",
  11112. .rlen = 48,
  11113. }, {
  11114. .key = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11115. .klen = 8,
  11116. .iv = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11117. .input = "\xca\x90\xf5\x9d\xcb\xd4\xd2\x3c"
  11118. "\x01\x88\x7f\x3e\x31\x6e\x62\x9d"
  11119. "\xd8\xe0\x57\xa3\x06\x3a\x42\x58"
  11120. "\x2a\x28\xfe\x72\x52\x2f\xdd\xe0"
  11121. "\x19\x89\x09\x1c\x2a\x8e\x8c\x94"
  11122. "\xfc\xc7\x68\xe4\x88\xaa\xde\x0f",
  11123. .ilen = 48,
  11124. .result = "The quick brown fox jumps over the lazy dogs.\0\0",
  11125. .rlen = 48,
  11126. }, { /* split-page version */
  11127. .key = "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11128. .klen = 8,
  11129. .iv = "\xf0\xe1\xd2\xc3\xb4\xa5\x96\x87",
  11130. .input = "\xca\x90\xf5\x9d\xcb\xd4\xd2\x3c"
  11131. "\x01\x88\x7f\x3e\x31\x6e\x62\x9d"
  11132. "\xd8\xe0\x57\xa3\x06\x3a\x42\x58"
  11133. "\x2a\x28\xfe\x72\x52\x2f\xdd\xe0"
  11134. "\x19\x89\x09\x1c\x2a\x8e\x8c\x94"
  11135. "\xfc\xc7\x68\xe4\x88\xaa\xde\x0f",
  11136. .ilen = 48,
  11137. .result = "The quick brown fox jumps over the lazy dogs.\0\0",
  11138. .rlen = 48,
  11139. .np = 2,
  11140. .tap = { 20, 28 },
  11141. }
  11142. };
  11143. /*
  11144. * CAMELLIA test vectors.
  11145. */
  11146. #define CAMELLIA_ENC_TEST_VECTORS 3
  11147. #define CAMELLIA_DEC_TEST_VECTORS 3
  11148. #define CAMELLIA_CBC_ENC_TEST_VECTORS 2
  11149. #define CAMELLIA_CBC_DEC_TEST_VECTORS 2
  11150. static struct cipher_testvec camellia_enc_tv_template[] = {
  11151. {
  11152. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11153. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11154. .klen = 16,
  11155. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11156. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11157. .ilen = 16,
  11158. .result = "\x67\x67\x31\x38\x54\x96\x69\x73"
  11159. "\x08\x57\x06\x56\x48\xea\xbe\x43",
  11160. .rlen = 16,
  11161. }, {
  11162. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11163. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  11164. "\x00\x11\x22\x33\x44\x55\x66\x77",
  11165. .klen = 24,
  11166. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11167. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11168. .ilen = 16,
  11169. .result = "\xb4\x99\x34\x01\xb3\xe9\x96\xf8"
  11170. "\x4e\xe5\xce\xe7\xd7\x9b\x09\xb9",
  11171. .rlen = 16,
  11172. }, {
  11173. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11174. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  11175. "\x00\x11\x22\x33\x44\x55\x66\x77"
  11176. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  11177. .klen = 32,
  11178. .input = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11179. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11180. .ilen = 16,
  11181. .result = "\x9a\xcc\x23\x7d\xff\x16\xd7\x6c"
  11182. "\x20\xef\x7c\x91\x9e\x3a\x75\x09",
  11183. .rlen = 16,
  11184. },
  11185. };
  11186. static struct cipher_testvec camellia_dec_tv_template[] = {
  11187. {
  11188. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11189. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11190. .klen = 16,
  11191. .input = "\x67\x67\x31\x38\x54\x96\x69\x73"
  11192. "\x08\x57\x06\x56\x48\xea\xbe\x43",
  11193. .ilen = 16,
  11194. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11195. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11196. .rlen = 16,
  11197. }, {
  11198. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11199. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  11200. "\x00\x11\x22\x33\x44\x55\x66\x77",
  11201. .klen = 24,
  11202. .input = "\xb4\x99\x34\x01\xb3\xe9\x96\xf8"
  11203. "\x4e\xe5\xce\xe7\xd7\x9b\x09\xb9",
  11204. .ilen = 16,
  11205. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11206. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11207. .rlen = 16,
  11208. }, {
  11209. .key = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11210. "\xfe\xdc\xba\x98\x76\x54\x32\x10"
  11211. "\x00\x11\x22\x33\x44\x55\x66\x77"
  11212. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff",
  11213. .klen = 32,
  11214. .input = "\x9a\xcc\x23\x7d\xff\x16\xd7\x6c"
  11215. "\x20\xef\x7c\x91\x9e\x3a\x75\x09",
  11216. .ilen = 16,
  11217. .result = "\x01\x23\x45\x67\x89\xab\xcd\xef"
  11218. "\xfe\xdc\xba\x98\x76\x54\x32\x10",
  11219. .rlen = 16,
  11220. },
  11221. };
  11222. static struct cipher_testvec camellia_cbc_enc_tv_template[] = {
  11223. {
  11224. .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
  11225. "\x51\x2e\x03\xd5\x34\x12\x00\x06",
  11226. .klen = 16,
  11227. .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
  11228. "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
  11229. .input = "Single block msg",
  11230. .ilen = 16,
  11231. .result = "\xea\x32\x12\x76\x3b\x50\x10\xe7"
  11232. "\x18\xf6\xfd\x5d\xf6\x8f\x13\x51",
  11233. .rlen = 16,
  11234. }, {
  11235. .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
  11236. "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
  11237. .klen = 16,
  11238. .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
  11239. "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
  11240. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11241. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  11242. "\x10\x11\x12\x13\x14\x15\x16\x17"
  11243. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  11244. .ilen = 32,
  11245. .result = "\xa5\xdf\x6e\x50\xda\x70\x6c\x01"
  11246. "\x4a\xab\xf3\xf2\xd6\xfc\x6c\xfd"
  11247. "\x19\xb4\x3e\x57\x1c\x02\x5e\xa0"
  11248. "\x15\x78\xe0\x5e\xf2\xcb\x87\x16",
  11249. .rlen = 32,
  11250. },
  11251. };
  11252. static struct cipher_testvec camellia_cbc_dec_tv_template[] = {
  11253. {
  11254. .key = "\x06\xa9\x21\x40\x36\xb8\xa1\x5b"
  11255. "\x51\x2e\x03\xd5\x34\x12\x00\x06",
  11256. .klen = 16,
  11257. .iv = "\x3d\xaf\xba\x42\x9d\x9e\xb4\x30"
  11258. "\xb4\x22\xda\x80\x2c\x9f\xac\x41",
  11259. .input = "\xea\x32\x12\x76\x3b\x50\x10\xe7"
  11260. "\x18\xf6\xfd\x5d\xf6\x8f\x13\x51",
  11261. .ilen = 16,
  11262. .result = "Single block msg",
  11263. .rlen = 16,
  11264. }, {
  11265. .key = "\xc2\x86\x69\x6d\x88\x7c\x9a\xa0"
  11266. "\x61\x1b\xbb\x3e\x20\x25\xa4\x5a",
  11267. .klen = 16,
  11268. .iv = "\x56\x2e\x17\x99\x6d\x09\x3d\x28"
  11269. "\xdd\xb3\xba\x69\x5a\x2e\x6f\x58",
  11270. .input = "\xa5\xdf\x6e\x50\xda\x70\x6c\x01"
  11271. "\x4a\xab\xf3\xf2\xd6\xfc\x6c\xfd"
  11272. "\x19\xb4\x3e\x57\x1c\x02\x5e\xa0"
  11273. "\x15\x78\xe0\x5e\xf2\xcb\x87\x16",
  11274. .ilen = 32,
  11275. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11276. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  11277. "\x10\x11\x12\x13\x14\x15\x16\x17"
  11278. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  11279. .rlen = 32,
  11280. },
  11281. };
  11282. /*
  11283. * SEED test vectors
  11284. */
  11285. #define SEED_ENC_TEST_VECTORS 4
  11286. #define SEED_DEC_TEST_VECTORS 4
  11287. static struct cipher_testvec seed_enc_tv_template[] = {
  11288. {
  11289. .key = zeroed_string,
  11290. .klen = 16,
  11291. .input = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11292. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  11293. .ilen = 16,
  11294. .result = "\x5e\xba\xc6\xe0\x05\x4e\x16\x68"
  11295. "\x19\xaf\xf1\xcc\x6d\x34\x6c\xdb",
  11296. .rlen = 16,
  11297. }, {
  11298. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11299. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  11300. .klen = 16,
  11301. .input = zeroed_string,
  11302. .ilen = 16,
  11303. .result = "\xc1\x1f\x22\xf2\x01\x40\x50\x50"
  11304. "\x84\x48\x35\x97\xe4\x37\x0f\x43",
  11305. .rlen = 16,
  11306. }, {
  11307. .key = "\x47\x06\x48\x08\x51\xe6\x1b\xe8"
  11308. "\x5d\x74\xbf\xb3\xfd\x95\x61\x85",
  11309. .klen = 16,
  11310. .input = "\x83\xa2\xf8\xa2\x88\x64\x1f\xb9"
  11311. "\xa4\xe9\xa5\xcc\x2f\x13\x1c\x7d",
  11312. .ilen = 16,
  11313. .result = "\xee\x54\xd1\x3e\xbc\xae\x70\x6d"
  11314. "\x22\x6b\xc3\x14\x2c\xd4\x0d\x4a",
  11315. .rlen = 16,
  11316. }, {
  11317. .key = "\x28\xdb\xc3\xbc\x49\xff\xd8\x7d"
  11318. "\xcf\xa5\x09\xb1\x1d\x42\x2b\xe7",
  11319. .klen = 16,
  11320. .input = "\xb4\x1e\x6b\xe2\xeb\xa8\x4a\x14"
  11321. "\x8e\x2e\xed\x84\x59\x3c\x5e\xc7",
  11322. .ilen = 16,
  11323. .result = "\x9b\x9b\x7b\xfc\xd1\x81\x3c\xb9"
  11324. "\x5d\x0b\x36\x18\xf4\x0f\x51\x22",
  11325. .rlen = 16,
  11326. }
  11327. };
  11328. static struct cipher_testvec seed_dec_tv_template[] = {
  11329. {
  11330. .key = zeroed_string,
  11331. .klen = 16,
  11332. .input = "\x5e\xba\xc6\xe0\x05\x4e\x16\x68"
  11333. "\x19\xaf\xf1\xcc\x6d\x34\x6c\xdb",
  11334. .ilen = 16,
  11335. .result = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11336. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  11337. .rlen = 16,
  11338. }, {
  11339. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11340. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f",
  11341. .klen = 16,
  11342. .input = "\xc1\x1f\x22\xf2\x01\x40\x50\x50"
  11343. "\x84\x48\x35\x97\xe4\x37\x0f\x43",
  11344. .ilen = 16,
  11345. .result = zeroed_string,
  11346. .rlen = 16,
  11347. }, {
  11348. .key = "\x47\x06\x48\x08\x51\xe6\x1b\xe8"
  11349. "\x5d\x74\xbf\xb3\xfd\x95\x61\x85",
  11350. .klen = 16,
  11351. .input = "\xee\x54\xd1\x3e\xbc\xae\x70\x6d"
  11352. "\x22\x6b\xc3\x14\x2c\xd4\x0d\x4a",
  11353. .ilen = 16,
  11354. .result = "\x83\xa2\xf8\xa2\x88\x64\x1f\xb9"
  11355. "\xa4\xe9\xa5\xcc\x2f\x13\x1c\x7d",
  11356. .rlen = 16,
  11357. }, {
  11358. .key = "\x28\xdb\xc3\xbc\x49\xff\xd8\x7d"
  11359. "\xcf\xa5\x09\xb1\x1d\x42\x2b\xe7",
  11360. .klen = 16,
  11361. .input = "\x9b\x9b\x7b\xfc\xd1\x81\x3c\xb9"
  11362. "\x5d\x0b\x36\x18\xf4\x0f\x51\x22",
  11363. .ilen = 16,
  11364. .result = "\xb4\x1e\x6b\xe2\xeb\xa8\x4a\x14"
  11365. "\x8e\x2e\xed\x84\x59\x3c\x5e\xc7",
  11366. .rlen = 16,
  11367. }
  11368. };
  11369. #define SALSA20_STREAM_ENC_TEST_VECTORS 5
  11370. static struct cipher_testvec salsa20_stream_enc_tv_template[] = {
  11371. /*
  11372. * Testvectors from verified.test-vectors submitted to ECRYPT.
  11373. * They are truncated to size 39, 64, 111, 129 to test a variety
  11374. * of input length.
  11375. */
  11376. { /* Set 3, vector 0 */
  11377. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11378. "\x08\x09\x0A\x0B\x0C\x0D\x0E\x0F",
  11379. .klen = 16,
  11380. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11381. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11382. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11383. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11384. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11385. "\x00\x00\x00\x00\x00\x00\x00",
  11386. .ilen = 39,
  11387. .result = "\x2D\xD5\xC3\xF7\xBA\x2B\x20\xF7"
  11388. "\x68\x02\x41\x0C\x68\x86\x88\x89"
  11389. "\x5A\xD8\xC1\xBD\x4E\xA6\xC9\xB1"
  11390. "\x40\xFB\x9B\x90\xE2\x10\x49\xBF"
  11391. "\x58\x3F\x52\x79\x70\xEB\xC1",
  11392. .rlen = 39,
  11393. }, { /* Set 5, vector 0 */
  11394. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11395. "\x00\x00\x00\x00\x00\x00\x00\x00",
  11396. .klen = 16,
  11397. .iv = "\x80\x00\x00\x00\x00\x00\x00\x00",
  11398. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11399. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11400. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11401. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11402. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11403. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11404. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11405. "\x00\x00\x00\x00\x00\x00\x00\x00",
  11406. .ilen = 64,
  11407. .result = "\xB6\x6C\x1E\x44\x46\xDD\x95\x57"
  11408. "\xE5\x78\xE2\x23\xB0\xB7\x68\x01"
  11409. "\x7B\x23\xB2\x67\xBB\x02\x34\xAE"
  11410. "\x46\x26\xBF\x44\x3F\x21\x97\x76"
  11411. "\x43\x6F\xB1\x9F\xD0\xE8\x86\x6F"
  11412. "\xCD\x0D\xE9\xA9\x53\x8F\x4A\x09"
  11413. "\xCA\x9A\xC0\x73\x2E\x30\xBC\xF9"
  11414. "\x8E\x4F\x13\xE4\xB9\xE2\x01\xD9",
  11415. .rlen = 64,
  11416. }, { /* Set 3, vector 27 */
  11417. .key = "\x1B\x1C\x1D\x1E\x1F\x20\x21\x22"
  11418. "\x23\x24\x25\x26\x27\x28\x29\x2A"
  11419. "\x2B\x2C\x2D\x2E\x2F\x30\x31\x32"
  11420. "\x33\x34\x35\x36\x37\x38\x39\x3A",
  11421. .klen = 32,
  11422. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00",
  11423. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11424. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11425. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11426. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11427. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11428. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11429. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11430. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11431. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11432. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11433. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11434. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11435. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11436. "\x00\x00\x00\x00\x00\x00\x00",
  11437. .ilen = 111,
  11438. .result = "\xAE\x39\x50\x8E\xAC\x9A\xEC\xE7"
  11439. "\xBF\x97\xBB\x20\xB9\xDE\xE4\x1F"
  11440. "\x87\xD9\x47\xF8\x28\x91\x35\x98"
  11441. "\xDB\x72\xCC\x23\x29\x48\x56\x5E"
  11442. "\x83\x7E\x0B\xF3\x7D\x5D\x38\x7B"
  11443. "\x2D\x71\x02\xB4\x3B\xB5\xD8\x23"
  11444. "\xB0\x4A\xDF\x3C\xEC\xB6\xD9\x3B"
  11445. "\x9B\xA7\x52\xBE\xC5\xD4\x50\x59"
  11446. "\x15\x14\xB4\x0E\x40\xE6\x53\xD1"
  11447. "\x83\x9C\x5B\xA0\x92\x29\x6B\x5E"
  11448. "\x96\x5B\x1E\x2F\xD3\xAC\xC1\x92"
  11449. "\xB1\x41\x3F\x19\x2F\xC4\x3B\xC6"
  11450. "\x95\x46\x45\x54\xE9\x75\x03\x08"
  11451. "\x44\xAF\xE5\x8A\x81\x12\x09",
  11452. .rlen = 111,
  11453. }, { /* Set 5, vector 27 */
  11454. .key = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11455. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11456. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11457. "\x00\x00\x00\x00\x00\x00\x00\x00",
  11458. .klen = 32,
  11459. .iv = "\x00\x00\x00\x10\x00\x00\x00\x00",
  11460. .input = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11461. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11462. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11463. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11464. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11465. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11466. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11467. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11468. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11469. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11470. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11471. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11472. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11473. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11474. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11475. "\x00\x00\x00\x00\x00\x00\x00\x00"
  11476. "\x00",
  11477. .ilen = 129,
  11478. .result = "\xD2\xDB\x1A\x5C\xF1\xC1\xAC\xDB"
  11479. "\xE8\x1A\x7A\x43\x40\xEF\x53\x43"
  11480. "\x5E\x7F\x4B\x1A\x50\x52\x3F\x8D"
  11481. "\x28\x3D\xCF\x85\x1D\x69\x6E\x60"
  11482. "\xF2\xDE\x74\x56\x18\x1B\x84\x10"
  11483. "\xD4\x62\xBA\x60\x50\xF0\x61\xF2"
  11484. "\x1C\x78\x7F\xC1\x24\x34\xAF\x58"
  11485. "\xBF\x2C\x59\xCA\x90\x77\xF3\xB0"
  11486. "\x5B\x4A\xDF\x89\xCE\x2C\x2F\xFC"
  11487. "\x67\xF0\xE3\x45\xE8\xB3\xB3\x75"
  11488. "\xA0\x95\x71\xA1\x29\x39\x94\xCA"
  11489. "\x45\x2F\xBD\xCB\x10\xB6\xBE\x9F"
  11490. "\x8E\xF9\xB2\x01\x0A\x5A\x0A\xB7"
  11491. "\x6B\x9D\x70\x8E\x4B\xD6\x2F\xCD"
  11492. "\x2E\x40\x48\x75\xE9\xE2\x21\x45"
  11493. "\x0B\xC9\xB6\xB5\x66\xBC\x9A\x59"
  11494. "\x5A",
  11495. .rlen = 129,
  11496. }, { /* large test vector generated using Crypto++ */
  11497. .key = "\x00\x01\x02\x03\x04\x05\x06\x07"
  11498. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  11499. "\x10\x11\x12\x13\x14\x15\x16\x17"
  11500. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f",
  11501. .klen = 32,
  11502. .iv = "\x00\x00\x00\x00\x00\x00\x00\x00"
  11503. "\x00\x00\x00\x00\x00\x00\x00\x00",
  11504. .input =
  11505. "\x00\x01\x02\x03\x04\x05\x06\x07"
  11506. "\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f"
  11507. "\x10\x11\x12\x13\x14\x15\x16\x17"
  11508. "\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f"
  11509. "\x20\x21\x22\x23\x24\x25\x26\x27"
  11510. "\x28\x29\x2a\x2b\x2c\x2d\x2e\x2f"
  11511. "\x30\x31\x32\x33\x34\x35\x36\x37"
  11512. "\x38\x39\x3a\x3b\x3c\x3d\x3e\x3f"
  11513. "\x40\x41\x42\x43\x44\x45\x46\x47"
  11514. "\x48\x49\x4a\x4b\x4c\x4d\x4e\x4f"
  11515. "\x50\x51\x52\x53\x54\x55\x56\x57"
  11516. "\x58\x59\x5a\x5b\x5c\x5d\x5e\x5f"
  11517. "\x60\x61\x62\x63\x64\x65\x66\x67"
  11518. "\x68\x69\x6a\x6b\x6c\x6d\x6e\x6f"
  11519. "\x70\x71\x72\x73\x74\x75\x76\x77"
  11520. "\x78\x79\x7a\x7b\x7c\x7d\x7e\x7f"
  11521. "\x80\x81\x82\x83\x84\x85\x86\x87"
  11522. "\x88\x89\x8a\x8b\x8c\x8d\x8e\x8f"
  11523. "\x90\x91\x92\x93\x94\x95\x96\x97"
  11524. "\x98\x99\x9a\x9b\x9c\x9d\x9e\x9f"
  11525. "\xa0\xa1\xa2\xa3\xa4\xa5\xa6\xa7"
  11526. "\xa8\xa9\xaa\xab\xac\xad\xae\xaf"
  11527. "\xb0\xb1\xb2\xb3\xb4\xb5\xb6\xb7"
  11528. "\xb8\xb9\xba\xbb\xbc\xbd\xbe\xbf"
  11529. "\xc0\xc1\xc2\xc3\xc4\xc5\xc6\xc7"
  11530. "\xc8\xc9\xca\xcb\xcc\xcd\xce\xcf"
  11531. "\xd0\xd1\xd2\xd3\xd4\xd5\xd6\xd7"
  11532. "\xd8\xd9\xda\xdb\xdc\xdd\xde\xdf"
  11533. "\xe0\xe1\xe2\xe3\xe4\xe5\xe6\xe7"
  11534. "\xe8\xe9\xea\xeb\xec\xed\xee\xef"
  11535. "\xf0\xf1\xf2\xf3\xf4\xf5\xf6\xf7"
  11536. "\xf8\xf9\xfa\xfb\xfc\xfd\xfe\xff"
  11537. "\x00\x03\x06\x09\x0c\x0f\x12\x15"
  11538. "\x18\x1b\x1e\x21\x24\x27\x2a\x2d"
  11539. "\x30\x33\x36\x39\x3c\x3f\x42\x45"
  11540. "\x48\x4b\x4e\x51\x54\x57\x5a\x5d"
  11541. "\x60\x63\x66\x69\x6c\x6f\x72\x75"
  11542. "\x78\x7b\x7e\x81\x84\x87\x8a\x8d"
  11543. "\x90\x93\x96\x99\x9c\x9f\xa2\xa5"
  11544. "\xa8\xab\xae\xb1\xb4\xb7\xba\xbd"
  11545. "\xc0\xc3\xc6\xc9\xcc\xcf\xd2\xd5"
  11546. "\xd8\xdb\xde\xe1\xe4\xe7\xea\xed"
  11547. "\xf0\xf3\xf6\xf9\xfc\xff\x02\x05"
  11548. "\x08\x0b\x0e\x11\x14\x17\x1a\x1d"
  11549. "\x20\x23\x26\x29\x2c\x2f\x32\x35"
  11550. "\x38\x3b\x3e\x41\x44\x47\x4a\x4d"
  11551. "\x50\x53\x56\x59\x5c\x5f\x62\x65"
  11552. "\x68\x6b\x6e\x71\x74\x77\x7a\x7d"
  11553. "\x80\x83\x86\x89\x8c\x8f\x92\x95"
  11554. "\x98\x9b\x9e\xa1\xa4\xa7\xaa\xad"
  11555. "\xb0\xb3\xb6\xb9\xbc\xbf\xc2\xc5"
  11556. "\xc8\xcb\xce\xd1\xd4\xd7\xda\xdd"
  11557. "\xe0\xe3\xe6\xe9\xec\xef\xf2\xf5"
  11558. "\xf8\xfb\xfe\x01\x04\x07\x0a\x0d"
  11559. "\x10\x13\x16\x19\x1c\x1f\x22\x25"
  11560. "\x28\x2b\x2e\x31\x34\x37\x3a\x3d"
  11561. "\x40\x43\x46\x49\x4c\x4f\x52\x55"
  11562. "\x58\x5b\x5e\x61\x64\x67\x6a\x6d"
  11563. "\x70\x73\x76\x79\x7c\x7f\x82\x85"
  11564. "\x88\x8b\x8e\x91\x94\x97\x9a\x9d"
  11565. "\xa0\xa3\xa6\xa9\xac\xaf\xb2\xb5"
  11566. "\xb8\xbb\xbe\xc1\xc4\xc7\xca\xcd"
  11567. "\xd0\xd3\xd6\xd9\xdc\xdf\xe2\xe5"
  11568. "\xe8\xeb\xee\xf1\xf4\xf7\xfa\xfd"
  11569. "\x00\x05\x0a\x0f\x14\x19\x1e\x23"
  11570. "\x28\x2d\x32\x37\x3c\x41\x46\x4b"
  11571. "\x50\x55\x5a\x5f\x64\x69\x6e\x73"
  11572. "\x78\x7d\x82\x87\x8c\x91\x96\x9b"
  11573. "\xa0\xa5\xaa\xaf\xb4\xb9\xbe\xc3"
  11574. "\xc8\xcd\xd2\xd7\xdc\xe1\xe6\xeb"
  11575. "\xf0\xf5\xfa\xff\x04\x09\x0e\x13"
  11576. "\x18\x1d\x22\x27\x2c\x31\x36\x3b"
  11577. "\x40\x45\x4a\x4f\x54\x59\x5e\x63"
  11578. "\x68\x6d\x72\x77\x7c\x81\x86\x8b"
  11579. "\x90\x95\x9a\x9f\xa4\xa9\xae\xb3"
  11580. "\xb8\xbd\xc2\xc7\xcc\xd1\xd6\xdb"
  11581. "\xe0\xe5\xea\xef\xf4\xf9\xfe\x03"
  11582. "\x08\x0d\x12\x17\x1c\x21\x26\x2b"
  11583. "\x30\x35\x3a\x3f\x44\x49\x4e\x53"
  11584. "\x58\x5d\x62\x67\x6c\x71\x76\x7b"
  11585. "\x80\x85\x8a\x8f\x94\x99\x9e\xa3"
  11586. "\xa8\xad\xb2\xb7\xbc\xc1\xc6\xcb"
  11587. "\xd0\xd5\xda\xdf\xe4\xe9\xee\xf3"
  11588. "\xf8\xfd\x02\x07\x0c\x11\x16\x1b"
  11589. "\x20\x25\x2a\x2f\x34\x39\x3e\x43"
  11590. "\x48\x4d\x52\x57\x5c\x61\x66\x6b"
  11591. "\x70\x75\x7a\x7f\x84\x89\x8e\x93"
  11592. "\x98\x9d\xa2\xa7\xac\xb1\xb6\xbb"
  11593. "\xc0\xc5\xca\xcf\xd4\xd9\xde\xe3"
  11594. "\xe8\xed\xf2\xf7\xfc\x01\x06\x0b"
  11595. "\x10\x15\x1a\x1f\x24\x29\x2e\x33"
  11596. "\x38\x3d\x42\x47\x4c\x51\x56\x5b"
  11597. "\x60\x65\x6a\x6f\x74\x79\x7e\x83"
  11598. "\x88\x8d\x92\x97\x9c\xa1\xa6\xab"
  11599. "\xb0\xb5\xba\xbf\xc4\xc9\xce\xd3"
  11600. "\xd8\xdd\xe2\xe7\xec\xf1\xf6\xfb"
  11601. "\x00\x07\x0e\x15\x1c\x23\x2a\x31"
  11602. "\x38\x3f\x46\x4d\x54\x5b\x62\x69"
  11603. "\x70\x77\x7e\x85\x8c\x93\x9a\xa1"
  11604. "\xa8\xaf\xb6\xbd\xc4\xcb\xd2\xd9"
  11605. "\xe0\xe7\xee\xf5\xfc\x03\x0a\x11"
  11606. "\x18\x1f\x26\x2d\x34\x3b\x42\x49"
  11607. "\x50\x57\x5e\x65\x6c\x73\x7a\x81"
  11608. "\x88\x8f\x96\x9d\xa4\xab\xb2\xb9"
  11609. "\xc0\xc7\xce\xd5\xdc\xe3\xea\xf1"
  11610. "\xf8\xff\x06\x0d\x14\x1b\x22\x29"
  11611. "\x30\x37\x3e\x45\x4c\x53\x5a\x61"
  11612. "\x68\x6f\x76\x7d\x84\x8b\x92\x99"
  11613. "\xa0\xa7\xae\xb5\xbc\xc3\xca\xd1"
  11614. "\xd8\xdf\xe6\xed\xf4\xfb\x02\x09"
  11615. "\x10\x17\x1e\x25\x2c\x33\x3a\x41"
  11616. "\x48\x4f\x56\x5d\x64\x6b\x72\x79"
  11617. "\x80\x87\x8e\x95\x9c\xa3\xaa\xb1"
  11618. "\xb8\xbf\xc6\xcd\xd4\xdb\xe2\xe9"
  11619. "\xf0\xf7\xfe\x05\x0c\x13\x1a\x21"
  11620. "\x28\x2f\x36\x3d\x44\x4b\x52\x59"
  11621. "\x60\x67\x6e\x75\x7c\x83\x8a\x91"
  11622. "\x98\x9f\xa6\xad\xb4\xbb\xc2\xc9"
  11623. "\xd0\xd7\xde\xe5\xec\xf3\xfa\x01"
  11624. "\x08\x0f\x16\x1d\x24\x2b\x32\x39"
  11625. "\x40\x47\x4e\x55\x5c\x63\x6a\x71"
  11626. "\x78\x7f\x86\x8d\x94\x9b\xa2\xa9"
  11627. "\xb0\xb7\xbe\xc5\xcc\xd3\xda\xe1"
  11628. "\xe8\xef\xf6\xfd\x04\x0b\x12\x19"
  11629. "\x20\x27\x2e\x35\x3c\x43\x4a\x51"
  11630. "\x58\x5f\x66\x6d\x74\x7b\x82\x89"
  11631. "\x90\x97\x9e\xa5\xac\xb3\xba\xc1"
  11632. "\xc8\xcf\xd6\xdd\xe4\xeb\xf2\xf9"
  11633. "\x00\x09\x12\x1b\x24\x2d\x36\x3f"
  11634. "\x48\x51\x5a\x63\x6c\x75\x7e\x87"
  11635. "\x90\x99\xa2\xab\xb4\xbd\xc6\xcf"
  11636. "\xd8\xe1\xea\xf3\xfc\x05\x0e\x17"
  11637. "\x20\x29\x32\x3b\x44\x4d\x56\x5f"
  11638. "\x68\x71\x7a\x83\x8c\x95\x9e\xa7"
  11639. "\xb0\xb9\xc2\xcb\xd4\xdd\xe6\xef"
  11640. "\xf8\x01\x0a\x13\x1c\x25\x2e\x37"
  11641. "\x40\x49\x52\x5b\x64\x6d\x76\x7f"
  11642. "\x88\x91\x9a\xa3\xac\xb5\xbe\xc7"
  11643. "\xd0\xd9\xe2\xeb\xf4\xfd\x06\x0f"
  11644. "\x18\x21\x2a\x33\x3c\x45\x4e\x57"
  11645. "\x60\x69\x72\x7b\x84\x8d\x96\x9f"
  11646. "\xa8\xb1\xba\xc3\xcc\xd5\xde\xe7"
  11647. "\xf0\xf9\x02\x0b\x14\x1d\x26\x2f"
  11648. "\x38\x41\x4a\x53\x5c\x65\x6e\x77"
  11649. "\x80\x89\x92\x9b\xa4\xad\xb6\xbf"
  11650. "\xc8\xd1\xda\xe3\xec\xf5\xfe\x07"
  11651. "\x10\x19\x22\x2b\x34\x3d\x46\x4f"
  11652. "\x58\x61\x6a\x73\x7c\x85\x8e\x97"
  11653. "\xa0\xa9\xb2\xbb\xc4\xcd\xd6\xdf"
  11654. "\xe8\xf1\xfa\x03\x0c\x15\x1e\x27"
  11655. "\x30\x39\x42\x4b\x54\x5d\x66\x6f"
  11656. "\x78\x81\x8a\x93\x9c\xa5\xae\xb7"
  11657. "\xc0\xc9\xd2\xdb\xe4\xed\xf6\xff"
  11658. "\x08\x11\x1a\x23\x2c\x35\x3e\x47"
  11659. "\x50\x59\x62\x6b\x74\x7d\x86\x8f"
  11660. "\x98\xa1\xaa\xb3\xbc\xc5\xce\xd7"
  11661. "\xe0\xe9\xf2\xfb\x04\x0d\x16\x1f"
  11662. "\x28\x31\x3a\x43\x4c\x55\x5e\x67"
  11663. "\x70\x79\x82\x8b\x94\x9d\xa6\xaf"
  11664. "\xb8\xc1\xca\xd3\xdc\xe5\xee\xf7"
  11665. "\x00\x0b\x16\x21\x2c\x37\x42\x4d"
  11666. "\x58\x63\x6e\x79\x84\x8f\x9a\xa5"
  11667. "\xb0\xbb\xc6\xd1\xdc\xe7\xf2\xfd"
  11668. "\x08\x13\x1e\x29\x34\x3f\x4a\x55"
  11669. "\x60\x6b\x76\x81\x8c\x97\xa2\xad"
  11670. "\xb8\xc3\xce\xd9\xe4\xef\xfa\x05"
  11671. "\x10\x1b\x26\x31\x3c\x47\x52\x5d"
  11672. "\x68\x73\x7e\x89\x94\x9f\xaa\xb5"
  11673. "\xc0\xcb\xd6\xe1\xec\xf7\x02\x0d"
  11674. "\x18\x23\x2e\x39\x44\x4f\x5a\x65"
  11675. "\x70\x7b\x86\x91\x9c\xa7\xb2\xbd"
  11676. "\xc8\xd3\xde\xe9\xf4\xff\x0a\x15"
  11677. "\x20\x2b\x36\x41\x4c\x57\x62\x6d"
  11678. "\x78\x83\x8e\x99\xa4\xaf\xba\xc5"
  11679. "\xd0\xdb\xe6\xf1\xfc\x07\x12\x1d"
  11680. "\x28\x33\x3e\x49\x54\x5f\x6a\x75"
  11681. "\x80\x8b\x96\xa1\xac\xb7\xc2\xcd"
  11682. "\xd8\xe3\xee\xf9\x04\x0f\x1a\x25"
  11683. "\x30\x3b\x46\x51\x5c\x67\x72\x7d"
  11684. "\x88\x93\x9e\xa9\xb4\xbf\xca\xd5"
  11685. "\xe0\xeb\xf6\x01\x0c\x17\x22\x2d"
  11686. "\x38\x43\x4e\x59\x64\x6f\x7a\x85"
  11687. "\x90\x9b\xa6\xb1\xbc\xc7\xd2\xdd"
  11688. "\xe8\xf3\xfe\x09\x14\x1f\x2a\x35"
  11689. "\x40\x4b\x56\x61\x6c\x77\x82\x8d"
  11690. "\x98\xa3\xae\xb9\xc4\xcf\xda\xe5"
  11691. "\xf0\xfb\x06\x11\x1c\x27\x32\x3d"
  11692. "\x48\x53\x5e\x69\x74\x7f\x8a\x95"
  11693. "\xa0\xab\xb6\xc1\xcc\xd7\xe2\xed"
  11694. "\xf8\x03\x0e\x19\x24\x2f\x3a\x45"
  11695. "\x50\x5b\x66\x71\x7c\x87\x92\x9d"
  11696. "\xa8\xb3\xbe\xc9\xd4\xdf\xea\xf5"
  11697. "\x00\x0d\x1a\x27\x34\x41\x4e\x5b"
  11698. "\x68\x75\x82\x8f\x9c\xa9\xb6\xc3"
  11699. "\xd0\xdd\xea\xf7\x04\x11\x1e\x2b"
  11700. "\x38\x45\x52\x5f\x6c\x79\x86\x93"
  11701. "\xa0\xad\xba\xc7\xd4\xe1\xee\xfb"
  11702. "\x08\x15\x22\x2f\x3c\x49\x56\x63"
  11703. "\x70\x7d\x8a\x97\xa4\xb1\xbe\xcb"
  11704. "\xd8\xe5\xf2\xff\x0c\x19\x26\x33"
  11705. "\x40\x4d\x5a\x67\x74\x81\x8e\x9b"
  11706. "\xa8\xb5\xc2\xcf\xdc\xe9\xf6\x03"
  11707. "\x10\x1d\x2a\x37\x44\x51\x5e\x6b"
  11708. "\x78\x85\x92\x9f\xac\xb9\xc6\xd3"
  11709. "\xe0\xed\xfa\x07\x14\x21\x2e\x3b"
  11710. "\x48\x55\x62\x6f\x7c\x89\x96\xa3"
  11711. "\xb0\xbd\xca\xd7\xe4\xf1\xfe\x0b"
  11712. "\x18\x25\x32\x3f\x4c\x59\x66\x73"
  11713. "\x80\x8d\x9a\xa7\xb4\xc1\xce\xdb"
  11714. "\xe8\xf5\x02\x0f\x1c\x29\x36\x43"
  11715. "\x50\x5d\x6a\x77\x84\x91\x9e\xab"
  11716. "\xb8\xc5\xd2\xdf\xec\xf9\x06\x13"
  11717. "\x20\x2d\x3a\x47\x54\x61\x6e\x7b"
  11718. "\x88\x95\xa2\xaf\xbc\xc9\xd6\xe3"
  11719. "\xf0\xfd\x0a\x17\x24\x31\x3e\x4b"
  11720. "\x58\x65\x72\x7f\x8c\x99\xa6\xb3"
  11721. "\xc0\xcd\xda\xe7\xf4\x01\x0e\x1b"
  11722. "\x28\x35\x42\x4f\x5c\x69\x76\x83"
  11723. "\x90\x9d\xaa\xb7\xc4\xd1\xde\xeb"
  11724. "\xf8\x05\x12\x1f\x2c\x39\x46\x53"
  11725. "\x60\x6d\x7a\x87\x94\xa1\xae\xbb"
  11726. "\xc8\xd5\xe2\xef\xfc\x09\x16\x23"
  11727. "\x30\x3d\x4a\x57\x64\x71\x7e\x8b"
  11728. "\x98\xa5\xb2\xbf\xcc\xd9\xe6\xf3"
  11729. "\x00\x0f\x1e\x2d\x3c\x4b\x5a\x69"
  11730. "\x78\x87\x96\xa5\xb4\xc3\xd2\xe1"
  11731. "\xf0\xff\x0e\x1d\x2c\x3b\x4a\x59"
  11732. "\x68\x77\x86\x95\xa4\xb3\xc2\xd1"
  11733. "\xe0\xef\xfe\x0d\x1c\x2b\x3a\x49"
  11734. "\x58\x67\x76\x85\x94\xa3\xb2\xc1"
  11735. "\xd0\xdf\xee\xfd\x0c\x1b\x2a\x39"
  11736. "\x48\x57\x66\x75\x84\x93\xa2\xb1"
  11737. "\xc0\xcf\xde\xed\xfc\x0b\x1a\x29"
  11738. "\x38\x47\x56\x65\x74\x83\x92\xa1"
  11739. "\xb0\xbf\xce\xdd\xec\xfb\x0a\x19"
  11740. "\x28\x37\x46\x55\x64\x73\x82\x91"
  11741. "\xa0\xaf\xbe\xcd\xdc\xeb\xfa\x09"
  11742. "\x18\x27\x36\x45\x54\x63\x72\x81"
  11743. "\x90\x9f\xae\xbd\xcc\xdb\xea\xf9"
  11744. "\x08\x17\x26\x35\x44\x53\x62\x71"
  11745. "\x80\x8f\x9e\xad\xbc\xcb\xda\xe9"
  11746. "\xf8\x07\x16\x25\x34\x43\x52\x61"
  11747. "\x70\x7f\x8e\x9d\xac\xbb\xca\xd9"
  11748. "\xe8\xf7\x06\x15\x24\x33\x42\x51"
  11749. "\x60\x6f\x7e\x8d\x9c\xab\xba\xc9"
  11750. "\xd8\xe7\xf6\x05\x14\x23\x32\x41"
  11751. "\x50\x5f\x6e\x7d\x8c\x9b\xaa\xb9"
  11752. "\xc8\xd7\xe6\xf5\x04\x13\x22\x31"
  11753. "\x40\x4f\x5e\x6d\x7c\x8b\x9a\xa9"
  11754. "\xb8\xc7\xd6\xe5\xf4\x03\x12\x21"
  11755. "\x30\x3f\x4e\x5d\x6c\x7b\x8a\x99"
  11756. "\xa8\xb7\xc6\xd5\xe4\xf3\x02\x11"
  11757. "\x20\x2f\x3e\x4d\x5c\x6b\x7a\x89"
  11758. "\x98\xa7\xb6\xc5\xd4\xe3\xf2\x01"
  11759. "\x10\x1f\x2e\x3d\x4c\x5b\x6a\x79"
  11760. "\x88\x97\xa6\xb5\xc4\xd3\xe2\xf1"
  11761. "\x00\x11\x22\x33\x44\x55\x66\x77"
  11762. "\x88\x99\xaa\xbb\xcc\xdd\xee\xff"
  11763. "\x10\x21\x32\x43\x54\x65\x76\x87"
  11764. "\x98\xa9\xba\xcb\xdc\xed\xfe\x0f"
  11765. "\x20\x31\x42\x53\x64\x75\x86\x97"
  11766. "\xa8\xb9\xca\xdb\xec\xfd\x0e\x1f"
  11767. "\x30\x41\x52\x63\x74\x85\x96\xa7"
  11768. "\xb8\xc9\xda\xeb\xfc\x0d\x1e\x2f"
  11769. "\x40\x51\x62\x73\x84\x95\xa6\xb7"
  11770. "\xc8\xd9\xea\xfb\x0c\x1d\x2e\x3f"
  11771. "\x50\x61\x72\x83\x94\xa5\xb6\xc7"
  11772. "\xd8\xe9\xfa\x0b\x1c\x2d\x3e\x4f"
  11773. "\x60\x71\x82\x93\xa4\xb5\xc6\xd7"
  11774. "\xe8\xf9\x0a\x1b\x2c\x3d\x4e\x5f"
  11775. "\x70\x81\x92\xa3\xb4\xc5\xd6\xe7"
  11776. "\xf8\x09\x1a\x2b\x3c\x4d\x5e\x6f"
  11777. "\x80\x91\xa2\xb3\xc4\xd5\xe6\xf7"
  11778. "\x08\x19\x2a\x3b\x4c\x5d\x6e\x7f"
  11779. "\x90\xa1\xb2\xc3\xd4\xe5\xf6\x07"
  11780. "\x18\x29\x3a\x4b\x5c\x6d\x7e\x8f"
  11781. "\xa0\xb1\xc2\xd3\xe4\xf5\x06\x17"
  11782. "\x28\x39\x4a\x5b\x6c\x7d\x8e\x9f"
  11783. "\xb0\xc1\xd2\xe3\xf4\x05\x16\x27"
  11784. "\x38\x49\x5a\x6b\x7c\x8d\x9e\xaf"
  11785. "\xc0\xd1\xe2\xf3\x04\x15\x26\x37"
  11786. "\x48\x59\x6a\x7b\x8c\x9d\xae\xbf"
  11787. "\xd0\xe1\xf2\x03\x14\x25\x36\x47"
  11788. "\x58\x69\x7a\x8b\x9c\xad\xbe\xcf"
  11789. "\xe0\xf1\x02\x13\x24\x35\x46\x57"
  11790. "\x68\x79\x8a\x9b\xac\xbd\xce\xdf"
  11791. "\xf0\x01\x12\x23\x34\x45\x56\x67"
  11792. "\x78\x89\x9a\xab\xbc\xcd\xde\xef"
  11793. "\x00\x13\x26\x39\x4c\x5f\x72\x85"
  11794. "\x98\xab\xbe\xd1\xe4\xf7\x0a\x1d"
  11795. "\x30\x43\x56\x69\x7c\x8f\xa2\xb5"
  11796. "\xc8\xdb\xee\x01\x14\x27\x3a\x4d"
  11797. "\x60\x73\x86\x99\xac\xbf\xd2\xe5"
  11798. "\xf8\x0b\x1e\x31\x44\x57\x6a\x7d"
  11799. "\x90\xa3\xb6\xc9\xdc\xef\x02\x15"
  11800. "\x28\x3b\x4e\x61\x74\x87\x9a\xad"
  11801. "\xc0\xd3\xe6\xf9\x0c\x1f\x32\x45"
  11802. "\x58\x6b\x7e\x91\xa4\xb7\xca\xdd"
  11803. "\xf0\x03\x16\x29\x3c\x4f\x62\x75"
  11804. "\x88\x9b\xae\xc1\xd4\xe7\xfa\x0d"
  11805. "\x20\x33\x46\x59\x6c\x7f\x92\xa5"
  11806. "\xb8\xcb\xde\xf1\x04\x17\x2a\x3d"
  11807. "\x50\x63\x76\x89\x9c\xaf\xc2\xd5"
  11808. "\xe8\xfb\x0e\x21\x34\x47\x5a\x6d"
  11809. "\x80\x93\xa6\xb9\xcc\xdf\xf2\x05"
  11810. "\x18\x2b\x3e\x51\x64\x77\x8a\x9d"
  11811. "\xb0\xc3\xd6\xe9\xfc\x0f\x22\x35"
  11812. "\x48\x5b\x6e\x81\x94\xa7\xba\xcd"
  11813. "\xe0\xf3\x06\x19\x2c\x3f\x52\x65"
  11814. "\x78\x8b\x9e\xb1\xc4\xd7\xea\xfd"
  11815. "\x10\x23\x36\x49\x5c\x6f\x82\x95"
  11816. "\xa8\xbb\xce\xe1\xf4\x07\x1a\x2d"
  11817. "\x40\x53\x66\x79\x8c\x9f\xb2\xc5"
  11818. "\xd8\xeb\xfe\x11\x24\x37\x4a\x5d"
  11819. "\x70\x83\x96\xa9\xbc\xcf\xe2\xf5"
  11820. "\x08\x1b\x2e\x41\x54\x67\x7a\x8d"
  11821. "\xa0\xb3\xc6\xd9\xec\xff\x12\x25"
  11822. "\x38\x4b\x5e\x71\x84\x97\xaa\xbd"
  11823. "\xd0\xe3\xf6\x09\x1c\x2f\x42\x55"
  11824. "\x68\x7b\x8e\xa1\xb4\xc7\xda\xed"
  11825. "\x00\x15\x2a\x3f\x54\x69\x7e\x93"
  11826. "\xa8\xbd\xd2\xe7\xfc\x11\x26\x3b"
  11827. "\x50\x65\x7a\x8f\xa4\xb9\xce\xe3"
  11828. "\xf8\x0d\x22\x37\x4c\x61\x76\x8b"
  11829. "\xa0\xb5\xca\xdf\xf4\x09\x1e\x33"
  11830. "\x48\x5d\x72\x87\x9c\xb1\xc6\xdb"
  11831. "\xf0\x05\x1a\x2f\x44\x59\x6e\x83"
  11832. "\x98\xad\xc2\xd7\xec\x01\x16\x2b"
  11833. "\x40\x55\x6a\x7f\x94\xa9\xbe\xd3"
  11834. "\xe8\xfd\x12\x27\x3c\x51\x66\x7b"
  11835. "\x90\xa5\xba\xcf\xe4\xf9\x0e\x23"
  11836. "\x38\x4d\x62\x77\x8c\xa1\xb6\xcb"
  11837. "\xe0\xf5\x0a\x1f\x34\x49\x5e\x73"
  11838. "\x88\x9d\xb2\xc7\xdc\xf1\x06\x1b"
  11839. "\x30\x45\x5a\x6f\x84\x99\xae\xc3"
  11840. "\xd8\xed\x02\x17\x2c\x41\x56\x6b"
  11841. "\x80\x95\xaa\xbf\xd4\xe9\xfe\x13"
  11842. "\x28\x3d\x52\x67\x7c\x91\xa6\xbb"
  11843. "\xd0\xe5\xfa\x0f\x24\x39\x4e\x63"
  11844. "\x78\x8d\xa2\xb7\xcc\xe1\xf6\x0b"
  11845. "\x20\x35\x4a\x5f\x74\x89\x9e\xb3"
  11846. "\xc8\xdd\xf2\x07\x1c\x31\x46\x5b"
  11847. "\x70\x85\x9a\xaf\xc4\xd9\xee\x03"
  11848. "\x18\x2d\x42\x57\x6c\x81\x96\xab"
  11849. "\xc0\xd5\xea\xff\x14\x29\x3e\x53"
  11850. "\x68\x7d\x92\xa7\xbc\xd1\xe6\xfb"
  11851. "\x10\x25\x3a\x4f\x64\x79\x8e\xa3"
  11852. "\xb8\xcd\xe2\xf7\x0c\x21\x36\x4b"
  11853. "\x60\x75\x8a\x9f\xb4\xc9\xde\xf3"
  11854. "\x08\x1d\x32\x47\x5c\x71\x86\x9b"
  11855. "\xb0\xc5\xda\xef\x04\x19\x2e\x43"
  11856. "\x58\x6d\x82\x97\xac\xc1\xd6\xeb"
  11857. "\x00\x17\x2e\x45\x5c\x73\x8a\xa1"
  11858. "\xb8\xcf\xe6\xfd\x14\x2b\x42\x59"
  11859. "\x70\x87\x9e\xb5\xcc\xe3\xfa\x11"
  11860. "\x28\x3f\x56\x6d\x84\x9b\xb2\xc9"
  11861. "\xe0\xf7\x0e\x25\x3c\x53\x6a\x81"
  11862. "\x98\xaf\xc6\xdd\xf4\x0b\x22\x39"
  11863. "\x50\x67\x7e\x95\xac\xc3\xda\xf1"
  11864. "\x08\x1f\x36\x4d\x64\x7b\x92\xa9"
  11865. "\xc0\xd7\xee\x05\x1c\x33\x4a\x61"
  11866. "\x78\x8f\xa6\xbd\xd4\xeb\x02\x19"
  11867. "\x30\x47\x5e\x75\x8c\xa3\xba\xd1"
  11868. "\xe8\xff\x16\x2d\x44\x5b\x72\x89"
  11869. "\xa0\xb7\xce\xe5\xfc\x13\x2a\x41"
  11870. "\x58\x6f\x86\x9d\xb4\xcb\xe2\xf9"
  11871. "\x10\x27\x3e\x55\x6c\x83\x9a\xb1"
  11872. "\xc8\xdf\xf6\x0d\x24\x3b\x52\x69"
  11873. "\x80\x97\xae\xc5\xdc\xf3\x0a\x21"
  11874. "\x38\x4f\x66\x7d\x94\xab\xc2\xd9"
  11875. "\xf0\x07\x1e\x35\x4c\x63\x7a\x91"
  11876. "\xa8\xbf\xd6\xed\x04\x1b\x32\x49"
  11877. "\x60\x77\x8e\xa5\xbc\xd3\xea\x01"
  11878. "\x18\x2f\x46\x5d\x74\x8b\xa2\xb9"
  11879. "\xd0\xe7\xfe\x15\x2c\x43\x5a\x71"
  11880. "\x88\x9f\xb6\xcd\xe4\xfb\x12\x29"
  11881. "\x40\x57\x6e\x85\x9c\xb3\xca\xe1"
  11882. "\xf8\x0f\x26\x3d\x54\x6b\x82\x99"
  11883. "\xb0\xc7\xde\xf5\x0c\x23\x3a\x51"
  11884. "\x68\x7f\x96\xad\xc4\xdb\xf2\x09"
  11885. "\x20\x37\x4e\x65\x7c\x93\xaa\xc1"
  11886. "\xd8\xef\x06\x1d\x34\x4b\x62\x79"
  11887. "\x90\xa7\xbe\xd5\xec\x03\x1a\x31"
  11888. "\x48\x5f\x76\x8d\xa4\xbb\xd2\xe9"
  11889. "\x00\x19\x32\x4b\x64\x7d\x96\xaf"
  11890. "\xc8\xe1\xfa\x13\x2c\x45\x5e\x77"
  11891. "\x90\xa9\xc2\xdb\xf4\x0d\x26\x3f"
  11892. "\x58\x71\x8a\xa3\xbc\xd5\xee\x07"
  11893. "\x20\x39\x52\x6b\x84\x9d\xb6\xcf"
  11894. "\xe8\x01\x1a\x33\x4c\x65\x7e\x97"
  11895. "\xb0\xc9\xe2\xfb\x14\x2d\x46\x5f"
  11896. "\x78\x91\xaa\xc3\xdc\xf5\x0e\x27"
  11897. "\x40\x59\x72\x8b\xa4\xbd\xd6\xef"
  11898. "\x08\x21\x3a\x53\x6c\x85\x9e\xb7"
  11899. "\xd0\xe9\x02\x1b\x34\x4d\x66\x7f"
  11900. "\x98\xb1\xca\xe3\xfc\x15\x2e\x47"
  11901. "\x60\x79\x92\xab\xc4\xdd\xf6\x0f"
  11902. "\x28\x41\x5a\x73\x8c\xa5\xbe\xd7"
  11903. "\xf0\x09\x22\x3b\x54\x6d\x86\x9f"
  11904. "\xb8\xd1\xea\x03\x1c\x35\x4e\x67"
  11905. "\x80\x99\xb2\xcb\xe4\xfd\x16\x2f"
  11906. "\x48\x61\x7a\x93\xac\xc5\xde\xf7"
  11907. "\x10\x29\x42\x5b\x74\x8d\xa6\xbf"
  11908. "\xd8\xf1\x0a\x23\x3c\x55\x6e\x87"
  11909. "\xa0\xb9\xd2\xeb\x04\x1d\x36\x4f"
  11910. "\x68\x81\x9a\xb3\xcc\xe5\xfe\x17"
  11911. "\x30\x49\x62\x7b\x94\xad\xc6\xdf"
  11912. "\xf8\x11\x2a\x43\x5c\x75\x8e\xa7"
  11913. "\xc0\xd9\xf2\x0b\x24\x3d\x56\x6f"
  11914. "\x88\xa1\xba\xd3\xec\x05\x1e\x37"
  11915. "\x50\x69\x82\x9b\xb4\xcd\xe6\xff"
  11916. "\x18\x31\x4a\x63\x7c\x95\xae\xc7"
  11917. "\xe0\xf9\x12\x2b\x44\x5d\x76\x8f"
  11918. "\xa8\xc1\xda\xf3\x0c\x25\x3e\x57"
  11919. "\x70\x89\xa2\xbb\xd4\xed\x06\x1f"
  11920. "\x38\x51\x6a\x83\x9c\xb5\xce\xe7"
  11921. "\x00\x1b\x36\x51\x6c\x87\xa2\xbd"
  11922. "\xd8\xf3\x0e\x29\x44\x5f\x7a\x95"
  11923. "\xb0\xcb\xe6\x01\x1c\x37\x52\x6d"
  11924. "\x88\xa3\xbe\xd9\xf4\x0f\x2a\x45"
  11925. "\x60\x7b\x96\xb1\xcc\xe7\x02\x1d"
  11926. "\x38\x53\x6e\x89\xa4\xbf\xda\xf5"
  11927. "\x10\x2b\x46\x61\x7c\x97\xb2\xcd"
  11928. "\xe8\x03\x1e\x39\x54\x6f\x8a\xa5"
  11929. "\xc0\xdb\xf6\x11\x2c\x47\x62\x7d"
  11930. "\x98\xb3\xce\xe9\x04\x1f\x3a\x55"
  11931. "\x70\x8b\xa6\xc1\xdc\xf7\x12\x2d"
  11932. "\x48\x63\x7e\x99\xb4\xcf\xea\x05"
  11933. "\x20\x3b\x56\x71\x8c\xa7\xc2\xdd"
  11934. "\xf8\x13\x2e\x49\x64\x7f\x9a\xb5"
  11935. "\xd0\xeb\x06\x21\x3c\x57\x72\x8d"
  11936. "\xa8\xc3\xde\xf9\x14\x2f\x4a\x65"
  11937. "\x80\x9b\xb6\xd1\xec\x07\x22\x3d"
  11938. "\x58\x73\x8e\xa9\xc4\xdf\xfa\x15"
  11939. "\x30\x4b\x66\x81\x9c\xb7\xd2\xed"
  11940. "\x08\x23\x3e\x59\x74\x8f\xaa\xc5"
  11941. "\xe0\xfb\x16\x31\x4c\x67\x82\x9d"
  11942. "\xb8\xd3\xee\x09\x24\x3f\x5a\x75"
  11943. "\x90\xab\xc6\xe1\xfc\x17\x32\x4d"
  11944. "\x68\x83\x9e\xb9\xd4\xef\x0a\x25"
  11945. "\x40\x5b\x76\x91\xac\xc7\xe2\xfd"
  11946. "\x18\x33\x4e\x69\x84\x9f\xba\xd5"
  11947. "\xf0\x0b\x26\x41\x5c\x77\x92\xad"
  11948. "\xc8\xe3\xfe\x19\x34\x4f\x6a\x85"
  11949. "\xa0\xbb\xd6\xf1\x0c\x27\x42\x5d"
  11950. "\x78\x93\xae\xc9\xe4\xff\x1a\x35"
  11951. "\x50\x6b\x86\xa1\xbc\xd7\xf2\x0d"
  11952. "\x28\x43\x5e\x79\x94\xaf\xca\xe5"
  11953. "\x00\x1d\x3a\x57\x74\x91\xae\xcb"
  11954. "\xe8\x05\x22\x3f\x5c\x79\x96\xb3"
  11955. "\xd0\xed\x0a\x27\x44\x61\x7e\x9b"
  11956. "\xb8\xd5\xf2\x0f\x2c\x49\x66\x83"
  11957. "\xa0\xbd\xda\xf7\x14\x31\x4e\x6b"
  11958. "\x88\xa5\xc2\xdf\xfc\x19\x36\x53"
  11959. "\x70\x8d\xaa\xc7\xe4\x01\x1e\x3b"
  11960. "\x58\x75\x92\xaf\xcc\xe9\x06\x23"
  11961. "\x40\x5d\x7a\x97\xb4\xd1\xee\x0b"
  11962. "\x28\x45\x62\x7f\x9c\xb9\xd6\xf3"
  11963. "\x10\x2d\x4a\x67\x84\xa1\xbe\xdb"
  11964. "\xf8\x15\x32\x4f\x6c\x89\xa6\xc3"
  11965. "\xe0\xfd\x1a\x37\x54\x71\x8e\xab"
  11966. "\xc8\xe5\x02\x1f\x3c\x59\x76\x93"
  11967. "\xb0\xcd\xea\x07\x24\x41\x5e\x7b"
  11968. "\x98\xb5\xd2\xef\x0c\x29\x46\x63"
  11969. "\x80\x9d\xba\xd7\xf4\x11\x2e\x4b"
  11970. "\x68\x85\xa2\xbf\xdc\xf9\x16\x33"
  11971. "\x50\x6d\x8a\xa7\xc4\xe1\xfe\x1b"
  11972. "\x38\x55\x72\x8f\xac\xc9\xe6\x03"
  11973. "\x20\x3d\x5a\x77\x94\xb1\xce\xeb"
  11974. "\x08\x25\x42\x5f\x7c\x99\xb6\xd3"
  11975. "\xf0\x0d\x2a\x47\x64\x81\x9e\xbb"
  11976. "\xd8\xf5\x12\x2f\x4c\x69\x86\xa3"
  11977. "\xc0\xdd\xfa\x17\x34\x51\x6e\x8b"
  11978. "\xa8\xc5\xe2\xff\x1c\x39\x56\x73"
  11979. "\x90\xad\xca\xe7\x04\x21\x3e\x5b"
  11980. "\x78\x95\xb2\xcf\xec\x09\x26\x43"
  11981. "\x60\x7d\x9a\xb7\xd4\xf1\x0e\x2b"
  11982. "\x48\x65\x82\x9f\xbc\xd9\xf6\x13"
  11983. "\x30\x4d\x6a\x87\xa4\xc1\xde\xfb"
  11984. "\x18\x35\x52\x6f\x8c\xa9\xc6\xe3"
  11985. "\x00\x1f\x3e\x5d\x7c\x9b\xba\xd9"
  11986. "\xf8\x17\x36\x55\x74\x93\xb2\xd1"
  11987. "\xf0\x0f\x2e\x4d\x6c\x8b\xaa\xc9"
  11988. "\xe8\x07\x26\x45\x64\x83\xa2\xc1"
  11989. "\xe0\xff\x1e\x3d\x5c\x7b\x9a\xb9"
  11990. "\xd8\xf7\x16\x35\x54\x73\x92\xb1"
  11991. "\xd0\xef\x0e\x2d\x4c\x6b\x8a\xa9"
  11992. "\xc8\xe7\x06\x25\x44\x63\x82\xa1"
  11993. "\xc0\xdf\xfe\x1d\x3c\x5b\x7a\x99"
  11994. "\xb8\xd7\xf6\x15\x34\x53\x72\x91"
  11995. "\xb0\xcf\xee\x0d\x2c\x4b\x6a\x89"
  11996. "\xa8\xc7\xe6\x05\x24\x43\x62\x81"
  11997. "\xa0\xbf\xde\xfd\x1c\x3b\x5a\x79"
  11998. "\x98\xb7\xd6\xf5\x14\x33\x52\x71"
  11999. "\x90\xaf\xce\xed\x0c\x2b\x4a\x69"
  12000. "\x88\xa7\xc6\xe5\x04\x23\x42\x61"
  12001. "\x80\x9f\xbe\xdd\xfc\x1b\x3a\x59"
  12002. "\x78\x97\xb6\xd5\xf4\x13\x32\x51"
  12003. "\x70\x8f\xae\xcd\xec\x0b\x2a\x49"
  12004. "\x68\x87\xa6\xc5\xe4\x03\x22\x41"
  12005. "\x60\x7f\x9e\xbd\xdc\xfb\x1a\x39"
  12006. "\x58\x77\x96\xb5\xd4\xf3\x12\x31"
  12007. "\x50\x6f\x8e\xad\xcc\xeb\x0a\x29"
  12008. "\x48\x67\x86\xa5\xc4\xe3\x02\x21"
  12009. "\x40\x5f\x7e\x9d\xbc\xdb\xfa\x19"
  12010. "\x38\x57\x76\x95\xb4\xd3\xf2\x11"
  12011. "\x30\x4f\x6e\x8d\xac\xcb\xea\x09"
  12012. "\x28\x47\x66\x85\xa4\xc3\xe2\x01"
  12013. "\x20\x3f\x5e\x7d\x9c\xbb\xda\xf9"
  12014. "\x18\x37\x56\x75\x94\xb3\xd2\xf1"
  12015. "\x10\x2f\x4e\x6d\x8c\xab\xca\xe9"
  12016. "\x08\x27\x46\x65\x84\xa3\xc2\xe1"
  12017. "\x00\x21\x42\x63",
  12018. .ilen = 4100,
  12019. .result =
  12020. "\xb5\x81\xf5\x64\x18\x73\xe3\xf0"
  12021. "\x4c\x13\xf2\x77\x18\x60\x65\x5e"
  12022. "\x29\x01\xce\x98\x55\x53\xf9\x0c"
  12023. "\x2a\x08\xd5\x09\xb3\x57\x55\x56"
  12024. "\xc5\xe9\x56\x90\xcb\x6a\xa3\xc0"
  12025. "\xff\xc4\x79\xb4\xd2\x97\x5d\xc4"
  12026. "\x43\xd1\xfe\x94\x7b\x88\x06\x5a"
  12027. "\xb2\x9e\x2c\xfc\x44\x03\xb7\x90"
  12028. "\xa0\xc1\xba\x6a\x33\xb8\xc7\xb2"
  12029. "\x9d\xe1\x12\x4f\xc0\x64\xd4\x01"
  12030. "\xfe\x8c\x7a\x66\xf7\xe6\x5a\x91"
  12031. "\xbb\xde\x56\x86\xab\x65\x21\x30"
  12032. "\x00\x84\x65\x24\xa5\x7d\x85\xb4"
  12033. "\xe3\x17\xed\x3a\xb7\x6f\xb4\x0b"
  12034. "\x0b\xaf\x15\xae\x5a\x8f\xf2\x0c"
  12035. "\x2f\x27\xf4\x09\xd8\xd2\x96\xb7"
  12036. "\x71\xf2\xc5\x99\x4d\x7e\x7f\x75"
  12037. "\x77\x89\x30\x8b\x59\xdb\xa2\xb2"
  12038. "\xa0\xf3\x19\x39\x2b\xc5\x7e\x3f"
  12039. "\x4f\xd9\xd3\x56\x28\x97\x44\xdc"
  12040. "\xc0\x8b\x77\x24\xd9\x52\xe7\xc5"
  12041. "\xaf\xf6\x7d\x59\xb2\x44\x05\x1d"
  12042. "\xb1\xb0\x11\xa5\x0f\xec\x33\xe1"
  12043. "\x6d\x1b\x4e\x1f\xff\x57\x91\xb4"
  12044. "\x5b\x9a\x96\xc5\x53\xbc\xae\x20"
  12045. "\x3c\xbb\x14\xe2\xe8\x22\x33\xc1"
  12046. "\x5e\x76\x9e\x46\x99\xf6\x2a\x15"
  12047. "\xc6\x97\x02\xa0\x66\x43\xd1\xa6"
  12048. "\x31\xa6\x9f\xfb\xf4\xd3\x69\xe5"
  12049. "\xcd\x76\x95\xb8\x7a\x82\x7f\x21"
  12050. "\x45\xff\x3f\xce\x55\xf6\x95\x10"
  12051. "\x08\x77\x10\x43\xc6\xf3\x09\xe5"
  12052. "\x68\xe7\x3c\xad\x00\x52\x45\x0d"
  12053. "\xfe\x2d\xc6\xc2\x94\x8c\x12\x1d"
  12054. "\xe6\x25\xae\x98\x12\x8e\x19\x9c"
  12055. "\x81\x68\xb1\x11\xf6\x69\xda\xe3"
  12056. "\x62\x08\x18\x7a\x25\x49\x28\xac"
  12057. "\xba\x71\x12\x0b\xe4\xa2\xe5\xc7"
  12058. "\x5d\x8e\xec\x49\x40\x21\xbf\x5a"
  12059. "\x98\xf3\x02\x68\x55\x03\x7f\x8a"
  12060. "\xe5\x94\x0c\x32\x5c\x07\x82\x63"
  12061. "\xaf\x6f\x91\x40\x84\x8e\x52\x25"
  12062. "\xd0\xb0\x29\x53\x05\xe2\x50\x7a"
  12063. "\x34\xeb\xc9\x46\x20\xa8\x3d\xde"
  12064. "\x7f\x16\x5f\x36\xc5\x2e\xdc\xd1"
  12065. "\x15\x47\xc7\x50\x40\x6d\x91\xc5"
  12066. "\xe7\x93\x95\x1a\xd3\x57\xbc\x52"
  12067. "\x33\xee\x14\x19\x22\x52\x89\xa7"
  12068. "\x4a\x25\x56\x77\x4b\xca\xcf\x0a"
  12069. "\xe1\xf5\x35\x85\x30\x7e\x59\x4a"
  12070. "\xbd\x14\x5b\xdf\xe3\x46\xcb\xac"
  12071. "\x1f\x6c\x96\x0e\xf4\x81\xd1\x99"
  12072. "\xca\x88\x63\x3d\x02\x58\x6b\xa9"
  12073. "\xe5\x9f\xb3\x00\xb2\x54\xc6\x74"
  12074. "\x1c\xbf\x46\xab\x97\xcc\xf8\x54"
  12075. "\x04\x07\x08\x52\xe6\xc0\xda\x93"
  12076. "\x74\x7d\x93\x99\x5d\x78\x68\xa6"
  12077. "\x2e\x6b\xd3\x6a\x69\xcc\x12\x6b"
  12078. "\xd4\xc7\xa5\xc6\xe7\xf6\x03\x04"
  12079. "\x5d\xcd\x61\x5e\x17\x40\xdc\xd1"
  12080. "\x5c\xf5\x08\xdf\x5c\x90\x85\xa4"
  12081. "\xaf\xf6\x78\xbb\x0d\xf1\xf4\xa4"
  12082. "\x54\x26\x72\x9e\x61\xfa\x86\xcf"
  12083. "\xe8\x9e\xa1\xe0\xc7\x48\x23\xae"
  12084. "\x5a\x90\xae\x75\x0a\x74\x18\x89"
  12085. "\x05\xb1\x92\xb2\x7f\xd0\x1b\xa6"
  12086. "\x62\x07\x25\x01\xc7\xc2\x4f\xf9"
  12087. "\xe8\xfe\x63\x95\x80\x07\xb4\x26"
  12088. "\xcc\xd1\x26\xb6\xc4\x3f\x9e\xcb"
  12089. "\x8e\x3b\x2e\x44\x16\xd3\x10\x9a"
  12090. "\x95\x08\xeb\xc8\xcb\xeb\xbf\x6f"
  12091. "\x0b\xcd\x1f\xc8\xca\x86\xaa\xec"
  12092. "\x33\xe6\x69\xf4\x45\x25\x86\x3a"
  12093. "\x22\x94\x4f\x00\x23\x6a\x44\xc2"
  12094. "\x49\x97\x33\xab\x36\x14\x0a\x70"
  12095. "\x24\xc3\xbe\x04\x3b\x79\xa0\xf9"
  12096. "\xb8\xe7\x76\x29\x22\x83\xd7\xf2"
  12097. "\x94\xf4\x41\x49\xba\x5f\x7b\x07"
  12098. "\xb5\xfb\xdb\x03\x1a\x9f\xb6\x4c"
  12099. "\xc2\x2e\x37\x40\x49\xc3\x38\x16"
  12100. "\xe2\x4f\x77\x82\xb0\x68\x4c\x71"
  12101. "\x1d\x57\x61\x9c\xd9\x4e\x54\x99"
  12102. "\x47\x13\x28\x73\x3c\xbb\x00\x90"
  12103. "\xf3\x4d\xc9\x0e\xfd\xe7\xb1\x71"
  12104. "\xd3\x15\x79\xbf\xcc\x26\x2f\xbd"
  12105. "\xad\x6c\x50\x69\x6c\x3e\x6d\x80"
  12106. "\x9a\xea\x78\xaf\x19\xb2\x0d\x4d"
  12107. "\xad\x04\x07\xae\x22\x90\x4a\x93"
  12108. "\x32\x0e\x36\x9b\x1b\x46\xba\x3b"
  12109. "\xb4\xac\xc6\xd1\xa2\x31\x53\x3b"
  12110. "\x2a\x3d\x45\xfe\x03\x61\x10\x85"
  12111. "\x17\x69\xa6\x78\xcc\x6c\x87\x49"
  12112. "\x53\xf9\x80\x10\xde\x80\xa2\x41"
  12113. "\x6a\xc3\x32\x02\xad\x6d\x3c\x56"
  12114. "\x00\x71\x51\x06\xa7\xbd\xfb\xef"
  12115. "\x3c\xb5\x9f\xfc\x48\x7d\x53\x7c"
  12116. "\x66\xb0\x49\x23\xc4\x47\x10\x0e"
  12117. "\xe5\x6c\x74\x13\xe6\xc5\x3f\xaa"
  12118. "\xde\xff\x07\x44\xdd\x56\x1b\xad"
  12119. "\x09\x77\xfb\x5b\x12\xb8\x0d\x38"
  12120. "\x17\x37\x35\x7b\x9b\xbc\xfe\xd4"
  12121. "\x7e\x8b\xda\x7e\x5b\x04\xa7\x22"
  12122. "\xa7\x31\xa1\x20\x86\xc7\x1b\x99"
  12123. "\xdb\xd1\x89\xf4\x94\xa3\x53\x69"
  12124. "\x8d\xe7\xe8\x74\x11\x8d\x74\xd6"
  12125. "\x07\x37\x91\x9f\xfd\x67\x50\x3a"
  12126. "\xc9\xe1\xf4\x36\xd5\xa0\x47\xd1"
  12127. "\xf9\xe5\x39\xa3\x31\xac\x07\x36"
  12128. "\x23\xf8\x66\x18\x14\x28\x34\x0f"
  12129. "\xb8\xd0\xe7\x29\xb3\x04\x4b\x55"
  12130. "\x01\x41\xb2\x75\x8d\xcb\x96\x85"
  12131. "\x3a\xfb\xab\x2b\x9e\xfa\x58\x20"
  12132. "\x44\x1f\xc0\x14\x22\x75\x61\xe8"
  12133. "\xaa\x19\xcf\xf1\x82\x56\xf4\xd7"
  12134. "\x78\x7b\x3d\x5f\xb3\x9e\x0b\x8a"
  12135. "\x57\x50\xdb\x17\x41\x65\x4d\xa3"
  12136. "\x02\xc9\x9c\x9c\x53\xfb\x39\x39"
  12137. "\x9b\x1d\x72\x24\xda\xb7\x39\xbe"
  12138. "\x13\x3b\xfa\x29\xda\x9e\x54\x64"
  12139. "\x6e\xba\xd8\xa1\xcb\xb3\x36\xfa"
  12140. "\xcb\x47\x85\xe9\x61\x38\xbc\xbe"
  12141. "\xc5\x00\x38\x2a\x54\xf7\xc4\xb9"
  12142. "\xb3\xd3\x7b\xa0\xa0\xf8\x72\x7f"
  12143. "\x8c\x8e\x82\x0e\xc6\x1c\x75\x9d"
  12144. "\xca\x8e\x61\x87\xde\xad\x80\xd2"
  12145. "\xf5\xf9\x80\xef\x15\x75\xaf\xf5"
  12146. "\x80\xfb\xff\x6d\x1e\x25\xb7\x40"
  12147. "\x61\x6a\x39\x5a\x6a\xb5\x31\xab"
  12148. "\x97\x8a\x19\x89\x44\x40\xc0\xa6"
  12149. "\xb4\x4e\x30\x32\x7b\x13\xe7\x67"
  12150. "\xa9\x8b\x57\x04\xc2\x01\xa6\xf4"
  12151. "\x28\x99\xad\x2c\x76\xa3\x78\xc2"
  12152. "\x4a\xe6\xca\x5c\x50\x6a\xc1\xb0"
  12153. "\x62\x4b\x10\x8e\x7c\x17\x43\xb3"
  12154. "\x17\x66\x1c\x3e\x8d\x69\xf0\x5a"
  12155. "\x71\xf5\x97\xdc\xd1\x45\xdd\x28"
  12156. "\xf3\x5d\xdf\x53\x7b\x11\xe5\xbc"
  12157. "\x4c\xdb\x1b\x51\x6b\xe9\xfb\x3d"
  12158. "\xc1\xc3\x2c\xb9\x71\xf5\xb6\xb2"
  12159. "\x13\x36\x79\x80\x53\xe8\xd3\xa6"
  12160. "\x0a\xaf\xfd\x56\x97\xf7\x40\x8e"
  12161. "\x45\xce\xf8\xb0\x9e\x5c\x33\x82"
  12162. "\xb0\x44\x56\xfc\x05\x09\xe9\x2a"
  12163. "\xac\x26\x80\x14\x1d\xc8\x3a\x35"
  12164. "\x4c\x82\x97\xfd\x76\xb7\xa9\x0a"
  12165. "\x35\x58\x79\x8e\x0f\x66\xea\xaf"
  12166. "\x51\x6c\x09\xa9\x6e\x9b\xcb\x9a"
  12167. "\x31\x47\xa0\x2f\x7c\x71\xb4\x4a"
  12168. "\x11\xaa\x8c\x66\xc5\x64\xe6\x3a"
  12169. "\x54\xda\x24\x6a\xc4\x41\x65\x46"
  12170. "\x82\xa0\x0a\x0f\x5f\xfb\x25\xd0"
  12171. "\x2c\x91\xa7\xee\xc4\x81\x07\x86"
  12172. "\x75\x5e\x33\x69\x97\xe4\x2c\xa8"
  12173. "\x9d\x9f\x0b\x6a\xbe\xad\x98\xda"
  12174. "\x6d\x94\x41\xda\x2c\x1e\x89\xc4"
  12175. "\xc2\xaf\x1e\x00\x05\x0b\x83\x60"
  12176. "\xbd\x43\xea\x15\x23\x7f\xb9\xac"
  12177. "\xee\x4f\x2c\xaf\x2a\xf3\xdf\xd0"
  12178. "\xf3\x19\x31\xbb\x4a\x74\x84\x17"
  12179. "\x52\x32\x2c\x7d\x61\xe4\xcb\xeb"
  12180. "\x80\x38\x15\x52\xcb\x6f\xea\xe5"
  12181. "\x73\x9c\xd9\x24\x69\xc6\x95\x32"
  12182. "\x21\xc8\x11\xe4\xdc\x36\xd7\x93"
  12183. "\x38\x66\xfb\xb2\x7f\x3a\xb9\xaf"
  12184. "\x31\xdd\x93\x75\x78\x8a\x2c\x94"
  12185. "\x87\x1a\x58\xec\x9e\x7d\x4d\xba"
  12186. "\xe1\xe5\x4d\xfc\xbc\xa4\x2a\x14"
  12187. "\xef\xcc\xa7\xec\xab\x43\x09\x18"
  12188. "\xd3\xab\x68\xd1\x07\x99\x44\x47"
  12189. "\xd6\x83\x85\x3b\x30\xea\xa9\x6b"
  12190. "\x63\xea\xc4\x07\xfb\x43\x2f\xa4"
  12191. "\xaa\xb0\xab\x03\x89\xce\x3f\x8c"
  12192. "\x02\x7c\x86\x54\xbc\x88\xaf\x75"
  12193. "\xd2\xdc\x63\x17\xd3\x26\xf6\x96"
  12194. "\xa9\x3c\xf1\x61\x8c\x11\x18\xcc"
  12195. "\xd6\xea\x5b\xe2\xcd\xf0\xf1\xb2"
  12196. "\xe5\x35\x90\x1f\x85\x4c\x76\x5b"
  12197. "\x66\xce\x44\xa4\x32\x9f\xe6\x7b"
  12198. "\x71\x6e\x9f\x58\x15\x67\x72\x87"
  12199. "\x64\x8e\x3a\x44\x45\xd4\x76\xfa"
  12200. "\xc2\xf6\xef\x85\x05\x18\x7a\x9b"
  12201. "\xba\x41\x54\xac\xf0\xfc\x59\x12"
  12202. "\x3f\xdf\xa0\xe5\x8a\x65\xfd\x3a"
  12203. "\x62\x8d\x83\x2c\x03\xbe\x05\x76"
  12204. "\x2e\x53\x49\x97\x94\x33\xae\x40"
  12205. "\x81\x15\xdb\x6e\xad\xaa\xf5\x4b"
  12206. "\xe3\x98\x70\xdf\xe0\x7c\xcd\xdb"
  12207. "\x02\xd4\x7d\x2f\xc1\xe6\xb4\xf3"
  12208. "\xd7\x0d\x7a\xd9\x23\x9e\x87\x2d"
  12209. "\xce\x87\xad\xcc\x72\x05\x00\x29"
  12210. "\xdc\x73\x7f\x64\xc1\x15\x0e\xc2"
  12211. "\xdf\xa7\x5f\xeb\x41\xa1\xcd\xef"
  12212. "\x5c\x50\x79\x2a\x56\x56\x71\x8c"
  12213. "\xac\xc0\x79\x50\x69\xca\x59\x32"
  12214. "\x65\xf2\x54\xe4\x52\x38\x76\xd1"
  12215. "\x5e\xde\x26\x9e\xfb\x75\x2e\x11"
  12216. "\xb5\x10\xf4\x17\x73\xf5\x89\xc7"
  12217. "\x4f\x43\x5c\x8e\x7c\xb9\x05\x52"
  12218. "\x24\x40\x99\xfe\x9b\x85\x0b\x6c"
  12219. "\x22\x3e\x8b\xae\x86\xa1\xd2\x79"
  12220. "\x05\x68\x6b\xab\xe3\x41\x49\xed"
  12221. "\x15\xa1\x8d\x40\x2d\x61\xdf\x1a"
  12222. "\x59\xc9\x26\x8b\xef\x30\x4c\x88"
  12223. "\x4b\x10\xf8\x8d\xa6\x92\x9f\x4b"
  12224. "\xf3\xc4\x53\x0b\x89\x5d\x28\x92"
  12225. "\xcf\x78\xb2\xc0\x5d\xed\x7e\xfc"
  12226. "\xc0\x12\x23\x5f\x5a\x78\x86\x43"
  12227. "\x6e\x27\xf7\x5a\xa7\x6a\xed\x19"
  12228. "\x04\xf0\xb3\x12\xd1\xbd\x0e\x89"
  12229. "\x6e\xbc\x96\xa8\xd8\x49\x39\x9f"
  12230. "\x7e\x67\xf0\x2e\x3e\x01\xa9\xba"
  12231. "\xec\x8b\x62\x8e\xcb\x4a\x70\x43"
  12232. "\xc7\xc2\xc4\xca\x82\x03\x73\xe9"
  12233. "\x11\xdf\xcf\x54\xea\xc9\xb0\x95"
  12234. "\x51\xc0\x13\x3d\x92\x05\xfa\xf4"
  12235. "\xa9\x34\xc8\xce\x6c\x3d\x54\xcc"
  12236. "\xc4\xaf\xf1\xdc\x11\x44\x26\xa2"
  12237. "\xaf\xf1\x85\x75\x7d\x03\x61\x68"
  12238. "\x4e\x78\xc6\x92\x7d\x86\x7d\x77"
  12239. "\xdc\x71\x72\xdb\xc6\xae\xa1\xcb"
  12240. "\x70\x9a\x0b\x19\xbe\x4a\x6c\x2a"
  12241. "\xe2\xba\x6c\x64\x9a\x13\x28\xdf"
  12242. "\x85\x75\xe6\x43\xf6\x87\x08\x68"
  12243. "\x6e\xba\x6e\x79\x9f\x04\xbc\x23"
  12244. "\x50\xf6\x33\x5c\x1f\x24\x25\xbe"
  12245. "\x33\x47\x80\x45\x56\xa3\xa7\xd7"
  12246. "\x7a\xb1\x34\x0b\x90\x3c\x9c\xad"
  12247. "\x44\x5f\x9e\x0e\x9d\xd4\xbd\x93"
  12248. "\x5e\xfa\x3c\xe0\xb0\xd9\xed\xf3"
  12249. "\xd6\x2e\xff\x24\xd8\x71\x6c\xed"
  12250. "\xaf\x55\xeb\x22\xac\x93\x68\x32"
  12251. "\x05\x5b\x47\xdd\xc6\x4a\xcb\xc7"
  12252. "\x10\xe1\x3c\x92\x1a\xf3\x23\x78"
  12253. "\x2b\xa1\xd2\x80\xf4\x12\xb1\x20"
  12254. "\x8f\xff\x26\x35\xdd\xfb\xc7\x4e"
  12255. "\x78\xf1\x2d\x50\x12\x77\xa8\x60"
  12256. "\x7c\x0f\xf5\x16\x2f\x63\x70\x2a"
  12257. "\xc0\x96\x80\x4e\x0a\xb4\x93\x35"
  12258. "\x5d\x1d\x3f\x56\xf7\x2f\xbb\x90"
  12259. "\x11\x16\x8f\xa2\xec\x47\xbe\xac"
  12260. "\x56\x01\x26\x56\xb1\x8c\xb2\x10"
  12261. "\xf9\x1a\xca\xf5\xd1\xb7\x39\x20"
  12262. "\x63\xf1\x69\x20\x4f\x13\x12\x1f"
  12263. "\x5b\x65\xfc\x98\xf7\xc4\x7a\xbe"
  12264. "\xf7\x26\x4d\x2b\x84\x7b\x42\xad"
  12265. "\xd8\x7a\x0a\xb4\xd8\x74\xbf\xc1"
  12266. "\xf0\x6e\xb4\x29\xa3\xbb\xca\x46"
  12267. "\x67\x70\x6a\x2d\xce\x0e\xa2\x8a"
  12268. "\xa9\x87\xbf\x05\xc4\xc1\x04\xa3"
  12269. "\xab\xd4\x45\x43\x8c\xb6\x02\xb0"
  12270. "\x41\xc8\xfc\x44\x3d\x59\xaa\x2e"
  12271. "\x44\x21\x2a\x8d\x88\x9d\x57\xf4"
  12272. "\xa0\x02\x77\xb8\xa6\xa0\xe6\x75"
  12273. "\x5c\x82\x65\x3e\x03\x5c\x29\x8f"
  12274. "\x38\x55\xab\x33\x26\xef\x9f\x43"
  12275. "\x52\xfd\x68\xaf\x36\xb4\xbb\x9a"
  12276. "\x58\x09\x09\x1b\xc3\x65\x46\x46"
  12277. "\x1d\xa7\x94\x18\x23\x50\x2c\xca"
  12278. "\x2c\x55\x19\x97\x01\x9d\x93\x3b"
  12279. "\x63\x86\xf2\x03\x67\x45\xd2\x72"
  12280. "\x28\x52\x6c\xf4\xe3\x1c\xb5\x11"
  12281. "\x13\xf1\xeb\x21\xc7\xd9\x56\x82"
  12282. "\x2b\x82\x39\xbd\x69\x54\xed\x62"
  12283. "\xc3\xe2\xde\x73\xd4\x6a\x12\xae"
  12284. "\x13\x21\x7f\x4b\x5b\xfc\xbf\xe8"
  12285. "\x2b\xbe\x56\xba\x68\x8b\x9a\xb1"
  12286. "\x6e\xfa\xbf\x7e\x5a\x4b\xf1\xac"
  12287. "\x98\x65\x85\xd1\x93\x53\xd3\x7b"
  12288. "\x09\xdd\x4b\x10\x6d\x84\xb0\x13"
  12289. "\x65\xbd\xcf\x52\x09\xc4\x85\xe2"
  12290. "\x84\x74\x15\x65\xb7\xf7\x51\xaf"
  12291. "\x55\xad\xa4\xd1\x22\x54\x70\x94"
  12292. "\xa0\x1c\x90\x41\xfd\x99\xd7\x5a"
  12293. "\x31\xef\xaa\x25\xd0\x7f\x4f\xea"
  12294. "\x1d\x55\x42\xe5\x49\xb0\xd0\x46"
  12295. "\x62\x36\x43\xb2\x82\x15\x75\x50"
  12296. "\xa4\x72\xeb\x54\x27\x1f\x8a\xe4"
  12297. "\x7d\xe9\x66\xc5\xf1\x53\xa4\xd1"
  12298. "\x0c\xeb\xb8\xf8\xbc\xd4\xe2\xe7"
  12299. "\xe1\xf8\x4b\xcb\xa9\xa1\xaf\x15"
  12300. "\x83\xcb\x72\xd0\x33\x79\x00\x2d"
  12301. "\x9f\xd7\xf1\x2e\x1e\x10\xe4\x45"
  12302. "\xc0\x75\x3a\x39\xea\x68\xf7\x5d"
  12303. "\x1b\x73\x8f\xe9\x8e\x0f\x72\x47"
  12304. "\xae\x35\x0a\x31\x7a\x14\x4d\x4a"
  12305. "\x6f\x47\xf7\x7e\x91\x6e\x74\x8b"
  12306. "\x26\x47\xf9\xc3\xf9\xde\x70\xf5"
  12307. "\x61\xab\xa9\x27\x9f\x82\xe4\x9c"
  12308. "\x89\x91\x3f\x2e\x6a\xfd\xb5\x49"
  12309. "\xe9\xfd\x59\x14\x36\x49\x40\x6d"
  12310. "\x32\xd8\x85\x42\xf3\xa5\xdf\x0c"
  12311. "\xa8\x27\xd7\x54\xe2\x63\x2f\xf2"
  12312. "\x7e\x8b\x8b\xe7\xf1\x9a\x95\x35"
  12313. "\x43\xdc\x3a\xe4\xb6\xf4\xd0\xdf"
  12314. "\x9c\xcb\x94\xf3\x21\xa0\x77\x50"
  12315. "\xe2\xc6\xc4\xc6\x5f\x09\x64\x5b"
  12316. "\x92\x90\xd8\xe1\xd1\xed\x4b\x42"
  12317. "\xd7\x37\xaf\x65\x3d\x11\x39\xb6"
  12318. "\x24\x8a\x60\xae\xd6\x1e\xbf\x0e"
  12319. "\x0d\xd7\xdc\x96\x0e\x65\x75\x4e"
  12320. "\x29\x06\x9d\xa4\x51\x3a\x10\x63"
  12321. "\x8f\x17\x07\xd5\x8e\x3c\xf4\x28"
  12322. "\x00\x5a\x5b\x05\x19\xd8\xc0\x6c"
  12323. "\xe5\x15\xe4\x9c\x9d\x71\x9d\x5e"
  12324. "\x94\x29\x1a\xa7\x80\xfa\x0e\x33"
  12325. "\x03\xdd\xb7\x3e\x9a\xa9\x26\x18"
  12326. "\x37\xa9\x64\x08\x4d\x94\x5a\x88"
  12327. "\xca\x35\xce\x81\x02\xe3\x1f\x1b"
  12328. "\x89\x1a\x77\x85\xe3\x41\x6d\x32"
  12329. "\x42\x19\x23\x7d\xc8\x73\xee\x25"
  12330. "\x85\x0d\xf8\x31\x25\x79\x1b\x6f"
  12331. "\x79\x25\xd2\xd8\xd4\x23\xfd\xf7"
  12332. "\x82\x36\x6a\x0c\x46\x22\x15\xe9"
  12333. "\xff\x72\x41\x91\x91\x7d\x3a\xb7"
  12334. "\xdd\x65\x99\x70\xf6\x8d\x84\xf8"
  12335. "\x67\x15\x20\x11\xd6\xb2\x55\x7b"
  12336. "\xdb\x87\xee\xef\x55\x89\x2a\x59"
  12337. "\x2b\x07\x8f\x43\x8a\x59\x3c\x01"
  12338. "\x8b\x65\x54\xa1\x66\xd5\x38\xbd"
  12339. "\xc6\x30\xa9\xcc\x49\xb6\xa8\x1b"
  12340. "\xb8\xc0\x0e\xe3\x45\x28\xe2\xff"
  12341. "\x41\x9f\x7e\x7c\xd1\xae\x9e\x25"
  12342. "\x3f\x4c\x7c\x7c\xf4\xa8\x26\x4d"
  12343. "\x5c\xfd\x4b\x27\x18\xf9\x61\x76"
  12344. "\x48\xba\x0c\x6b\xa9\x4d\xfc\xf5"
  12345. "\x3b\x35\x7e\x2f\x4a\xa9\xc2\x9a"
  12346. "\xae\xab\x86\x09\x89\xc9\xc2\x40"
  12347. "\x39\x2c\x81\xb3\xb8\x17\x67\xc2"
  12348. "\x0d\x32\x4a\x3a\x67\x81\xd7\x1a"
  12349. "\x34\x52\xc5\xdb\x0a\xf5\x63\x39"
  12350. "\xea\x1f\xe1\x7c\xa1\x9e\xc1\x35"
  12351. "\xe3\xb1\x18\x45\x67\xf9\x22\x38"
  12352. "\x95\xd9\x34\x34\x86\xc6\x41\x94"
  12353. "\x15\xf9\x5b\x41\xa6\x87\x8b\xf8"
  12354. "\xd5\xe1\x1b\xe2\x5b\xf3\x86\x10"
  12355. "\xff\xe6\xae\x69\x76\xbc\x0d\xb4"
  12356. "\x09\x90\x0c\xa2\x65\x0c\xad\x74"
  12357. "\xf5\xd7\xff\xda\xc1\xce\x85\xbe"
  12358. "\x00\xa7\xff\x4d\x2f\x65\xd3\x8c"
  12359. "\x86\x2d\x05\xe8\xed\x3e\x6b\x8b"
  12360. "\x0f\x3d\x83\x8c\xf1\x1d\x5b\x96"
  12361. "\x2e\xb1\x9c\xc2\x98\xe1\x70\xb9"
  12362. "\xba\x5c\x8a\x43\xd6\x34\xa7\x2d"
  12363. "\xc9\x92\xae\xf2\xa5\x7b\x05\x49"
  12364. "\xa7\x33\x34\x86\xca\xe4\x96\x23"
  12365. "\x76\x5b\xf2\xc6\xf1\x51\x28\x42"
  12366. "\x7b\xcc\x76\x8f\xfa\xa2\xad\x31"
  12367. "\xd4\xd6\x7a\x6d\x25\x25\x54\xe4"
  12368. "\x3f\x50\x59\xe1\x5c\x05\xb7\x27"
  12369. "\x48\xbf\x07\xec\x1b\x13\xbe\x2b"
  12370. "\xa1\x57\x2b\xd5\xab\xd7\xd0\x4c"
  12371. "\x1e\xcb\x71\x9b\xc5\x90\x85\xd3"
  12372. "\xde\x59\xec\x71\xeb\x89\xbb\xd0"
  12373. "\x09\x50\xe1\x16\x3f\xfd\x1c\x34"
  12374. "\xc3\x1c\xa1\x10\x77\x53\x98\xef"
  12375. "\xf2\xfd\xa5\x01\x59\xc2\x9b\x26"
  12376. "\xc7\x42\xd9\x49\xda\x58\x2b\x6e"
  12377. "\x9f\x53\x19\x76\x7e\xd9\xc9\x0e"
  12378. "\x68\xc8\x7f\x51\x22\x42\xef\x49"
  12379. "\xa4\x55\xb6\x36\xac\x09\xc7\x31"
  12380. "\x88\x15\x4b\x2e\x8f\x3a\x08\xf7"
  12381. "\xd8\xf7\xa8\xc5\xa9\x33\xa6\x45"
  12382. "\xe4\xc4\x94\x76\xf3\x0d\x8f\x7e"
  12383. "\xc8\xf6\xbc\x23\x0a\xb6\x4c\xd3"
  12384. "\x6a\xcd\x36\xc2\x90\x5c\x5c\x3c"
  12385. "\x65\x7b\xc2\xd6\xcc\xe6\x0d\x87"
  12386. "\x73\x2e\x71\x79\x16\x06\x63\x28"
  12387. "\x09\x15\xd8\x89\x38\x38\x3d\xb5"
  12388. "\x42\x1c\x08\x24\xf7\x2a\xd2\x9d"
  12389. "\xc8\xca\xef\xf9\x27\xd8\x07\x86"
  12390. "\xf7\x43\x0b\x55\x15\x3f\x9f\x83"
  12391. "\xef\xdc\x49\x9d\x2a\xc1\x54\x62"
  12392. "\xbd\x9b\x66\x55\x9f\xb7\x12\xf3"
  12393. "\x1b\x4d\x9d\x2a\x5c\xed\x87\x75"
  12394. "\x87\x26\xec\x61\x2c\xb4\x0f\x89"
  12395. "\xb0\xfb\x2e\x68\x5d\x15\xc7\x8d"
  12396. "\x2e\xc0\xd9\xec\xaf\x4f\xd2\x25"
  12397. "\x29\xe8\xd2\x26\x2b\x67\xe9\xfc"
  12398. "\x2b\xa8\x67\x96\x12\x1f\x5b\x96"
  12399. "\xc6\x14\x53\xaf\x44\xea\xd6\xe2"
  12400. "\x94\x98\xe4\x12\x93\x4c\x92\xe0"
  12401. "\x18\xa5\x8d\x2d\xe4\x71\x3c\x47"
  12402. "\x4c\xf7\xe6\x47\x9e\xc0\x68\xdf"
  12403. "\xd4\xf5\x5a\x74\xb1\x2b\x29\x03"
  12404. "\x19\x07\xaf\x90\x62\x5c\x68\x98"
  12405. "\x48\x16\x11\x02\x9d\xee\xb4\x9b"
  12406. "\xe5\x42\x7f\x08\xfd\x16\x32\x0b"
  12407. "\xd0\xb3\xfa\x2b\xb7\x99\xf9\x29"
  12408. "\xcd\x20\x45\x9f\xb3\x1a\x5d\xa2"
  12409. "\xaf\x4d\xe0\xbd\x42\x0d\xbc\x74"
  12410. "\x99\x9c\x8e\x53\x1a\xb4\x3e\xbd"
  12411. "\xa2\x9a\x2d\xf7\xf8\x39\x0f\x67"
  12412. "\x63\xfc\x6b\xc0\xaf\xb3\x4b\x4f"
  12413. "\x55\xc4\xcf\xa7\xc8\x04\x11\x3e"
  12414. "\x14\x32\xbb\x1b\x38\x77\xd6\x7f"
  12415. "\x54\x4c\xdf\x75\xf3\x07\x2d\x33"
  12416. "\x9b\xa8\x20\xe1\x7b\x12\xb5\xf3"
  12417. "\xef\x2f\xce\x72\xe5\x24\x60\xc1"
  12418. "\x30\xe2\xab\xa1\x8e\x11\x09\xa8"
  12419. "\x21\x33\x44\xfe\x7f\x35\x32\x93"
  12420. "\x39\xa7\xad\x8b\x79\x06\xb2\xcb"
  12421. "\x4e\xa9\x5f\xc7\xba\x74\x29\xec"
  12422. "\x93\xa0\x4e\x54\x93\xc0\xbc\x55"
  12423. "\x64\xf0\x48\xe5\x57\x99\xee\x75"
  12424. "\xd6\x79\x0f\x66\xb7\xc6\x57\x76"
  12425. "\xf7\xb7\xf3\x9c\xc5\x60\xe8\x7f"
  12426. "\x83\x76\xd6\x0e\xaa\xe6\x90\x39"
  12427. "\x1d\xa6\x32\x6a\x34\xe3\x55\xf8"
  12428. "\x58\xa0\x58\x7d\x33\xe0\x22\x39"
  12429. "\x44\x64\x87\x86\x5a\x2f\xa7\x7e"
  12430. "\x0f\x38\xea\xb0\x30\xcc\x61\xa5"
  12431. "\x6a\x32\xae\x1e\xf7\xe9\xd0\xa9"
  12432. "\x0c\x32\x4b\xb5\x49\x28\xab\x85"
  12433. "\x2f\x8e\x01\x36\x38\x52\xd0\xba"
  12434. "\xd6\x02\x78\xf8\x0e\x3e\x9c\x8b"
  12435. "\x6b\x45\x99\x3f\x5c\xfe\x58\xf1"
  12436. "\x5c\x94\x04\xe1\xf5\x18\x6d\x51"
  12437. "\xb2\x5d\x18\x20\xb6\xc2\x9a\x42"
  12438. "\x1d\xb3\xab\x3c\xb6\x3a\x13\x03"
  12439. "\xb2\x46\x82\x4f\xfc\x64\xbc\x4f"
  12440. "\xca\xfa\x9c\xc0\xd5\xa7\xbd\x11"
  12441. "\xb7\xe4\x5a\xf6\x6f\x4d\x4d\x54"
  12442. "\xea\xa4\x98\x66\xd4\x22\x3b\xd3"
  12443. "\x8f\x34\x47\xd9\x7c\xf4\x72\x3b"
  12444. "\x4d\x02\x77\xf6\xd6\xdd\x08\x0a"
  12445. "\x81\xe1\x86\x89\x3e\x56\x10\x3c"
  12446. "\xba\xd7\x81\x8c\x08\xbc\x8b\xe2"
  12447. "\x53\xec\xa7\x89\xee\xc8\x56\xb5"
  12448. "\x36\x2c\xb2\x03\xba\x99\xdd\x7c"
  12449. "\x48\xa0\xb0\xbc\x91\x33\xe9\xa8"
  12450. "\xcb\xcd\xcf\x59\x5f\x1f\x15\xe2"
  12451. "\x56\xf5\x4e\x01\x35\x27\x45\x77"
  12452. "\x47\xc8\xbc\xcb\x7e\x39\xc1\x97"
  12453. "\x28\xd3\x84\xfc\x2c\x3e\xc8\xad"
  12454. "\x9c\xf8\x8a\x61\x9c\x28\xaa\xc5"
  12455. "\x99\x20\x43\x85\x9d\xa5\xe2\x8b"
  12456. "\xb8\xae\xeb\xd0\x32\x0d\x52\x78"
  12457. "\x09\x56\x3f\xc7\xd8\x7e\x26\xfc"
  12458. "\x37\xfb\x6f\x04\xfc\xfa\x92\x10"
  12459. "\xac\xf8\x3e\x21\xdc\x8c\x21\x16"
  12460. "\x7d\x67\x6e\xf6\xcd\xda\xb6\x98"
  12461. "\x23\xab\x23\x3c\xb2\x10\xa0\x53"
  12462. "\x5a\x56\x9f\xc5\xd0\xff\xbb\xe4"
  12463. "\x98\x3c\x69\x1e\xdb\x38\x8f\x7e"
  12464. "\x0f\xd2\x98\x88\x81\x8b\x45\x67"
  12465. "\xea\x33\xf1\xeb\xe9\x97\x55\x2e"
  12466. "\xd9\xaa\xeb\x5a\xec\xda\xe1\x68"
  12467. "\xa8\x9d\x3c\x84\x7c\x05\x3d\x62"
  12468. "\x87\x8f\x03\x21\x28\x95\x0c\x89"
  12469. "\x25\x22\x4a\xb0\x93\xa9\x50\xa2"
  12470. "\x2f\x57\x6e\x18\x42\x19\x54\x0c"
  12471. "\x55\x67\xc6\x11\x49\xf4\x5c\xd2"
  12472. "\xe9\x3d\xdd\x8b\x48\x71\x21\x00"
  12473. "\xc3\x9a\x6c\x85\x74\x28\x83\x4a"
  12474. "\x1b\x31\x05\xe1\x06\x92\xe7\xda"
  12475. "\x85\x73\x78\x45\x20\x7f\xae\x13"
  12476. "\x7c\x33\x06\x22\xf4\x83\xf9\x35"
  12477. "\x3f\x6c\x71\xa8\x4e\x48\xbe\x9b"
  12478. "\xce\x8a\xba\xda\xbe\x28\x08\xf7"
  12479. "\xe2\x14\x8c\x71\xea\x72\xf9\x33"
  12480. "\xf2\x88\x3f\xd7\xbb\x69\x6c\x29"
  12481. "\x19\xdc\x84\xce\x1f\x12\x4f\xc8"
  12482. "\xaf\xa5\x04\xba\x5a\xab\xb0\xd9"
  12483. "\x14\x1f\x6c\x68\x98\x39\x89\x7a"
  12484. "\xd9\xd8\x2f\xdf\xa8\x47\x4a\x25"
  12485. "\xe2\xfb\x33\xf4\x59\x78\xe1\x68"
  12486. "\x85\xcf\xfe\x59\x20\xd4\x05\x1d"
  12487. "\x80\x99\xae\xbc\xca\xae\x0f\x2f"
  12488. "\x65\x43\x34\x8e\x7e\xac\xd3\x93"
  12489. "\x2f\xac\x6d\x14\x3d\x02\x07\x70"
  12490. "\x9d\xa4\xf3\x1b\x5c\x36\xfc\x01"
  12491. "\x73\x34\x85\x0c\x6c\xd6\xf1\xbd"
  12492. "\x3f\xdf\xee\xf5\xd9\xba\x56\xef"
  12493. "\xf4\x9b\x6b\xee\x9f\x5a\x78\x6d"
  12494. "\x32\x19\xf4\xf7\xf8\x4c\x69\x0b"
  12495. "\x4b\xbc\xbb\xb7\xf2\x85\xaf\x70"
  12496. "\x75\x24\x6c\x54\xa7\x0e\x4d\x1d"
  12497. "\x01\xbf\x08\xac\xcf\x7f\x2c\xe3"
  12498. "\x14\x89\x5e\x70\x5a\x99\x92\xcd"
  12499. "\x01\x84\xc8\xd2\xab\xe5\x4f\x58"
  12500. "\xe7\x0f\x2f\x0e\xff\x68\xea\xfd"
  12501. "\x15\xb3\x17\xe6\xb0\xe7\x85\xd8"
  12502. "\x23\x2e\x05\xc7\xc9\xc4\x46\x1f"
  12503. "\xe1\x9e\x49\x20\x23\x24\x4d\x7e"
  12504. "\x29\x65\xff\xf4\xb6\xfd\x1a\x85"
  12505. "\xc4\x16\xec\xfc\xea\x7b\xd6\x2c"
  12506. "\x43\xf8\xb7\xbf\x79\xc0\x85\xcd"
  12507. "\xef\xe1\x98\xd3\xa5\xf7\x90\x8c"
  12508. "\xe9\x7f\x80\x6b\xd2\xac\x4c\x30"
  12509. "\xa7\xc6\x61\x6c\xd2\xf9\x2c\xff"
  12510. "\x30\xbc\x22\x81\x7d\x93\x12\xe4"
  12511. "\x0a\xcd\xaf\xdd\xe8\xab\x0a\x1e"
  12512. "\x13\xa4\x27\xc3\x5f\xf7\x4b\xbb"
  12513. "\x37\x09\x4b\x91\x6f\x92\x4f\xaf"
  12514. "\x52\xee\xdf\xef\x09\x6f\xf7\x5c"
  12515. "\x6e\x12\x17\x72\x63\x57\xc7\xba"
  12516. "\x3b\x6b\x38\x32\x73\x1b\x9c\x80"
  12517. "\xc1\x7a\xc6\xcf\xcd\x35\xc0\x6b"
  12518. "\x31\x1a\x6b\xe9\xd8\x2c\x29\x3f"
  12519. "\x96\xfb\xb6\xcd\x13\x91\x3b\xc2"
  12520. "\xd2\xa3\x31\x8d\xa4\xcd\x57\xcd"
  12521. "\x13\x3d\x64\xfd\x06\xce\xe6\xdc"
  12522. "\x0c\x24\x43\x31\x40\x57\xf1\x72"
  12523. "\x17\xe3\x3a\x63\x6d\x35\xcf\x5d"
  12524. "\x97\x40\x59\xdd\xf7\x3c\x02\xf7"
  12525. "\x1c\x7e\x05\xbb\xa9\x0d\x01\xb1"
  12526. "\x8e\xc0\x30\xa9\x53\x24\xc9\x89"
  12527. "\x84\x6d\xaa\xd0\xcd\x91\xc2\x4d"
  12528. "\x91\xb0\x89\xe2\xbf\x83\x44\xaa"
  12529. "\x28\x72\x23\xa0\xc2\xad\xad\x1c"
  12530. "\xfc\x3f\x09\x7a\x0b\xdc\xc5\x1b"
  12531. "\x87\x13\xc6\x5b\x59\x8d\xf2\xc8"
  12532. "\xaf\xdf\x11\x95",
  12533. .rlen = 4100,
  12534. .np = 2,
  12535. .tap = { 4064, 36 },
  12536. },
  12537. };
  12538. /*
  12539. * CTS (Cipher Text Stealing) mode tests
  12540. */
  12541. #define CTS_MODE_ENC_TEST_VECTORS 6
  12542. #define CTS_MODE_DEC_TEST_VECTORS 6
  12543. static struct cipher_testvec cts_mode_enc_tv_template[] = {
  12544. { /* from rfc3962 */
  12545. .klen = 16,
  12546. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12547. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12548. .ilen = 17,
  12549. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12550. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12551. "\x20",
  12552. .rlen = 17,
  12553. .result = "\xc6\x35\x35\x68\xf2\xbf\x8c\xb4"
  12554. "\xd8\xa5\x80\x36\x2d\xa7\xff\x7f"
  12555. "\x97",
  12556. }, {
  12557. .klen = 16,
  12558. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12559. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12560. .ilen = 31,
  12561. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12562. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12563. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12564. "\x20\x47\x61\x75\x27\x73\x20",
  12565. .rlen = 31,
  12566. .result = "\xfc\x00\x78\x3e\x0e\xfd\xb2\xc1"
  12567. "\xd4\x45\xd4\xc8\xef\xf7\xed\x22"
  12568. "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12569. "\xc0\x7b\x25\xe2\x5e\xcf\xe5",
  12570. }, {
  12571. .klen = 16,
  12572. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12573. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12574. .ilen = 32,
  12575. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12576. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12577. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12578. "\x20\x47\x61\x75\x27\x73\x20\x43",
  12579. .rlen = 32,
  12580. .result = "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12581. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8"
  12582. "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12583. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84",
  12584. }, {
  12585. .klen = 16,
  12586. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12587. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12588. .ilen = 47,
  12589. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12590. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12591. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12592. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12593. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12594. "\x70\x6c\x65\x61\x73\x65\x2c",
  12595. .rlen = 47,
  12596. .result = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12597. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12598. "\xb3\xff\xfd\x94\x0c\x16\xa1\x8c"
  12599. "\x1b\x55\x49\xd2\xf8\x38\x02\x9e"
  12600. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12601. "\xbe\x7f\xcb\xcc\x98\xeb\xf5",
  12602. }, {
  12603. .klen = 16,
  12604. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12605. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12606. .ilen = 48,
  12607. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12608. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12609. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12610. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12611. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12612. "\x70\x6c\x65\x61\x73\x65\x2c\x20",
  12613. .rlen = 48,
  12614. .result = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12615. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12616. "\x9d\xad\x8b\xbb\x96\xc4\xcd\xc0"
  12617. "\x3b\xc1\x03\xe1\xa1\x94\xbb\xd8"
  12618. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12619. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8",
  12620. }, {
  12621. .klen = 16,
  12622. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12623. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12624. .ilen = 64,
  12625. .input = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12626. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12627. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12628. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12629. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12630. "\x70\x6c\x65\x61\x73\x65\x2c\x20"
  12631. "\x61\x6e\x64\x20\x77\x6f\x6e\x74"
  12632. "\x6f\x6e\x20\x73\x6f\x75\x70\x2e",
  12633. .rlen = 64,
  12634. .result = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12635. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12636. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12637. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8"
  12638. "\x48\x07\xef\xe8\x36\xee\x89\xa5"
  12639. "\x26\x73\x0d\xbc\x2f\x7b\xc8\x40"
  12640. "\x9d\xad\x8b\xbb\x96\xc4\xcd\xc0"
  12641. "\x3b\xc1\x03\xe1\xa1\x94\xbb\xd8",
  12642. }
  12643. };
  12644. static struct cipher_testvec cts_mode_dec_tv_template[] = {
  12645. { /* from rfc3962 */
  12646. .klen = 16,
  12647. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12648. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12649. .rlen = 17,
  12650. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12651. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12652. "\x20",
  12653. .ilen = 17,
  12654. .input = "\xc6\x35\x35\x68\xf2\xbf\x8c\xb4"
  12655. "\xd8\xa5\x80\x36\x2d\xa7\xff\x7f"
  12656. "\x97",
  12657. }, {
  12658. .klen = 16,
  12659. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12660. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12661. .rlen = 31,
  12662. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12663. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12664. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12665. "\x20\x47\x61\x75\x27\x73\x20",
  12666. .ilen = 31,
  12667. .input = "\xfc\x00\x78\x3e\x0e\xfd\xb2\xc1"
  12668. "\xd4\x45\xd4\xc8\xef\xf7\xed\x22"
  12669. "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12670. "\xc0\x7b\x25\xe2\x5e\xcf\xe5",
  12671. }, {
  12672. .klen = 16,
  12673. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12674. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12675. .rlen = 32,
  12676. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12677. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12678. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12679. "\x20\x47\x61\x75\x27\x73\x20\x43",
  12680. .ilen = 32,
  12681. .input = "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12682. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8"
  12683. "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12684. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84",
  12685. }, {
  12686. .klen = 16,
  12687. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12688. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12689. .rlen = 47,
  12690. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12691. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12692. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12693. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12694. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12695. "\x70\x6c\x65\x61\x73\x65\x2c",
  12696. .ilen = 47,
  12697. .input = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12698. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12699. "\xb3\xff\xfd\x94\x0c\x16\xa1\x8c"
  12700. "\x1b\x55\x49\xd2\xf8\x38\x02\x9e"
  12701. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12702. "\xbe\x7f\xcb\xcc\x98\xeb\xf5",
  12703. }, {
  12704. .klen = 16,
  12705. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12706. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12707. .rlen = 48,
  12708. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12709. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12710. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12711. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12712. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12713. "\x70\x6c\x65\x61\x73\x65\x2c\x20",
  12714. .ilen = 48,
  12715. .input = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12716. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12717. "\x9d\xad\x8b\xbb\x96\xc4\xcd\xc0"
  12718. "\x3b\xc1\x03\xe1\xa1\x94\xbb\xd8"
  12719. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12720. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8",
  12721. }, {
  12722. .klen = 16,
  12723. .key = "\x63\x68\x69\x63\x6b\x65\x6e\x20"
  12724. "\x74\x65\x72\x69\x79\x61\x6b\x69",
  12725. .rlen = 64,
  12726. .result = "\x49\x20\x77\x6f\x75\x6c\x64\x20"
  12727. "\x6c\x69\x6b\x65\x20\x74\x68\x65"
  12728. "\x20\x47\x65\x6e\x65\x72\x61\x6c"
  12729. "\x20\x47\x61\x75\x27\x73\x20\x43"
  12730. "\x68\x69\x63\x6b\x65\x6e\x2c\x20"
  12731. "\x70\x6c\x65\x61\x73\x65\x2c\x20"
  12732. "\x61\x6e\x64\x20\x77\x6f\x6e\x74"
  12733. "\x6f\x6e\x20\x73\x6f\x75\x70\x2e",
  12734. .ilen = 64,
  12735. .input = "\x97\x68\x72\x68\xd6\xec\xcc\xc0"
  12736. "\xc0\x7b\x25\xe2\x5e\xcf\xe5\x84"
  12737. "\x39\x31\x25\x23\xa7\x86\x62\xd5"
  12738. "\xbe\x7f\xcb\xcc\x98\xeb\xf5\xa8"
  12739. "\x48\x07\xef\xe8\x36\xee\x89\xa5"
  12740. "\x26\x73\x0d\xbc\x2f\x7b\xc8\x40"
  12741. "\x9d\xad\x8b\xbb\x96\xc4\xcd\xc0"
  12742. "\x3b\xc1\x03\xe1\xa1\x94\xbb\xd8",
  12743. }
  12744. };
  12745. /*
  12746. * Compression stuff.
  12747. */
  12748. #define COMP_BUF_SIZE 512
  12749. struct comp_testvec {
  12750. int inlen, outlen;
  12751. char input[COMP_BUF_SIZE];
  12752. char output[COMP_BUF_SIZE];
  12753. };
  12754. struct pcomp_testvec {
  12755. void *params;
  12756. unsigned int paramsize;
  12757. int inlen, outlen;
  12758. char input[COMP_BUF_SIZE];
  12759. char output[COMP_BUF_SIZE];
  12760. };
  12761. /*
  12762. * Deflate test vectors (null-terminated strings).
  12763. * Params: winbits=-11, Z_DEFAULT_COMPRESSION, MAX_MEM_LEVEL.
  12764. */
  12765. #define DEFLATE_COMP_TEST_VECTORS 2
  12766. #define DEFLATE_DECOMP_TEST_VECTORS 2
  12767. static struct comp_testvec deflate_comp_tv_template[] = {
  12768. {
  12769. .inlen = 70,
  12770. .outlen = 38,
  12771. .input = "Join us now and share the software "
  12772. "Join us now and share the software ",
  12773. .output = "\xf3\xca\xcf\xcc\x53\x28\x2d\x56"
  12774. "\xc8\xcb\x2f\x57\x48\xcc\x4b\x51"
  12775. "\x28\xce\x48\x2c\x4a\x55\x28\xc9"
  12776. "\x48\x55\x28\xce\x4f\x2b\x29\x07"
  12777. "\x71\xbc\x08\x2b\x01\x00",
  12778. }, {
  12779. .inlen = 191,
  12780. .outlen = 122,
  12781. .input = "This document describes a compression method based on the DEFLATE"
  12782. "compression algorithm. This document defines the application of "
  12783. "the DEFLATE algorithm to the IP Payload Compression Protocol.",
  12784. .output = "\x5d\x8d\x31\x0e\xc2\x30\x10\x04"
  12785. "\xbf\xb2\x2f\xc8\x1f\x10\x04\x09"
  12786. "\x89\xc2\x85\x3f\x70\xb1\x2f\xf8"
  12787. "\x24\xdb\x67\xd9\x47\xc1\xef\x49"
  12788. "\x68\x12\x51\xae\x76\x67\xd6\x27"
  12789. "\x19\x88\x1a\xde\x85\xab\x21\xf2"
  12790. "\x08\x5d\x16\x1e\x20\x04\x2d\xad"
  12791. "\xf3\x18\xa2\x15\x85\x2d\x69\xc4"
  12792. "\x42\x83\x23\xb6\x6c\x89\x71\x9b"
  12793. "\xef\xcf\x8b\x9f\xcf\x33\xca\x2f"
  12794. "\xed\x62\xa9\x4c\x80\xff\x13\xaf"
  12795. "\x52\x37\xed\x0e\x52\x6b\x59\x02"
  12796. "\xd9\x4e\xe8\x7a\x76\x1d\x02\x98"
  12797. "\xfe\x8a\x87\x83\xa3\x4f\x56\x8a"
  12798. "\xb8\x9e\x8e\x5c\x57\xd3\xa0\x79"
  12799. "\xfa\x02",
  12800. },
  12801. };
  12802. static struct comp_testvec deflate_decomp_tv_template[] = {
  12803. {
  12804. .inlen = 122,
  12805. .outlen = 191,
  12806. .input = "\x5d\x8d\x31\x0e\xc2\x30\x10\x04"
  12807. "\xbf\xb2\x2f\xc8\x1f\x10\x04\x09"
  12808. "\x89\xc2\x85\x3f\x70\xb1\x2f\xf8"
  12809. "\x24\xdb\x67\xd9\x47\xc1\xef\x49"
  12810. "\x68\x12\x51\xae\x76\x67\xd6\x27"
  12811. "\x19\x88\x1a\xde\x85\xab\x21\xf2"
  12812. "\x08\x5d\x16\x1e\x20\x04\x2d\xad"
  12813. "\xf3\x18\xa2\x15\x85\x2d\x69\xc4"
  12814. "\x42\x83\x23\xb6\x6c\x89\x71\x9b"
  12815. "\xef\xcf\x8b\x9f\xcf\x33\xca\x2f"
  12816. "\xed\x62\xa9\x4c\x80\xff\x13\xaf"
  12817. "\x52\x37\xed\x0e\x52\x6b\x59\x02"
  12818. "\xd9\x4e\xe8\x7a\x76\x1d\x02\x98"
  12819. "\xfe\x8a\x87\x83\xa3\x4f\x56\x8a"
  12820. "\xb8\x9e\x8e\x5c\x57\xd3\xa0\x79"
  12821. "\xfa\x02",
  12822. .output = "This document describes a compression method based on the DEFLATE"
  12823. "compression algorithm. This document defines the application of "
  12824. "the DEFLATE algorithm to the IP Payload Compression Protocol.",
  12825. }, {
  12826. .inlen = 38,
  12827. .outlen = 70,
  12828. .input = "\xf3\xca\xcf\xcc\x53\x28\x2d\x56"
  12829. "\xc8\xcb\x2f\x57\x48\xcc\x4b\x51"
  12830. "\x28\xce\x48\x2c\x4a\x55\x28\xc9"
  12831. "\x48\x55\x28\xce\x4f\x2b\x29\x07"
  12832. "\x71\xbc\x08\x2b\x01\x00",
  12833. .output = "Join us now and share the software "
  12834. "Join us now and share the software ",
  12835. },
  12836. };
  12837. #define ZLIB_COMP_TEST_VECTORS 2
  12838. #define ZLIB_DECOMP_TEST_VECTORS 2
  12839. static const struct {
  12840. struct nlattr nla;
  12841. int val;
  12842. } deflate_comp_params[] = {
  12843. {
  12844. .nla = {
  12845. .nla_len = NLA_HDRLEN + sizeof(int),
  12846. .nla_type = ZLIB_COMP_LEVEL,
  12847. },
  12848. .val = Z_DEFAULT_COMPRESSION,
  12849. }, {
  12850. .nla = {
  12851. .nla_len = NLA_HDRLEN + sizeof(int),
  12852. .nla_type = ZLIB_COMP_METHOD,
  12853. },
  12854. .val = Z_DEFLATED,
  12855. }, {
  12856. .nla = {
  12857. .nla_len = NLA_HDRLEN + sizeof(int),
  12858. .nla_type = ZLIB_COMP_WINDOWBITS,
  12859. },
  12860. .val = -11,
  12861. }, {
  12862. .nla = {
  12863. .nla_len = NLA_HDRLEN + sizeof(int),
  12864. .nla_type = ZLIB_COMP_MEMLEVEL,
  12865. },
  12866. .val = MAX_MEM_LEVEL,
  12867. }, {
  12868. .nla = {
  12869. .nla_len = NLA_HDRLEN + sizeof(int),
  12870. .nla_type = ZLIB_COMP_STRATEGY,
  12871. },
  12872. .val = Z_DEFAULT_STRATEGY,
  12873. }
  12874. };
  12875. static const struct {
  12876. struct nlattr nla;
  12877. int val;
  12878. } deflate_decomp_params[] = {
  12879. {
  12880. .nla = {
  12881. .nla_len = NLA_HDRLEN + sizeof(int),
  12882. .nla_type = ZLIB_DECOMP_WINDOWBITS,
  12883. },
  12884. .val = -11,
  12885. }
  12886. };
  12887. static struct pcomp_testvec zlib_comp_tv_template[] = {
  12888. {
  12889. .params = &deflate_comp_params,
  12890. .paramsize = sizeof(deflate_comp_params),
  12891. .inlen = 70,
  12892. .outlen = 38,
  12893. .input = "Join us now and share the software "
  12894. "Join us now and share the software ",
  12895. .output = "\xf3\xca\xcf\xcc\x53\x28\x2d\x56"
  12896. "\xc8\xcb\x2f\x57\x48\xcc\x4b\x51"
  12897. "\x28\xce\x48\x2c\x4a\x55\x28\xc9"
  12898. "\x48\x55\x28\xce\x4f\x2b\x29\x07"
  12899. "\x71\xbc\x08\x2b\x01\x00",
  12900. }, {
  12901. .params = &deflate_comp_params,
  12902. .paramsize = sizeof(deflate_comp_params),
  12903. .inlen = 191,
  12904. .outlen = 122,
  12905. .input = "This document describes a compression method based on the DEFLATE"
  12906. "compression algorithm. This document defines the application of "
  12907. "the DEFLATE algorithm to the IP Payload Compression Protocol.",
  12908. .output = "\x5d\x8d\x31\x0e\xc2\x30\x10\x04"
  12909. "\xbf\xb2\x2f\xc8\x1f\x10\x04\x09"
  12910. "\x89\xc2\x85\x3f\x70\xb1\x2f\xf8"
  12911. "\x24\xdb\x67\xd9\x47\xc1\xef\x49"
  12912. "\x68\x12\x51\xae\x76\x67\xd6\x27"
  12913. "\x19\x88\x1a\xde\x85\xab\x21\xf2"
  12914. "\x08\x5d\x16\x1e\x20\x04\x2d\xad"
  12915. "\xf3\x18\xa2\x15\x85\x2d\x69\xc4"
  12916. "\x42\x83\x23\xb6\x6c\x89\x71\x9b"
  12917. "\xef\xcf\x8b\x9f\xcf\x33\xca\x2f"
  12918. "\xed\x62\xa9\x4c\x80\xff\x13\xaf"
  12919. "\x52\x37\xed\x0e\x52\x6b\x59\x02"
  12920. "\xd9\x4e\xe8\x7a\x76\x1d\x02\x98"
  12921. "\xfe\x8a\x87\x83\xa3\x4f\x56\x8a"
  12922. "\xb8\x9e\x8e\x5c\x57\xd3\xa0\x79"
  12923. "\xfa\x02",
  12924. },
  12925. };
  12926. static struct pcomp_testvec zlib_decomp_tv_template[] = {
  12927. {
  12928. .params = &deflate_decomp_params,
  12929. .paramsize = sizeof(deflate_decomp_params),
  12930. .inlen = 122,
  12931. .outlen = 191,
  12932. .input = "\x5d\x8d\x31\x0e\xc2\x30\x10\x04"
  12933. "\xbf\xb2\x2f\xc8\x1f\x10\x04\x09"
  12934. "\x89\xc2\x85\x3f\x70\xb1\x2f\xf8"
  12935. "\x24\xdb\x67\xd9\x47\xc1\xef\x49"
  12936. "\x68\x12\x51\xae\x76\x67\xd6\x27"
  12937. "\x19\x88\x1a\xde\x85\xab\x21\xf2"
  12938. "\x08\x5d\x16\x1e\x20\x04\x2d\xad"
  12939. "\xf3\x18\xa2\x15\x85\x2d\x69\xc4"
  12940. "\x42\x83\x23\xb6\x6c\x89\x71\x9b"
  12941. "\xef\xcf\x8b\x9f\xcf\x33\xca\x2f"
  12942. "\xed\x62\xa9\x4c\x80\xff\x13\xaf"
  12943. "\x52\x37\xed\x0e\x52\x6b\x59\x02"
  12944. "\xd9\x4e\xe8\x7a\x76\x1d\x02\x98"
  12945. "\xfe\x8a\x87\x83\xa3\x4f\x56\x8a"
  12946. "\xb8\x9e\x8e\x5c\x57\xd3\xa0\x79"
  12947. "\xfa\x02",
  12948. .output = "This document describes a compression method based on the DEFLATE"
  12949. "compression algorithm. This document defines the application of "
  12950. "the DEFLATE algorithm to the IP Payload Compression Protocol.",
  12951. }, {
  12952. .params = &deflate_decomp_params,
  12953. .paramsize = sizeof(deflate_decomp_params),
  12954. .inlen = 38,
  12955. .outlen = 70,
  12956. .input = "\xf3\xca\xcf\xcc\x53\x28\x2d\x56"
  12957. "\xc8\xcb\x2f\x57\x48\xcc\x4b\x51"
  12958. "\x28\xce\x48\x2c\x4a\x55\x28\xc9"
  12959. "\x48\x55\x28\xce\x4f\x2b\x29\x07"
  12960. "\x71\xbc\x08\x2b\x01\x00",
  12961. .output = "Join us now and share the software "
  12962. "Join us now and share the software ",
  12963. },
  12964. };
  12965. /*
  12966. * LZO test vectors (null-terminated strings).
  12967. */
  12968. #define LZO_COMP_TEST_VECTORS 2
  12969. #define LZO_DECOMP_TEST_VECTORS 2
  12970. static struct comp_testvec lzo_comp_tv_template[] = {
  12971. {
  12972. .inlen = 70,
  12973. .outlen = 46,
  12974. .input = "Join us now and share the software "
  12975. "Join us now and share the software ",
  12976. .output = "\x00\x0d\x4a\x6f\x69\x6e\x20\x75"
  12977. "\x73\x20\x6e\x6f\x77\x20\x61\x6e"
  12978. "\x64\x20\x73\x68\x61\x72\x65\x20"
  12979. "\x74\x68\x65\x20\x73\x6f\x66\x74"
  12980. "\x77\x70\x01\x01\x4a\x6f\x69\x6e"
  12981. "\x3d\x88\x00\x11\x00\x00",
  12982. }, {
  12983. .inlen = 159,
  12984. .outlen = 133,
  12985. .input = "This document describes a compression method based on the LZO "
  12986. "compression algorithm. This document defines the application of "
  12987. "the LZO algorithm used in UBIFS.",
  12988. .output = "\x00\x2b\x54\x68\x69\x73\x20\x64"
  12989. "\x6f\x63\x75\x6d\x65\x6e\x74\x20"
  12990. "\x64\x65\x73\x63\x72\x69\x62\x65"
  12991. "\x73\x20\x61\x20\x63\x6f\x6d\x70"
  12992. "\x72\x65\x73\x73\x69\x6f\x6e\x20"
  12993. "\x6d\x65\x74\x68\x6f\x64\x20\x62"
  12994. "\x61\x73\x65\x64\x20\x6f\x6e\x20"
  12995. "\x74\x68\x65\x20\x4c\x5a\x4f\x2b"
  12996. "\x8c\x00\x0d\x61\x6c\x67\x6f\x72"
  12997. "\x69\x74\x68\x6d\x2e\x20\x20\x54"
  12998. "\x68\x69\x73\x2a\x54\x01\x02\x66"
  12999. "\x69\x6e\x65\x73\x94\x06\x05\x61"
  13000. "\x70\x70\x6c\x69\x63\x61\x74\x76"
  13001. "\x0a\x6f\x66\x88\x02\x60\x09\x27"
  13002. "\xf0\x00\x0c\x20\x75\x73\x65\x64"
  13003. "\x20\x69\x6e\x20\x55\x42\x49\x46"
  13004. "\x53\x2e\x11\x00\x00",
  13005. },
  13006. };
  13007. static struct comp_testvec lzo_decomp_tv_template[] = {
  13008. {
  13009. .inlen = 133,
  13010. .outlen = 159,
  13011. .input = "\x00\x2b\x54\x68\x69\x73\x20\x64"
  13012. "\x6f\x63\x75\x6d\x65\x6e\x74\x20"
  13013. "\x64\x65\x73\x63\x72\x69\x62\x65"
  13014. "\x73\x20\x61\x20\x63\x6f\x6d\x70"
  13015. "\x72\x65\x73\x73\x69\x6f\x6e\x20"
  13016. "\x6d\x65\x74\x68\x6f\x64\x20\x62"
  13017. "\x61\x73\x65\x64\x20\x6f\x6e\x20"
  13018. "\x74\x68\x65\x20\x4c\x5a\x4f\x2b"
  13019. "\x8c\x00\x0d\x61\x6c\x67\x6f\x72"
  13020. "\x69\x74\x68\x6d\x2e\x20\x20\x54"
  13021. "\x68\x69\x73\x2a\x54\x01\x02\x66"
  13022. "\x69\x6e\x65\x73\x94\x06\x05\x61"
  13023. "\x70\x70\x6c\x69\x63\x61\x74\x76"
  13024. "\x0a\x6f\x66\x88\x02\x60\x09\x27"
  13025. "\xf0\x00\x0c\x20\x75\x73\x65\x64"
  13026. "\x20\x69\x6e\x20\x55\x42\x49\x46"
  13027. "\x53\x2e\x11\x00\x00",
  13028. .output = "This document describes a compression method based on the LZO "
  13029. "compression algorithm. This document defines the application of "
  13030. "the LZO algorithm used in UBIFS.",
  13031. }, {
  13032. .inlen = 46,
  13033. .outlen = 70,
  13034. .input = "\x00\x0d\x4a\x6f\x69\x6e\x20\x75"
  13035. "\x73\x20\x6e\x6f\x77\x20\x61\x6e"
  13036. "\x64\x20\x73\x68\x61\x72\x65\x20"
  13037. "\x74\x68\x65\x20\x73\x6f\x66\x74"
  13038. "\x77\x70\x01\x01\x4a\x6f\x69\x6e"
  13039. "\x3d\x88\x00\x11\x00\x00",
  13040. .output = "Join us now and share the software "
  13041. "Join us now and share the software ",
  13042. },
  13043. };
  13044. /*
  13045. * Michael MIC test vectors from IEEE 802.11i
  13046. */
  13047. #define MICHAEL_MIC_TEST_VECTORS 6
  13048. static struct hash_testvec michael_mic_tv_template[] = {
  13049. {
  13050. .key = "\x00\x00\x00\x00\x00\x00\x00\x00",
  13051. .ksize = 8,
  13052. .plaintext = zeroed_string,
  13053. .psize = 0,
  13054. .digest = "\x82\x92\x5c\x1c\xa1\xd1\x30\xb8",
  13055. },
  13056. {
  13057. .key = "\x82\x92\x5c\x1c\xa1\xd1\x30\xb8",
  13058. .ksize = 8,
  13059. .plaintext = "M",
  13060. .psize = 1,
  13061. .digest = "\x43\x47\x21\xca\x40\x63\x9b\x3f",
  13062. },
  13063. {
  13064. .key = "\x43\x47\x21\xca\x40\x63\x9b\x3f",
  13065. .ksize = 8,
  13066. .plaintext = "Mi",
  13067. .psize = 2,
  13068. .digest = "\xe8\xf9\xbe\xca\xe9\x7e\x5d\x29",
  13069. },
  13070. {
  13071. .key = "\xe8\xf9\xbe\xca\xe9\x7e\x5d\x29",
  13072. .ksize = 8,
  13073. .plaintext = "Mic",
  13074. .psize = 3,
  13075. .digest = "\x90\x03\x8f\xc6\xcf\x13\xc1\xdb",
  13076. },
  13077. {
  13078. .key = "\x90\x03\x8f\xc6\xcf\x13\xc1\xdb",
  13079. .ksize = 8,
  13080. .plaintext = "Mich",
  13081. .psize = 4,
  13082. .digest = "\xd5\x5e\x10\x05\x10\x12\x89\x86",
  13083. },
  13084. {
  13085. .key = "\xd5\x5e\x10\x05\x10\x12\x89\x86",
  13086. .ksize = 8,
  13087. .plaintext = "Michael",
  13088. .psize = 7,
  13089. .digest = "\x0a\x94\x2b\x12\x4e\xca\xa5\x46",
  13090. }
  13091. };
  13092. /*
  13093. * CRC32C test vectors
  13094. */
  13095. #define CRC32C_TEST_VECTORS 14
  13096. static struct hash_testvec crc32c_tv_template[] = {
  13097. {
  13098. .psize = 0,
  13099. .digest = "\x00\x00\x00\x00",
  13100. },
  13101. {
  13102. .key = "\x87\xa9\xcb\xed",
  13103. .ksize = 4,
  13104. .psize = 0,
  13105. .digest = "\x78\x56\x34\x12",
  13106. },
  13107. {
  13108. .key = "\xff\xff\xff\xff",
  13109. .ksize = 4,
  13110. .plaintext = "\x01\x02\x03\x04\x05\x06\x07\x08"
  13111. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  13112. "\x11\x12\x13\x14\x15\x16\x17\x18"
  13113. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20"
  13114. "\x21\x22\x23\x24\x25\x26\x27\x28",
  13115. .psize = 40,
  13116. .digest = "\x7f\x15\x2c\x0e",
  13117. },
  13118. {
  13119. .key = "\xff\xff\xff\xff",
  13120. .ksize = 4,
  13121. .plaintext = "\x29\x2a\x2b\x2c\x2d\x2e\x2f\x30"
  13122. "\x31\x32\x33\x34\x35\x36\x37\x38"
  13123. "\x39\x3a\x3b\x3c\x3d\x3e\x3f\x40"
  13124. "\x41\x42\x43\x44\x45\x46\x47\x48"
  13125. "\x49\x4a\x4b\x4c\x4d\x4e\x4f\x50",
  13126. .psize = 40,
  13127. .digest = "\xf6\xeb\x80\xe9",
  13128. },
  13129. {
  13130. .key = "\xff\xff\xff\xff",
  13131. .ksize = 4,
  13132. .plaintext = "\x51\x52\x53\x54\x55\x56\x57\x58"
  13133. "\x59\x5a\x5b\x5c\x5d\x5e\x5f\x60"
  13134. "\x61\x62\x63\x64\x65\x66\x67\x68"
  13135. "\x69\x6a\x6b\x6c\x6d\x6e\x6f\x70"
  13136. "\x71\x72\x73\x74\x75\x76\x77\x78",
  13137. .psize = 40,
  13138. .digest = "\xed\xbd\x74\xde",
  13139. },
  13140. {
  13141. .key = "\xff\xff\xff\xff",
  13142. .ksize = 4,
  13143. .plaintext = "\x79\x7a\x7b\x7c\x7d\x7e\x7f\x80"
  13144. "\x81\x82\x83\x84\x85\x86\x87\x88"
  13145. "\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90"
  13146. "\x91\x92\x93\x94\x95\x96\x97\x98"
  13147. "\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0",
  13148. .psize = 40,
  13149. .digest = "\x62\xc8\x79\xd5",
  13150. },
  13151. {
  13152. .key = "\xff\xff\xff\xff",
  13153. .ksize = 4,
  13154. .plaintext = "\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8"
  13155. "\xa9\xaa\xab\xac\xad\xae\xaf\xb0"
  13156. "\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8"
  13157. "\xb9\xba\xbb\xbc\xbd\xbe\xbf\xc0"
  13158. "\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8",
  13159. .psize = 40,
  13160. .digest = "\xd0\x9a\x97\xba",
  13161. },
  13162. {
  13163. .key = "\xff\xff\xff\xff",
  13164. .ksize = 4,
  13165. .plaintext = "\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0"
  13166. "\xd1\xd2\xd3\xd4\xd5\xd6\xd7\xd8"
  13167. "\xd9\xda\xdb\xdc\xdd\xde\xdf\xe0"
  13168. "\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8"
  13169. "\xe9\xea\xeb\xec\xed\xee\xef\xf0",
  13170. .psize = 40,
  13171. .digest = "\x13\xd9\x29\x2b",
  13172. },
  13173. {
  13174. .key = "\x80\xea\xd3\xf1",
  13175. .ksize = 4,
  13176. .plaintext = "\x29\x2a\x2b\x2c\x2d\x2e\x2f\x30"
  13177. "\x31\x32\x33\x34\x35\x36\x37\x38"
  13178. "\x39\x3a\x3b\x3c\x3d\x3e\x3f\x40"
  13179. "\x41\x42\x43\x44\x45\x46\x47\x48"
  13180. "\x49\x4a\x4b\x4c\x4d\x4e\x4f\x50",
  13181. .psize = 40,
  13182. .digest = "\x0c\xb5\xe2\xa2",
  13183. },
  13184. {
  13185. .key = "\xf3\x4a\x1d\x5d",
  13186. .ksize = 4,
  13187. .plaintext = "\x51\x52\x53\x54\x55\x56\x57\x58"
  13188. "\x59\x5a\x5b\x5c\x5d\x5e\x5f\x60"
  13189. "\x61\x62\x63\x64\x65\x66\x67\x68"
  13190. "\x69\x6a\x6b\x6c\x6d\x6e\x6f\x70"
  13191. "\x71\x72\x73\x74\x75\x76\x77\x78",
  13192. .psize = 40,
  13193. .digest = "\xd1\x7f\xfb\xa6",
  13194. },
  13195. {
  13196. .key = "\x2e\x80\x04\x59",
  13197. .ksize = 4,
  13198. .plaintext = "\x79\x7a\x7b\x7c\x7d\x7e\x7f\x80"
  13199. "\x81\x82\x83\x84\x85\x86\x87\x88"
  13200. "\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90"
  13201. "\x91\x92\x93\x94\x95\x96\x97\x98"
  13202. "\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0",
  13203. .psize = 40,
  13204. .digest = "\x59\x33\xe6\x7a",
  13205. },
  13206. {
  13207. .key = "\xa6\xcc\x19\x85",
  13208. .ksize = 4,
  13209. .plaintext = "\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8"
  13210. "\xa9\xaa\xab\xac\xad\xae\xaf\xb0"
  13211. "\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8"
  13212. "\xb9\xba\xbb\xbc\xbd\xbe\xbf\xc0"
  13213. "\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8",
  13214. .psize = 40,
  13215. .digest = "\xbe\x03\x01\xd2",
  13216. },
  13217. {
  13218. .key = "\x41\xfc\xfe\x2d",
  13219. .ksize = 4,
  13220. .plaintext = "\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0"
  13221. "\xd1\xd2\xd3\xd4\xd5\xd6\xd7\xd8"
  13222. "\xd9\xda\xdb\xdc\xdd\xde\xdf\xe0"
  13223. "\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8"
  13224. "\xe9\xea\xeb\xec\xed\xee\xef\xf0",
  13225. .psize = 40,
  13226. .digest = "\x75\xd3\xc5\x24",
  13227. },
  13228. {
  13229. .key = "\xff\xff\xff\xff",
  13230. .ksize = 4,
  13231. .plaintext = "\x01\x02\x03\x04\x05\x06\x07\x08"
  13232. "\x09\x0a\x0b\x0c\x0d\x0e\x0f\x10"
  13233. "\x11\x12\x13\x14\x15\x16\x17\x18"
  13234. "\x19\x1a\x1b\x1c\x1d\x1e\x1f\x20"
  13235. "\x21\x22\x23\x24\x25\x26\x27\x28"
  13236. "\x29\x2a\x2b\x2c\x2d\x2e\x2f\x30"
  13237. "\x31\x32\x33\x34\x35\x36\x37\x38"
  13238. "\x39\x3a\x3b\x3c\x3d\x3e\x3f\x40"
  13239. "\x41\x42\x43\x44\x45\x46\x47\x48"
  13240. "\x49\x4a\x4b\x4c\x4d\x4e\x4f\x50"
  13241. "\x51\x52\x53\x54\x55\x56\x57\x58"
  13242. "\x59\x5a\x5b\x5c\x5d\x5e\x5f\x60"
  13243. "\x61\x62\x63\x64\x65\x66\x67\x68"
  13244. "\x69\x6a\x6b\x6c\x6d\x6e\x6f\x70"
  13245. "\x71\x72\x73\x74\x75\x76\x77\x78"
  13246. "\x79\x7a\x7b\x7c\x7d\x7e\x7f\x80"
  13247. "\x81\x82\x83\x84\x85\x86\x87\x88"
  13248. "\x89\x8a\x8b\x8c\x8d\x8e\x8f\x90"
  13249. "\x91\x92\x93\x94\x95\x96\x97\x98"
  13250. "\x99\x9a\x9b\x9c\x9d\x9e\x9f\xa0"
  13251. "\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8"
  13252. "\xa9\xaa\xab\xac\xad\xae\xaf\xb0"
  13253. "\xb1\xb2\xb3\xb4\xb5\xb6\xb7\xb8"
  13254. "\xb9\xba\xbb\xbc\xbd\xbe\xbf\xc0"
  13255. "\xc1\xc2\xc3\xc4\xc5\xc6\xc7\xc8"
  13256. "\xc9\xca\xcb\xcc\xcd\xce\xcf\xd0"
  13257. "\xd1\xd2\xd3\xd4\xd5\xd6\xd7\xd8"
  13258. "\xd9\xda\xdb\xdc\xdd\xde\xdf\xe0"
  13259. "\xe1\xe2\xe3\xe4\xe5\xe6\xe7\xe8"
  13260. "\xe9\xea\xeb\xec\xed\xee\xef\xf0",
  13261. .psize = 240,
  13262. .digest = "\x75\xd3\xc5\x24",
  13263. .np = 2,
  13264. .tap = { 31, 209 }
  13265. },
  13266. };
  13267. #endif /* _CRYPTO_TESTMGR_H */