Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Crypt::Navajo

by Cybercosis (Monk)
on Jan 17, 2003 at 03:45 UTC ( #227633=sourcecode: print w/replies, xml ) Need Help??
Category: Cryptography
Author/Contact Info Cybercosis cybercosis@antisocial.com
Description: This module implements the code that was devised and used by the Navajo Code Talkers in the Pacific theater of WWII. The Code was instrumental to the Allied victory there.
#Crypt::Navajo -- Navajo Code Talkers Encryption
#Copyright (c) 2002, Michael J. Iatauro.  All rights reserved.
#This code is free software; you can redistribute it and/or modify it 
+under the
#same terms as Perl itself.

package Crypt::Navajo;

use warnings qw/all/;
use strict;

our $VERSION = '1.0';

use Exporter;
@Crypt::Navajo::ISA = qw/Exporter/;
@Crypt::Navajo::EXPORT_OK = qw/encrypt decrypt/;

my %CALPHA = ('A' => ['WOL-LA-CHEE', 'BE-LA-SANA', 'TSE-NILL'],
          'B' => ['NA-HASH-CHID', 'SHUSH', 'TOISH-JEH'],
          'C' => ['MOASI', 'TLA-GIN', 'BA-GOSHI'],
          'D' => ['BE', 'CHINDI', 'LHA-CHA-EH'],
          'E' => ['AH-JAH', 'DZEH', 'AH-NAH'],
          'F' => ['CHUO', 'TSA-E-DONIN-EE', 'MA-E'],
          'G' => ['AH-TAD', 'KLIZZIE', 'JEHA'],
          'H' => ['TSE-GAH', 'CHA', 'LIN'],
          'I' => ['TKIN', 'YEH-HES', 'A-CHI'],
          'J' => ['TKELE-CHO-G', 'AH-YA-TSINNE', 'YIL-DOI'],
          'K' => ['JAD-HO-LONI', 'BA-AH-NE-DI-TININ', 'KLIZZIE-YAZZIE'
+],
          'L' => ['DIBEH-YAZZIE', 'AH-JAD', 'NASH-DOIE-TSO'],
          'M' => ['TSIN-TLITI', 'BE-TAS-TNI', 'NA-AS-TSO-SI'],
          'N' => ['TSAH', 'A-CHIN'],
          'O' => ['A-KHA', 'TLO-CHIN', 'NE-AHS-JAH'],
          'P' => ['CLA-GI-AIH', 'BI-SO-DIH', 'NE-ZHONI'],
          'Q' => ['CA-YEILTH'],
          'R' => ['GAH', 'DAH-NES-TSA', 'AH-LOSZ'],
          'S' => ['DIBEH', 'KLESH'],
          'T' => ['D-AH', 'A-WOH', 'THAN-ZIE'],
          'U' => ['SHI-DA', 'NO-DA-IH'],
          'V' => ['A-KEH-KI-GLINI'],
          'W' => ['GLOE-IH'],
          'X' => ['AL-NA-AS-DZOH'],
          'Y' => ['TSAH-AS-ZIH'],
          'Z' => ['BESH-DO-TLIZ']);

my %DALPHA = ('WOL-LA-CHEE' => 'A',
          'BE-LA-SANA' => 'A',
          'TSE-NILL' => 'A',
          'NA-HASH-CHID' => 'B',
          'SHUSH' => 'B',
          'TOISH-JEH' => 'B',
          'MOASI' => 'C',
          'TLA-GIN' => 'C',
          'BA-GOSHI' => 'C',
          'BE' => 'D',
          'CHINDI' => 'D',
          'LHA-CHA-EH' => 'D',
          'AH-JAH' => 'E',
          'DZEH' => 'E',
          'AH-NAH' => 'E',
          'CHUO' => 'F',
          'TSA-E-DONIN-EE' => 'F',
          'MA-E' => 'F',
          'AH-TAD' => 'G',
          'KLIZZIE' => 'G',
          'JEHA' => 'G',
          'TSE-GAH' => 'H',
          'CHA' => 'H',
          'LIN' => 'H',
          'TKIN' => 'I',
          'YEH-HES' => 'I',
          'A-CHI' => 'I',
          'TKELE-CHO-G' => 'J',
          'AH-YA-TSINNE' => 'J',
          'YIL-DOI' => 'J',
          'JAD-HO-LONI' => 'K',
          'BA-AH-NE-DI-TININ' => 'K',
          'KLIZZIE-YAZZIE' => 'K',
          'DIBEH-YAZZIE' => 'L',
          'AH-JAD' => 'L',
          'NASH-DOIE-TSO' => 'L',
          'TSIN-TLITI' => 'M',
          'BE-TAS-TNI' => 'M',
          'NA-AS-TSO-SI' => 'M',
          'TSAH' => 'N',
          'A-CHIN' => 'N',
          'A-KHA' => 'O',
          'TLO-CHIN' => 'O',
          'NE-AHS-JAH' => 'O',
          'CLA-GI-AIH' => 'P',
          'BI-SO-DIH' => 'P',
          'NE-ZHONI' => 'P',
          'CA-YEILTH' => 'Q',
          'GAH' => 'R',
          'DAH-NES-TSA' => 'R',
          'AH-LOSZ' => 'R',
          'DIBEH' => 'S',
          'KLESH' => 'S',
          'D-AH' => 'T',
          'A-WOH' => 'T',
          'THAN-ZIE' => 'T',
          'SHI-DA' => 'U',
          'NO-DA-IH' => 'U',
          'A-KEH-KI-GLINI' => 'V',
          'GLOE-IH' => 'W',
          'AL-NA-AS-DZOH' => 'X',
          'TSAH-AS-ZIH' => 'Y',
          'BESH-DO-TLIZ' => 'Z');

my %CDICT = ('CORPS' => 'DIN-NEH-IH',
         'DIVISION' => 'ASHIH-HI',
         'REGIMENT' => 'TABAHA',
         'BATTALION' => 'TACHEENE',
         'COMPANY' => 'NAKIA',
         'PLATOON' => 'HAS-CLISH-NIH',
         'SECTION' => 'YO-IH',
         'SQUAD' => 'DEBEH-LI-ZINI',
         'COMMANDING GENERAL' => 'BIH-KEH-HE',
         'MAJOR GENERAL' => 'SO-NA-KIH',
         'BIRGADIER GENERAL' => 'SO-A-LA-IH',
         'COLONEL' => 'ATSAH-BESH-LE-GAI',
         'LIEUTENANT COLONEL' => 'CHE-CHIL-BE-TAH-BESH-LEGAI',
         'MAJOR' => 'CHE-CHIL-BE-TAH-OLA',
         'CAPTAIN' => 'BESH-LEGAI-NAH-KIH',
         'LIEUTENANT' => 'BESH-LEGAI-A-LAH-IH',
         'COMMANDING OFFICER' => 'HASH-KAY-GI-NA-TAH',
         'EXECUTIVE OFFICER' => 'BIH-DA-HOL-NEHI',
         'AFRICA' => 'ZHIN-NI',
         'ALASKA' => 'BEH-HGA',
         'AMERICA' => 'NE-HE-MAH',
         'AUSTRALIA' => 'CHA-YES-DESI',
         'BRITAIN' => 'TOH-TA',
         'CHINA' => 'CEH-YEHS-BESI',
         'FRANCE' => 'DA-GHA-HI',
         'GERMANY' => 'BESH-BE-CHA-HE',
         'ICELAND' => 'TKIN-KE-YAH',
         'INDIA' => 'AH-LE-GAI',
         'ITALY' => 'DOH-HA-CHI-YALI-TCHI',
         'JAPAN' => 'BEH-NA-ALI-TSOSIE',
         'PHILIPPINE' => 'KE-YAH-DA-NA-LHE',
         'RUSSIA' => 'SILA-GOL-CHI-IH',
         'SOUTH AMERICA' => 'SHA-DE-AH-NE-HI-MAH',
         'SPAIN' => 'DEBA-DE-NIH',
         'PLANES' => 'WO-TAH-DE-NE-IH',
         'DIVE BOMBER' => 'GINI',
         'TORPEDO PLANE' => 'TAS-CHIZZIE',
         'OBS. PLANE' => 'NE-AS-JAH',
         'FIGHTER PLANE' => 'DA-HE-TIH-HI',
         'BOMBER PLANE' => 'JAY-SHO',
         'PATROL PLANE' => 'GA-GIH',
         'TRANSPORT PLANE' => 'ATSAH',
         'SHIPS' => 'TOH-DINEH-IH',
         'BATTLESHIP' => 'LO-TSO',
         'AIRCRAFT' => 'TSINI-MOFFA-YE-HI',
         'SUBMARINE' => 'BESH-LO',
         'MINE SWEEPER' => 'CHA',
         'DESTROYER' => 'CHA-LO',
         'TRANSPORT SHIP' => 'DINEH-NAY-YE-HI',
         'CRUISER' => 'LO-TSO-YAZZIE',
         'MOSQUITO BOAT' => 'TSE-E',
         'JANUARY' => 'ATSAH-BE-YAZ',
         'FEBRUARY' => 'WOZ-CHEIND',
         'MARCH' => 'TAH-CHILL',
         'APRIL' => 'TAH-TSO',
         'MAY' => 'TAH-TSOSIE',
         'JUNE' => 'BE-NE-EH-EH-JAH-TSO',
         'JULY' => 'BE-NE-TA-TSOSIE',
         'AUGUST' => 'BE-NEEN-TA-TSO',
         'SEPTEMBER' => 'GHAW-JIH',
         'OCTOBER' => 'NIL-CHI-TSOSIE',
         'NOVEMBER' => 'NIL-CHI-TSO',
         'DECEMBER' => 'YAS-NIL-TES',
         'ABANDON' => 'YE-TSAN',
         'ABOUT' => 'WOLA-CHI-A-MOFFA-GAHN',
         'ABREAST' => 'WOLA-CHEE-BE-YIED',
         'ACCOMPLISH' => 'UL-SO',
         'ACCORDING' => 'BE-KA-HO',
         'ACKNOWLEDGE' => 'HANOT-DZIED',
         'ACTION' => 'AH-HA-TINH',
         'ACTIVITY' => 'AH-HA-TINH-Y',
         'ADEQUATE' => 'BEH-GHA',
         'ADDITION' => 'IH-HE-DE-NDEL',
         'ADDRESS' => 'YI-CHIN-HA-TSE',
         'ADJACENT' => 'BE-GAHI',
         'ADJUST' => 'HAS-TAI-NEL-KAD',
         'ADVANCE' => 'NAS-SEY',
         'ADVISE' => 'NA-NETIN',
         'AERIAL' => 'BE-ZONZ',
         'AFFIRMATIVE' => 'LANH',
         'AFTER' => 'BI-KHA-DI',
         'AGAINST' => 'BE-NA-GNISH',
         'AID' => 'EDA-ELE-TSOOD',
         'AIR' => 'NILCHI',
         'AIRDOME' => 'NILCHI-BEGHAN',
         'ALERT' => 'HA-IH-DES-EE',
         'ALL' => 'TA-A-TAH',
         'ALLIES' => 'NIH-HI-CHO',
         'ALONG' => 'WOLACHEE-SNEZ',
         'ALSO' => 'EH-DO',
         'ALTERNATE' => 'NA-KEE-GO-NE-NAN-DEY-HE',
         'AMBUSH' => 'KHAC-DA',
         'AMMUNITION' => 'BEH-ELI-DOH-BE-CAH-ALI-TAS-AI',
         'AMPHIBIOUS' => 'CHAL',
         'AND' => 'DO',
         'ANGLE' => 'DEE-CAHN',
         'ANNEX' => 'IH-NAY-TANI',
         'ANNOUNCE' => 'BEH-HA-O-DZE',
         'ANTI' => 'WOL-LA-CHEE-TSIN',
         'ANTICIPATE' => 'NI-JOL-LIH',
         'ANY' => 'TAH-HA-DAH',
         'APPEAR' => 'YE-KA-HA-YA',
         'APPROACH' => 'BI-CHI-OL-DAH',
         'APPROXIMATE' => 'TO-KUS-DAN',
         'ARE' => 'GAH-TSO-BIG',
         'AREA' => 'HAZ-A-GIH',
         'ARMOR' => 'BESH-YE-HA-DA-DI-TEH',
         'ARMY' => 'LEI-CHA-IH-YIL-KNEE-IH',
         'ARRIVE' => 'IL-DAY',
         'ARTILLERY' => 'BE-AL-DOH-TSO-LANI',
         'AS' => 'AHCE',
         'ASSAULT' => 'ALTSEH-E-JAH-HE',
         'ASSEMBLE' => 'DE-JI-KASH',
         'ASSIGN' => 'BAH-DEH-TAHN',
         'AT' => 'AH-DI',
         'ATTACK' => 'AL-TAH-JE-JAY',
         'ATTEMPT' => 'BO-O-NE-TAH',
         'ATTENTION' => 'GIHA',
         'AUTHENTICATOR' => 'HANI-BA-AH-HO-ZIN',
         'AUTHORIZE' => 'BE-BO-HO-SNEE',
         'AVAILABLE' => 'TA-SHOZ-TEH-IH',
         'BAGGAGE' => 'KLAILH',
         'BANZAI' => 'NE-TAH',
         'BARGE' => 'BESH-NA-ELT',
         'BARRAGE' => 'BESH-BA-WA-CHIND',
         'BARRIER' => 'BIH-CHAN-NI-AH',
         'BASE' => 'BIH-TSEE-DIH',
         'BATTERY' => 'BIH-BE-AL-DOH-TKA-IH',
         'BATTLE' => 'DA-AH-HI-DZI-TSIO',
         'BAY' => 'TOH-AH-HI-GHINH',
         'BAZOOKA' => 'AH-ZHOL',
         'BE' => 'TSES-NAH',
         'BEACH' => 'TAH-BAHN',
         'BEEN' => 'TSES-NAH-NES-CHEE',
         'BEFORE' => 'BIH-TSE-DIH',
         'BEGIN' => 'HA-HOL-ZIZ',
         'BELONG' => 'TSES-NAH-SNEZ',
         'BETWEEN' => 'BI-TAH-KIZ',
         'BEYOND' => 'BILH-LA',
         'BIVOUAC' => 'EHL-NAS-TEH',
         'BOMB' => 'A-YE-SHI',
         'BOOBY' => 'TRAP',
         'BORNE' => 'YE-CHIE-TSAH',
         'BOUNDARY' => 'KA-YAH-BI-NA-HAS-DZOH',
         'BULL' => 'DOZER',
         'BUNKER' => 'TSAS-KA',
         'BUT' => 'NEH-DIH',
         'BY' => 'BE-GHA',
         'CABLE' => 'BESH-LKOH',
         'CALIBER' => 'NAHL-KIHD',
         'CAMP' => 'TO-ALTSEH-HOGAN',
         'CAMOUFLAGE' => 'DI-NES-IH',
         'CAN' => 'YAH-DI-ZINI',
         'CANNONEER' => 'BE-AL-DOH-TSO-DEY-DIL-DON-IGI',
         'CAPACITY' => 'BE-NEL-AH',
         'CAPTURE' => 'YIS-NAH',
         'CARRY' => 'YO-LAILH',
         'CASE' => 'BIT-SAH',
         'CASUALTY' => 'BIH-DIN-NE-DEY',
         'CAUSE' => 'BI-NIH-NANI',
         'CAVE' => 'TSA-OND',
         'CEILING' => 'DA-TEL-JAY',
         'CEMETARY' => 'JISH-CHA',
         'CENTER' => 'ULH-NE-IH',
         'CHANGE' => 'THLA-GO-A-NAT-ZAH',
         'CHANNEL' => 'HA-TALHI-YAZZIE',
         'CHARGE' => 'AH-TAH-GI-JAH',
         'CHEMICAL' => 'TA-NEE',
         'CIRCLE' => 'NAS-PAS',
         'CIRCUIT' => 'AH-HEH-HA-DAILH',
         'CLASS' => 'ALTH-AH-A-TEH',
         'CLEAR' => 'YO-AH-HOL-ZHOD',
         'CLIFF' => 'TSE-YE-CHEE',
         'CLOSE' => 'UL-CHI-UH-NAL-YAH',
         'COAST' => 'GUARD',
         'CODE' => 'YIL-TAS',
         'COLON' => 'NAKI-ALH--DEH-DA-AL-ZHIN',
         'COLUMN' => 'ALTH-KAY-NE-ZIH',
         'COMBAT' => 'DA-AH-HI-JIH-GANH',
         'COMBINATION' => 'AL-TKAS-EI',
         'COME' => 'HUC-QUO',
         'COMMA' => 'TSA-NA-DAHL',
         'COMMERCIAL' => 'NAI-EL-NE-HI',
         'COMMIT' => 'HUC-QUO-LA-JISH',
         'COMMUNICATION' => 'HA-NEH-AL-ENJI',
         'CONCEAL' => 'BE-KI-ASZ-JOLE',
         'CONCENTRATION' => 'TA-LA-HI-JIH',
         'CONCUSSION' => 'WHE-HUS-DIL',
         'CONDITION' => 'AH-HO-TAI',
         'CONFERENCE' => 'BE-KE-YA-TI',
         'CONFIDENTIAL' => 'NA-NIL-IN',
         'CONFIRM' => 'TA-A-NEH',
         'CONQUER' => 'A-KEH-DES-DLIN',
         'CONSIDER' => 'NE-TSA-CAS',
         'CONSIST' => 'BILH',
         'CONSOLIDATE' => 'AH-HIH-HI-NIL',
         'CONSTRUCT' => 'AHL-NEH',
         'CONTACT' => 'AH-HI-DI-DAIL',
         'CONTINUE' => 'TA-YI-TEH',
         'CONTROL' => 'NAI-GHIZ',
         'CONVOY' => 'TKAL-KAH-O-NEL',
         'COORDINATE' => 'BEH-EH-HO-ZIN-NA-AS-DZOH',
         'COUNTER' => 'ATTACK',
         'COURSE' => 'CO-JI-GOH',
         'CRAFT' => 'AH-TOH',
         'CREEK' => 'TOH-NIL-TSANH',
         'CROSS' => 'AL-N-AS-DZOH',
         'CUB' => 'SHUSH-YAHZ',
         'DASH' => 'US-DZOH',
         'DAWN' => 'HA-YELI-KAHN',
         'DEFENSE' => 'AH-KIN-CIL-TOH',
         'DEGREE' => 'NAHL-KIHD',
         'DELAY' => 'BE-SITIHN',
         'DELIVER' => 'BE-BIH-ZIHDE',
         'DEMOLITION' => 'AH-DEEL-TAHI',
         'DENSE' => 'HO-DILH-CLA',
         'DEPART' => 'DA-DE-YAH',
         'DEPARTMENT' => 'HOGAN',
         'DESIGNATE' => 'YE-KHI-DEL-NEI',
         'DESPERATE' => 'AH-DA-AH-HO-DZAH',
         'DETACH' => 'AL-CHA-NIL',
         'DETAIL' => 'BE-BEH-SHA',
         'DETONATOR' => 'AH-DEEL-TAHI',
         'DIFFICULT' => 'NA-NE-KLAH',
         'DIG' => 'IN',
         'DIRECT' => 'AH-JI-GO',
         'DISEMBARK' => 'EH-HA-JAY',
         'DISPATCH' => 'LA-CHAI-EN-SEIS-BE-JAY',
         'DISPLACE' => 'HIH-DO-NAL',
         'DISPLAY' => 'BE-SEIS-NA-NEH',
         'DISPOSITION' => 'A-HO-TEY',
         'DISTRIBUTE' => 'NAH-NEH',
         'DISTRICT' => 'BE-THIN-YA-NI-CHE',
         'DO' => 'TSE-LE',
         'DOCUMENT' => 'BEH-EH-HO-ZINZ',
         'DRIVE' => 'AH-NOL-KAHL',
         'DUD' => 'DI-GISS-YAHZIE',
         'DUMMY' => 'DI-GISS-TSO',
         'EACH' => 'TA-LAHI-NE-ZINI-GO',
         'ECHELON' => 'WHO-DZAH',
         'EDGE' => 'BE-BA-HI',
         'EFFECTIVE' => 'BE-DELH-NEED',
         'EFFORT' => 'YEA-GO',
         'ELEMENT' => 'AH-NA-NAI',
         'ELEVATE' => 'ALI-KHI-HO-NE-OHA',
         'ELIMINATE' => 'HA-BEH-TO-DZIL',
         'EMBARK' => 'EH-HO-JAY',
         'EMERGENCY' => 'HO-NEZ-CLA',
         'EMPLACEMENT' => 'LA-AZ-NIL',
         'ENCIRCLE' => 'YE-NAS-TEH',
         'ENCOUNTER' => 'BI-KHANH',
         'ENGAGE' => 'A-HA-NE-HO-TA',
         'ENGINE' => 'CHIDI-BI-TSI-TSINE',
         'ENGINEER' => 'DAY-DIL-JAH-HE',
         'ENLARGE' => 'NIH-TSA-GOH-AL-NEH',
         'ENLIST' => 'BIH-ZIH-A-DA-YI-LAH',
         'ENTIRE' => 'TA-A-TAH',
         'ENTRENCH' => 'E-GAD-AH-NE-LIH',
         'ENVELOP' => 'A-ZAH-GI-YA',
         'EQUIPMENT' => 'YA-HA-DE-TAHI',
         'ERECT' => 'YEH-ZIHN',
         'ESCAPE' => 'A-ZEH-HA-GE-YAH',
         'ESTABLISH' => 'HAS-TAY-DZAH',
         'ESTIMATE' => 'BIH-KE-TSE-HOD-DES-KEZ',
         'EVACUATE' => 'HA-NA',
         'EXCEPT' => 'NEH-DIH',
         'EXCEPT' => 'NA-WOL-NE',
         'EXCHANGE' => 'ALH-NAHL-YAH',
         'EXECUTE' => 'A-DO-NIL',
         'EXPLOSIVE' => 'AH-DEL-TAHI',
         'EXPEDITE' => 'SHIL-LOH',
         'EXTEND' => 'NE-TDALE',
         'EXTREME' => 'AL-TSAN-AH-BAHM',
         'FAIL' => 'CHA-AL-EIND',
         'FAILURE' => 'YEES-GHIN',
         'FARM' => 'MAI-BE-HE-AHGAN',
         'FEED' => 'DZEH-CHI-YON',
         'FIELD' => 'CLO-DIH',
         'FIERCE' => 'TOH-BAH-HA-ZSID',
         'FILE' => 'BA-EH-CHEZ',
         'FINAL' => 'TAH-AH-KWO-DIH',
         'FLAME' => 'THROWER',
         'FLANK' => 'DAH-DI-KAD',
         'FLARE' => 'WO-CHI',
         'FLIGHT' => 'MA-E-AS-ZLOLI',
         'FORCE' => 'TA-NA-NE-LADI',
         'FORM' => 'BE-CHA',
         'FORMATION' => 'BE-CHA-YE-LAILH',
         'FORTIFICATION' => 'AH-NA-SOZI',
         'FORTIFY' => 'AH-NA-SOZI-YAZZIE',
         'FORWARD' => 'TEHI',
         'FRAGMENTATION' => 'BESH-YAZZIE',
         'FREQUENCY' => 'HA-TALHI-TSO',
         'FRIENDLY' => 'NEH-HECHO-DA-NE',
         'FROM' => 'BI-TSAN-DEHN',
         'FURNISH' => 'YEAS-NIL',
         'FURTHER' => 'WO-NAS-DI',
         'GARRISON' => 'YAH-A-DA-HAL-YON-IH',
         'GASOLINE' => 'CHIDI-BI-TOH',
         'GRENADE' => 'NI-MA-SI',
         'GUARD' => 'NI-DIH-DA-HI',
         'GUIDE' => 'NAH-E-THLAI',
         'HALL' => 'LHI-TA-A-TA',
         'HALF' => 'TRACK',
         'HALT' => 'TA-AKWAI-I',
         'HANDLE' => 'BET-SEEN',
         'HAVE' => 'JO',
         'HEADQUARTER' => 'NA-HA-TAH-TA-BA-HOGAN',
         'HELD' => 'WO-TAH-TA-EH-DAHN-OH',
         'HIGH' => 'WO-TAH',
         'HIGH' => 'EXPLOSIVE',
         'HIGHWAY' => 'WO-TAH-HO-NE-TEH',
         'HOLD' => 'WO-TKANH',
         'HOSPITAL' => 'A-ZEY-AL-IH',
         'HOSTILE' => 'A-NAH-NE-DZIN',
         'HOWITZER' => 'BE-EL-DON-TS-QUODI',
         'ILLUMINATE' => 'WO-CHI',
         'IMMEDIATELY' => 'SHIL-LOH',
         'IMPACT' => 'A-HE-DIS-GOH',
         'IMPORTANT' => 'BA-HAS-TEH',
         'IMPROVE' => 'HO-DOL-ZHOND',
         'INCLUDE' => 'EL-TSOD',
         'INCREASE' => 'HO-NALH',
         'INDICATE' => 'BA-HAL-NEH',
         'INFANTRY' => 'TA-NEH-NAL-DAHI',
         'INFILTRATE' => 'YE-GHA-NE-JEH',
         'INITIAL' => 'BEH-ED-DE-DLID',
         'INSTALL' => 'EHD-TNAH',
         'INSTALLATION' => 'NAS-NIL',
         'INSTRUCT' => 'NA-NE-TGIN',
         'INTELLIGENCE' => 'HO-YA',
         'INTENSE' => 'DZEEL',
         'INTERCEPT' => 'YEL-NA-ME-JAH',
         'INTERFERE' => 'AH-NILH-KHLAI',
         'INTERPRET' => 'AH-TAH-HA-NE',
         'INVESTIGATE' => 'NA-ALI-KA',
         'INVOLVE' => 'A-TAH',
         'IS' => 'SEIS',
         'ISLAND' => 'SEIS-KEYAH',
         'ISOLATE' => 'BIH-TSA-NEL-KAD',
         'JUNGLE' => 'WOH-DI-CHIL',
         'KILL' => 'NAZ-TSAID',
         'KILOCYCLE' => 'NAS-TSAID-A-KHA-AH-YEH-',
         'LABOR' => 'NA-NISH',
         'LAND' => 'KAY-YAH',
         'LAUNCH' => 'TKA-GHIL-ZHOD',
         'LEADER' => 'AH-NA-GHAI',
         'LEAST' => 'DE-BE-YAZIE-HA-A-AH',
         'LEAVE' => 'DAH-DE-YAH',
         'LEFT' => 'NISH-CLA-JIH-GOH',
         'LESS' => 'BI-OH',
         'LEVEL' => 'DIL-KONH',
         'LIAISON' => 'DA-A-HE-GI-ENEH',
         'LIMIT' => 'BA-HAS-AH',
         'LITTER' => 'NI-DAS-TON',
         'LOCATE' => 'A-KWE-EH',
         'LOSS' => 'UT-DIN',
         'MACHINE' => 'GUN',
         'MAGNETIC' => 'NA-E-LAHI',
         'MANAGE' => 'HASTNI-BEH-NA-HAI',
         'MANEUVER' => 'NA-NA-O-NALTH',
         'MAP' => 'KAH-YA-NESH-CHAI',
         'MAXIMUM' => 'BEL-DIL-KHON',
         'MECHANIC' => 'CHITI-A-NAYL-INIH',
         'MECHANIZED' => 'CHIDI-DA-AH-HE-GONI',
         'MEDICAL' => 'A-ZAY',
         'MEGACYCLE' => 'MIL-AH-HEH-AH-DILH',
         'MERCHANT' => 'SHIP',
         'MESSAGE' => 'HANE-AL-NEH',
         'MILITARY' => 'SILAGO-KEH-GOH',
         'MILLIMETER' => 'NA-AS-TSO-SI-A-YE-DO-TISH',
         'MINE' => 'HA-GADE',
         'MINIMUM' => 'BE-OH',
         'MINUTE' => 'AH-KHAY-EL-KIT-YAZZIE',
         'MISSION' => 'AL-NESHODI',
         'MISTAKE' => 'O-ZHI',
         'MOPPING' => 'HA-TAO-DI',
         'MORE' => 'THLA-NA-NAH',
         'MORTAR' => 'BE-AL-DOH-CID-DA-HI',
         'MOTION' => 'NA-HOT-NAH',
         'MOTOR' => 'CHIDE-BE-TSE-TSEN',
         'NATIVE' => 'KA-HA-TENI',
         'NAVY' => 'TAL-KAH-SILAGO',
         'NECESSARY' => 'YE-NA-ZEHN',
         'NEGATIVE' => 'DO-YA-SHO-DA',
         'NET' => 'NA-NES-DIZI',
         'NEUTRAL' => 'DO-NEH-LINI',
         'NORMAL' => 'DOH-A-TA-H-DAH',
         'NOT' => 'NI-DAH-THAN-ZIE',
         'NOTICE' => 'NE-DA-TAZI-THIN',
         'NOW' => 'KUT',
         'NUMBER' => 'BEH-BIH-KE-AS-CHINIGH',
         'OBJECTIVE' => 'BI-NE-YEI',
         'OBSERVE' => 'HAL-ZID',
         'OBSTACLE' => 'DA-HO-DESH-ZHA',
         'OCCUPY' => 'YEEL-TSOD',
         'OF' => 'TOH-NI-TKAL-LO',
         'OFFENSIVE' => 'BIN-KIE-JINH-JIH-DEZ-JAY',
         'ONCE' => 'TA-LAI-DI',
         'ONLY' => 'TA-EI-TAY-A-YAH',
         'OPERATE' => 'YE-NAHL-NISH',
         'OPPORTUNITY' => 'ASH-GA-ALIN',
         'OPPOSITION' => 'NE-HE-TSAH-JIH-SHIN',
         'OR' => 'EH-DO-DAH-GOH',
         'ORANGE' => 'TCHIL-LHE-SOI',
         'ORDER' => 'BE-EH-HO-ZINI',
         'ORDNANCE' => 'LEI-AZ-JAH',
         'ORIGINATE' => 'DAS-TEH-DO',
         'OTHER' => 'LA-E-CIH',
         'OUT' => 'CLO-DIH',
         'OVERLAY' => 'BE-KA-HAS-TSOZ',
         'PARENTHESIS' => 'ATSANH',
         'PARTICULAR' => 'A-YO-AD-DO-NEH',
         'PARTY' => 'DA-SHA-JAH',
         'PAY' => 'NA-ELI-YA',
         'PENALIZE' => 'TAH-NI-DES-TANH',
         'PERCENT' => 'YAL',
         'PERIOD' => 'DA-AHL-ZHIN',
         'PERIODIC' => 'DA-AL-ZHIN-THIN-MOASI',
         'PERMIT' => 'GOS-SHI-E',
         'PERSONNEL' => 'DA-NE-LEI',
         'PHOTOGRAPH' => 'BEH-CHI-MA-HAD-NIL',
         'PILL' => 'BOX',
         'PINNED' => 'DOWN',
         'PLANE' => 'TSIDI',
         'PLASMA' => 'DIL-DI-GHILI',
         'POINT' => 'BE-SO-DE-DEZ-AHE',
         'PONTOON' => 'TKOSH-JAH-DA-NA-ELT',
         'POSITION' => 'BILH-HAS-AHN',
         'POSSIBLE' => 'TA-HA-AH-TAY',
         'POST' => 'SAH-DEI',
         'PREPARE' => 'HASH-TAY-HO-DIT-NE',
         'PRESENT' => 'KUT',
         'PREVIOUS' => 'BIH-TSE-DIH',
         'PRIMARY' => 'ALTSEH-NAN-DAY-HI-GIH',
         'PRIORITY' => 'HANE-PESODI',
         'PROBABLE' => 'DA-TSI',
         'PROBLEM' => 'NA-NISH-TSOH',
         'PROCEED' => 'NAY-NIH-JIH',
         'PROGRESS' => 'NAH-SAI',
         'PROTECT' => 'AH-CHANH',
         'PROVIDE' => 'YIS-NIL',
         'PURPLE' => 'DINL-CHI',
         'PYROTECHNIC' => 'COH-NA-CHANH',
         'QUESTION' => 'AH-JAH',
         'QUICK' => 'SHIL-LOH',
         'RADAR' => 'ESAT-TSANH',
         'RAID' => 'DEZJAY',
         'RAILHEAD' => 'A-DE-GEH-HI',
         'RAILROAD' => 'KONH-NA-AL-BANSI-BI-THIN',
         'RALLYING' => 'A-LAH-NA-O-GLALIH',
         'RANGE' => 'AN-ZAH',
         'RATE' => 'GAH-EH-YAHN',
         'RATION' => 'NA-A-JAH',
         'RAVINE' => 'CHUSH-KA',
         'REACH' => 'IL-DAY',
         'READY' => 'KUT',
         'REAR' => 'BE-KA-DENH',
         'RECEIPT' => 'SHOZ-TEH',
         'RECOMMEND' => 'CHE-HO-TAI-TAHN',
         'RECONNAISSANCE' => 'HA-A-CIDI',
         'RECONNOITER' => 'TA-HA-NE-AL-YA',
         'RECORD' => 'GAH-AH-NAH-KLOLI',
         'RED' => 'LI-CHI',
         'REEF' => 'TSA-ZHIN',
         'REEMBARK' => 'EH-NA-COH',
         'REFIRE' => 'NA-NA-COH',
         'REGULATE' => 'NA-YEL-N',
         'REINFORCE' => 'NAL-DZIL',
         'RELIEF' => 'AGANH-TOL-JAY',
         'RELIEVE' => 'NAH-JIH-CO-NAL-YA',
         'REORGANIZE' => 'HA-DIT-ZAH',
         'REPLACEMENT' => 'NI-NA-DO-NIL',
         'REPORT' => 'WHO-NEH',
         'REPRESENTATIVE' => 'TKA-NAZ-NILI',
         'REQUEST' => 'JO-KAYED-GOH',
         'RESERVE' => 'HESH-J-E',
         'RESTRICT' => 'BA-HO-CHINI',
         'RETIRE' => 'AH-HOS-TEEND',
         'RETREAT' => 'JI-DIN-NES-CHANH',
         'RETURN' => 'NA-DZAH',
         'REVEAL' => 'WHO-NEH',
         'REVERT' => 'NA-SI-YIZ',
         'REVETMENT' => 'BA-NAS-CLA',
         'RIDGE' => 'GAH-GHIL-KEID',
         'RIFLEMAN' => 'BE-AL-DO-HOSTEEN',
         'RIVER' => 'TOH-YIL-KAL',
         'ROBOT' => 'BOMB',
         'ROCKET' => 'LESZ-YIL-BESHI',
         'ROLL' => 'YEH-MAS',
         'ROUND' => 'NAZ-PAS',
         'ROUTE' => 'GAH-BIH-TKEEN',
         'RUNNER' => 'NIH-DZID-TEIH',
         'SABOTAGE' => 'A-TKEL-YAH',
         'SABOTEUR' => 'A-TKEL-EL-INI',
         'SAILOR' => 'CHA-LE-GAI',
         'SALVAGE' => 'NA-HAS-GLAH',
         'SAT' => 'BIH-LA-SANA-CID-DA-HI',
         'SCHEDULE' => 'BEH-EH-HO-ZINI',
         'SCOUT' => 'HA-A-SID-AL-SIZI-GIH',
         'SCREEN' => 'BESH-NA-NES-DIZI',
         'SEAMAN' => 'TKAL-KAH-DINEH-IH',
         'SECRET' => 'BAH-HAS-TKIH',
         'SECTOR' => 'YOEHI',
         'SECURE' => 'YE-DZHE-AL-TSISI',
         'SEIZE' => 'YEEL-STOD',
         'SELECT' => 'BE-TAH-HAS-GLA',
         'SEMI' => 'COLON',
         'SET' => 'DZEH-CID-DA-HI',
         'SHACKLE' => 'DI-BAH-NESH-GOHZ',
         'SHELL' => 'BE-AL-DOH-BE-CA',
         'SHORE' => 'TAH-BAHN',
         'SHORT' => 'BOSH-KEESH',
         'SIDE' => 'BOSH-KEESH',
         'SIGHT' => 'YE-EL-TSANH',
         'SIGNAL' => 'NA-EH-EH-GISH',
         'SIMPLEX' => 'ALAH-IH-NE-TIH',
         'SIT' => 'TKIN-CID-DA-HI',
         'SITUATE' => 'A-HO-TAY',
         'SMOKE' => 'LIT',
         'SNIPER' => 'OH-BEHI',
         'SPACE' => 'BE-TKAH',
         'SPECIAL' => 'E-YIH-SIH',
         'SPEED' => 'YO-ZONS',
         'SPORADIC' => 'AH-NA-HO-NEIL',
         'SPOTTER' => 'EEL-TSAY-I',
         'SPRAY' => 'KLESH-SO-DILZIN',
         'SQUADRON' => 'NAH-GHIZI',
         'STORM' => 'NE-OL',
         'STRAFF' => 'NA-WO-GHI-GOID',
         'STRAGGLER' => 'CHY-NE-DE-DAHE',
         'STRATEGY' => 'NA-HA-TAH',
         'STREAM' => 'TOH-NI-LIH',
         'STRENGTH' => 'DZHEL',
         'STRETCH' => 'DESZ-TSOOD',
         'STRIKE' => 'NAY-DAL-GHAL',
         'STRIP' => 'HA-TIH-JAH',
         'STUBBORN' => 'NIL-TA',
         'SUBJECT' => 'NA-NISH-YAZZIE',
         'SUBMERGE' => 'TKAL-CLA-YI-YAH',
         'SUBMIT' => 'A-NIH-LEH',
         'SUBORDINATE' => 'AL-KHI-NAL-DZL',
         'SUCCEED' => 'YAH-TAY-GO-E-ELAH',
         'SUCCESS' => 'UT-ZAH',
         'SUCCESSFUL' => 'UT-ZAH-HA-DEZ-BIN',
         'SUCCESSIVE' => 'UT-ZAH-SID',
         'SUCH' => 'YIS-CLEH',
         'SUFFER' => 'TO-HO-NE',
         'SUMMARY' => 'SHIN-GO-BAH',
         'SUPPLEMENTARY' => 'TKA-GO-NE-NAN-DEY-HE',
         'SUPPLY' => 'NAL-YEH-HI',
         'SUPPLY' => 'SHIP',
         'SUPPORT' => 'BA-AH-HOT-GLI',
         'SURRENDER' => 'NE-NA-CHA',
         'SURROUND' => 'NAZ-PAS',
         'SURVIVE' => 'YIS-DA-YA',
         'SYSTEM' => 'DI-BA-TSA-AS-ZHI-BI-TSIN',
         'TACTICAL' => 'E-CHIHN',
         'TAKE' => 'GAH-TAHN',
         'TANK' => 'CHAY-DA-GAHI',
         'TANK' => 'DESTROYER',
         'TARGET' => 'WOL-DONI',
         'TASK' => 'TAZI-NA-EH-DIL-KID',
         'TEAM' => 'DEH-NA-AS-TSO-SI',
         'TERRACE' => 'ALI-KHI-HO-NE-OHA',
         'TERRAIN' => 'TASHI-NA-HAL-THIN',
         'TERRITORY' => 'KA-YAH',
         'THAT' => 'TAZI-CHA',
         'THE' => 'CHA-GEE',
         'THEIR' => 'BIH',
         'THEREAFTER' => 'TA-ZI-KWA-I-BE-KA-DI',
         'THESE' => 'CHA-GI-O-EH',
         'THEY' => 'CHA-GEE',
         'THIS' => 'DI',
         'TOGETHER' => 'TA-BILH',
         'TORPEDO' => 'LO-BE-CA',
         'TOTAL' => 'TA-AL-SO',
         'TRACER' => 'BEH-NA-AL-KAH-HI',
         'TRAFFIC' => 'DIAGRAM',
         'TRAIN' => 'COH-NAI-ALI-BAHN-SI',
         'TRANSPORTATION' => 'A-HAH-DA-A-CHA',
         'TRENCH' => 'E-GADE',
         'TRIPLE' => 'TKA-IH',
         'TROOP' => 'NAL-DEH-HI',
         'TRUCK' => 'CHIDO-TSO',
         'TYPE' => 'ALTH-AH-A-TEH',
         'UNDER' => 'BI-YAH',
         'UNIDENTIFIED' => 'DO-BAY-HOSEN-E',
         'UNIT' => 'DA-AZ-JAH',
         'UNSHACKLE' => 'NO-DA-EH-NESH-GOHZ',
         'UNTIL' => 'UH-QUO-HO',
         'VICINITY' => 'NA-HOS-AH-GIH',
         'VILLAGE' => 'CHAH-HO-OH-LHAN-IH',
         'VISIBILITY' => 'NAY-ES-TEE',
         'VITAL' => 'TA-EH-YE-SY',
         'WARNING' => 'BILH-HE-NEH',
         'WAS' => 'NE-TEH',
         'WATER' => 'TKOH',
         'WAVE' => 'YILH-KOLH',
         'WEAPON' => 'BEH-DAH-A-HI-JIH-GANI',
         'WELL' => 'TO-HA-HA-DLAY',
         'WHEN' => 'GLOE-EH-NA-AH-WO-HAI',
         'WHERE' => 'GLOE-IH-QUI-AH',
         'WHICH' => 'GLOE-IH-A-HSI-TLON',
         'WILL' => 'GLOE-IH-DOT-SAHI',
         'WIRE' => 'BESH-TSOSIE',
         'WITH' => 'BILH',
         'WITHIN' => 'BILH-BIGIH',
         'WITHOUT' => 'TA-GAID',
         'WOOD' => 'CHIZ',
         'WOUND' => 'CAH-DA-KHI',
         'YARD' => 'A-DEL-TAHL',
         'ZONE' => 'BIH-NA-HAS-DZOH');

my %DDICT = ('DIN-NEH-IH' => 'CORPS',
         'ASHIH-HI' => 'DIVISION',
         'TABAHA' => 'REGIMENT',
         'TACHEENE' => 'BATTALION',
         'NAKIA' => 'COMPANY',
         'HAS-CLISH-NIH' => 'PLATOON',
         'YO-IH' => 'SECTION',
         'DEBEH-LI-ZINI' => 'SQUAD',
         'GEN' => 'COMMANDING',
         'GEN' => 'MAJOR',
         'GEN' => 'BRIGADIER',
         'ATSAH-BESH-LE-GAI' => 'COLONEL',
         'CHE-CHIL-BE-TAH-OLA' => 'MAJOR',
         'BESH-LEGAI-NAH-KIH' => 'CAPTAIN',
         'BESH-LEGAI-A-LAH-IH' => 'LIEUTENANT',
         'OFFICER' => 'COMMANDING',
         'OFFICER' => 'EXECUTIVE',
         'ZHIN-NI' => 'AFRICA',
         'BEH-HGA' => 'ALASKA',
         'NE-HE-MAH' => 'AMERICA',
         'CHA-YES-DESI' => 'AUSTRALIA',
         'TOH-TA' => 'BRITAIN',
         'CEH-YEHS-BESI' => 'CHINA',
         'DA-GHA-HI' => 'FRANCE',
         'BESH-BE-CHA-HE' => 'GERMANY',
         'TKIN-KE-YAH' => 'ICELAND',
         'AH-LE-GAI' => 'INDIA',
         'DOH-HA-CHI-YALI-TCHI' => 'ITALY',
         'BEH-NA-ALI-TSOSIE' => 'JAPAN',
         'KE-YAH-DA-NA-LHE' => 'PHILIPPINE',
         'SILA-GOL-CHI-IH' => 'RUSSIA',
         'AMERICA' => 'SOUTH',
         'DEBA-DE-NIH' => 'SPAIN',
         'WO-TAH-DE-NE-IH' => 'PLANES',
         'BOMBER' => 'DIVE',
         'PLANE' => 'TORPEDO',
         'PLANE' => 'FIGHTER',
         'PLANE' => 'BOMBER',
         'PLANE' => 'PATROL',
         'ATSAH' => 'TRANSPORT',
         'TOH-DINEH-IH' => 'SHIPS',
         'LO-TSO' => 'BATTLESHIP',
         'TSIDI-MOFFA-YE-HI' => 'AIRCRAFT',
         'BESH-LO' => 'SUBMARINE',
         'SWEEPER' => 'MINE',
         'CA-LO' => 'DESTROYER',
         'DINEH-NAY-YE-HI' => 'TRANSPORT',
         'LO-TSO-YAZZIE' => 'CRUISER',
         'BOAT' => 'MOSQUITO',
         'ATSAH-BE-YAZ' => 'JANUARY',
         'WOZ-CHEIND' => 'FEBRUARY',
         'TAH-CHILL' => 'MARCH',
         'TAH-TSO' => 'APRIL',
         'TAH-TSOSIE' => 'MAY',
         'BE-NE-EH-EH-JAH-TSO' => 'JUNE',
         'BE-NE-TA-TSOSIE' => 'JULY',
         'BE-NEEN-TA-TSO' => 'AUGUST',
         'GHAW-JIH' => 'SEPTEMBER',
         'NIL-CHI-TSOSIE' => 'OCTOBER',
         'NIL-CHI-TSO' => 'NOVEMBER',
         'YAS-NIL-TES' => 'DECEMBER',
         'YE-TSAN' => 'ABANDON',
         'WOLA-CHI-A-MOFFA-GAHN' => 'ABOUT',
         'WOLA-CHEE-BE-YIED' => 'ABREAST',
         'UL-SO' => 'ACCOMPLISH',
         'BE-KA-HO' => 'ACCORDING',
         'HANOT-DZIED' => 'ACKNOWLEDGE',
         'AH-HA-TINH' => 'ACTION',
         'AH-HA-TINH-Y' => 'ACTIVITY',
         'BEH-GHA' => 'ADEQUATE',
         'IH-HE-DE-NDEL' => 'ADDITION',
         'YI-CHIN-HA-TSE' => 'ADDRESS',
         'BE-GAHI' => 'ADJACENT',
         'HAS-TAI-NEL-KAD' => 'ADJUST',
         'NAS-SEY' => 'ADVANCE',
         'NA-NETIN' => 'ADVISE',
         'BE-ZONZ' => 'AERIAL',
         'LANH' => 'AFFIRMATIVE',
         'BI-KHA-DI' => 'AFTER',
         'BE-NA-GNISH' => 'AGAINST',
         'EDA-ELE-TSOOD' => 'AID',
         'NILCHI' => 'AIR',
         'NILCHI-BEGHAN' => 'AIRDOME',
         'HA-IH-DES-EE' => 'ALERT',
         'TA-A-TAH' => 'ALL',
         'NIH-HI-CHO' => 'ALLIES',
         'WOLACHEE-SNEZ' => 'ALONG',
         'EH-DO' => 'ALSO',
         'NA-KEE-GO-NE-NAN-DEY-HE' => 'ALTERNATE',
         'KHAC-DA' => 'AMBUSH',
         'BEH-ELI-DOH-BE-CAH-ALI-TAS-AI' => 'AMMUNITION',
         'CHAL' => 'AMPHIBIOUS',
         'DO' => 'AND',
         'DEE-CAHN' => 'ANGLE',
         'IH-NAY-TANI' => 'ANNEX',
         'BEH-HA-O-DZE' => 'ANNOUNCE',
         'WOL-LA-CHEE-TSIN' => 'ANTI',
         'NI-JOL-LIH' => 'ANTICIPATE',
         'TAH-HA-DAH' => 'ANY',
         'YE-KA-HA-YA' => 'APPEAR',
         'BI-CHI-OL-DAH' => 'APPROACH',
         'TO-KUS-DAN' => 'APPROXIMATE',
         'GAH-TSO' => 'ARE',
         'HAZ-A-GIH' => 'AREA',
         'BESH-YE-HA-DA-DI-TEH' => 'ARMOR',
         'LEI-CHA-IH-YIL-KNEE-IH' => 'ARMY',
         'IL-DAY' => 'ARRIVE',
         'BE-AL-DOH-TSO-LANI' => 'ARTILLERY',
         'AHCE' => 'AS',
         'ALTSEH-E-JAH-HE' => 'ASSAULT',
         'DE-JI-KASH' => 'ASSEMBLE',
         'BAH-DEH-TAHN' => 'ASSIGN',
         'AH-DI' => 'AT',
         'AL-TAH-JE-JAY' => 'ATTACK',
         'BO-O-NE-TAH' => 'ATTEMPT',
         'GIHA' => 'ATTENTION',
         'HANI-BA-AH-HO-ZIN' => 'AUTHENTICATOR',
         'BE-BO-HO-SNEE' => 'AUTHORIZE',
         'TA-SHOZ-TEH-IH' => 'AVAILABLE',
         'KLAILH' => 'BAGGAGE',
         'NE-TAH' => 'BANZAI',
         'BESH-NA-ELT' => 'BARGE',
         'BESH-BA-WA-CHIND' => 'BARRAGE',
         'BIH-CHAN-NI-AH' => 'BARRIER',
         'BIH-TSEE-DIH' => 'BASE',
         'BIH-BE-AL-DOH-TKA-IH' => 'BATTERY',
         'DA-AH-HI-DZI-TSIO' => 'BATTLE',
         'TOH-AH-HI-GHINH' => 'BAY',
         'AH-ZHOL' => 'BAZOOKA',
         'TSES-NAH' => 'BE',
         'TAH-BAHN' => 'BEACH',
         'TSES-NAH-NES-CHEE' => 'BEEN',
         'BIH-TSE-DIH' => 'BEFORE',
         'HA-HOL-ZIZ' => 'BEGIN',
         'TSES-NAH-SNEZ' => 'BELONG',
         'BI-TAH-KIZ' => 'BETWEEN',
         'BILH-LA' => 'BEYOND',
         'EHL-NAS-TEH' => 'BIVOUAC',
         'A-YE-SHI' => 'BOMB',
         'TRAP' => 'BOOBY',
         'YE-CHIE-TSAH' => 'BORNE',
         'KA-YAH-BI-NA-HAS-DZOH' => 'BOUNDARY',
         'DOZER' => 'BULL',
         'TSAS-KA' => 'BUNKER',
         'NEH-DIH' => 'BUT',
         'BE-GHA' => 'BY',
         'BESH-LKOH' => 'CABLE',
         'NAHL-KIHD' => 'CALIBER',
         'TO-ALTSEH-HOGAN' => 'CAMP',
         'DI-NES-IH' => 'CAMOUFLAGE',
         'YAH-DI-ZINI' => 'CAN',
         'BE-AL-DOH-TSO-DEY-DIL-DON-IGI' => 'CANNONEER',
         'BE-NEL-AH' => 'CAPACITY',
         'YIS-NAH' => 'CAPTURE',
         'YO-LAILH' => 'CARRY',
         'BIT-SAH' => 'CASE',
         'BIH-DIN-NE-DEY' => 'CASUALTY',
         'BI-NIH-NANI' => 'CAUSE',
         'TSA-OND' => 'CAVE',
         'DA-TEL-JAY' => 'CEILING',
         'JISH-CHA' => 'CEMETARY',
         'ULH-NE-IH' => 'CENTER',
         'THLA-GO-A-NAT-ZAH' => 'CHANGE',
         'HA-TALHI-YAZZIE' => 'CHANNEL',
         'AH-TAH-GI-JAH' => 'CHARGE',
         'TA-NEE' => 'CHEMICAL',
         'NAS-PAS' => 'CIRCLE',
         'AH-HEH-HA-DAILH' => 'CIRCUIT',
         'ALTH-AH-A-TEH' => 'CLASS',
         'YO-AH-HOL-ZHOD' => 'CLEAR',
         'TSE-YE-CHEE' => 'CLIFF',
         'UL-CHI-UH-NAL-YAH' => 'CLOSE',
         'GUARD' => 'COAST',
         'YIL-TAS' => 'CODE',
         'NAKI-ALH--DEH-DA-AL-ZHIN' => 'COLON',
         'ALTH-KAY-NE-ZIH' => 'COLUMN',
         'DA-AH-HI-JIH-GANH' => 'COMBAT',
         'AL-TKAS-EI' => 'COMBINATION',
         'HUC-QUO' => 'COME',
         'TSA-NA-DAHL' => 'COMMA',
         'NAI-EL-NE-HI' => 'COMMERCIAL',
         'HUC-QUO-LA-JISH' => 'COMMIT',
         'HA-NEH-AL-ENJI' => 'COMMUNICATION',
         'BE-KI-ASZ-JOLE' => 'CONCEAL',
         'TA-LA-HI-JIH' => 'CONCENTRATION',
         'WHE-HUS-DIL' => 'CONCUSSION',
         'AH-HO-TAI' => 'CONDITION',
         'BE-KE-YA-TI' => 'CONFERENCE',
         'NA-NIL-IN' => 'CONFIDENTIAL',
         'TA-A-NEH' => 'CONFIRM',
         'A-KEH-DES-DLIN' => 'CONQUER',
         'NE-TSA-CAS' => 'CONSIDER',
         'BILH' => 'CONSIST',
         'AH-HIH-HI-NIL' => 'CONSOLIDATE',
         'AHL-NEH' => 'CONSTRUCT',
         'AH-HI-DI-DAIL' => 'CONTACT',
         'TA-YI-TEH' => 'CONTINUE',
         'NAI-GHIZ' => 'CONTROL',
         'TKAL-KAH-O-NEL' => 'CONVOY',
         'BEH-EH-HO-ZIN-NA-AS-DZOH' => 'COORDINATE',
         'ATTACK' => 'COUNTER',
         'CO-JI-GOH' => 'COURSE',
         'AH-TOH' => 'CRAFT',
         'TOH-NIL-TSANH' => 'CREEK',
         'AL-N-AS-DZOH' => 'CROSS',
         'SHUSH-YAHZ' => 'CUB',
         'US-DZOH' => 'DASH',
         'HA-YELI-KAHN' => 'DAWN',
         'AH-KIN-CIL-TOH' => 'DEFENSE',
         'NAHL-KIHD' => 'DEGREE',
         'BE-SITIHN' => 'DELAY',
         'BE-BIH-ZIHDE' => 'DELIVER',
         'AH-DEEL-TAHI' => 'DEMOLITION',
         'HO-DILH-CLA' => 'DENSE',
         'DA-DE-YAH' => 'DEPART',
         'HOGAN' => 'DEPARTMENT',
         'YE-KHI-DEL-NEI' => 'DESIGNATE',
         'AH-DA-AH-HO-DZAH' => 'DESPERATE',
         'AL-CHA-NIL' => 'DETACH',
         'BE-BEH-SHA' => 'DETAIL',
         'AH-DEEL-TAHI' => 'DETONATOR',
         'NA-NE-KLAH' => 'DIFFICULT',
         'IN' => 'DIG',
         'AH-JI-GO' => 'DIRECT',
         'EH-HA-JAY' => 'DISEMBARK',
         'LA-CHAI-EN-SEIS-BE-JAY' => 'DISPATCH',
         'HIH-DO-NAL' => 'DISPLACE',
         'BE-SEIS-NA-NEH' => 'DISPLAY',
         'A-HO-TEY' => 'DISPOSITION',
         'NAH-NEH' => 'DISTRIBUTE',
         'BE-THIN-YA-NI-CHE' => 'DISTRICT',
         'TSE-LE' => 'DO',
         'BEH-EH-HO-ZINZ' => 'DOCUMENT',
         'AH-NOL-KAHL' => 'DRIVE',
         'DI-GISS-YAHZIE' => 'DUD',
         'DI-GISS-TSO' => 'DUMMY',
         'TA-LAHI-NE-ZINI-GO' => 'EACH',
         'WHO-DZAH' => 'ECHELON',
         'BE-BA-HI' => 'EDGE',
         'BE-DELH-NEED' => 'EFFECTIVE',
         'YEA-GO' => 'EFFORT',
         'AH-NA-NAI' => 'ELEMENT',
         'ALI-KHI-HO-NE-OHA' => 'ELEVATE',
         'HA-BEH-TO-DZIL' => 'ELIMINATE',
         'EH-HO-JAY' => 'EMBARK',
         'HO-NEZ-CLA' => 'EMERGENCY',
         'LA-AZ-NIL' => 'EMPLACEMENT',
         'YE-NAS-TEH' => 'ENCIRCLE',
         'BI-KHANH' => 'ENCOUNTER',
         'A-HA-NE-HO-TA' => 'ENGAGE',
         'CHIDI-BI-TSI-TSINE' => 'ENGINE',
         'DAY-DIL-JAH-HE' => 'ENGINEER',
         'NIH-TSA-GOH-AL-NEH' => 'ENLARGE',
         'BIH-ZIH-A-DA-YI-LAH' => 'ENLIST',
         'TA-A-TAH' => 'ENTIRE',
         'E-GAD-AH-NE-LIH' => 'ENTRENCH',
         'A-ZAH-GI-YA' => 'ENVELOP',
         'YA-HA-DE-TAHI' => 'EQUIPMENT',
         'YEH-ZIHN' => 'ERECT',
         'A-ZEH-HA-GE-YAH' => 'ESCAPE',
         'HAS-TAY-DZAH' => 'ESTABLISH',
         'BIH-KE-TSE-HOD-DES-KEZ' => 'ESTIMATE',
         'HA-NA' => 'EVACUATE',
         'NEH-DIH' => 'EXCEPT',
         'NA-WOL-NE' => 'EXCEPT',
         'ALH-NAHL-YAH' => 'EXCHANGE',
         'A-DO-NIL' => 'EXECUTE',
         'AH-DEL-TAHI' => 'EXPLOSIVE',
         'SHIL-LOH' => 'EXPEDITE',
         'NE-TDALE' => 'EXTEND',
         'AL-TSAN-AH-BAHM' => 'EXTREME',
         'CHA-AL-EIND' => 'FAIL',
         'YEES-GHIN' => 'FAILURE',
         'MAI-BE-HE-AHGAN' => 'FARM',
         'DZEH-CHI-YON' => 'FEED',
         'CLO-DIH' => 'FIELD',
         'TOH-BAH-HA-ZSID' => 'FIERCE',
         'BA-EH-CHEZ' => 'FILE',
         'TAH-AH-KWO-DIH' => 'FINAL',
         'THROWER' => 'FLAME',
         'DAH-DI-KAD' => 'FLANK',
         'WO-CHI' => 'FLARE',
         'MA-E-AS-ZLOLI' => 'FLIGHT',
         'TA-NA-NE-LADI' => 'FORCE',
         'BE-CHA' => 'FORM',
         'BE-CHA-YE-LAILH' => 'FORMATION',
         'AH-NA-SOZI' => 'FORTIFICATION',
         'AH-NA-SOZI-YAZZIE' => 'FORTIFY',
         'TEHI' => 'FORWARD',
         'BESH-YAZZIE' => 'FRAGMENTATION',
         'HA-TALHI-TSO' => 'FREQUENCY',
         'NEH-HECHO-DA-NE' => 'FRIENDLY',
         'BI-TSAN-DEHN' => 'FROM',
         'YEAS-NIL' => 'FURNISH',
         'WO-NAS-DI' => 'FURTHER',
         'YAH-A-DA-HAL-YON-IH' => 'GARRISON',
         'CHIDI-BI-TOH' => 'GASOLINE',
         'NI-MA-SI' => 'GRENADE',
         'NI-DIH-DA-HI' => 'GUARD',
         'NAH-E-THLAI' => 'GUIDE',
         'LHI-TA-A-TA' => 'HALL',
         'TRACK' => 'HALF',
         'TA-AKWAI-I' => 'HALT',
         'BET-SEEN' => 'HANDLE',
         'JO' => 'HAVE',
         'NA-HA-TAH-TA-BA-HOGAN' => 'HEADQUARTER',
         'WO-TAH-TA-EH-DAHN-OH' => 'HELD',
         'WO-TAH' => 'HIGH',
         'EXPLOSIVE' => 'HIGH',
         'WO-TAH-HO-NE-TEH' => 'HIGHWAY',
         'WO-TKANH' => 'HOLD',
         'A-ZEY-AL-IH' => 'HOSPITAL',
         'A-NAH-NE-DZIN' => 'HOSTILE',
         'BE-EL-DON-TS-QUODI' => 'HOWITZER',
         'WO-CHI' => 'ILLUMINATE',
         'SHIL-LOH' => 'IMMEDIATELY',
         'A-HE-DIS-GOH' => 'IMPACT',
         'BA-HAS-TEH' => 'IMPORTANT',
         'HO-DOL-ZHOND' => 'IMPROVE',
         'EL-TSOD' => 'INCLUDE',
         'HO-NALH' => 'INCREASE',
         'BA-HAL-NEH' => 'INDICATE',
         'TA-NEH-NAL-DAHI' => 'INFANTRY',
         'YE-GHA-NE-JEH' => 'INFILTRATE',
         'BEH-ED-DE-DLID' => 'INITIAL',
         'EHD-TNAH' => 'INSTALL',
         'NAS-NIL' => 'INSTALLATION',
         'NA-NE-TGIN' => 'INSTRUCT',
         'HO-YA' => 'INTELLIGENCE',
         'DZEEL' => 'INTENSE',
         'YEL-NA-ME-JAH' => 'INTERCEPT',
         'AH-NILH-KHLAI' => 'INTERFERE',
         'AH-TAH-HA-NE' => 'INTERPRET',
         'NA-ALI-KA' => 'INVESTIGATE',
         'A-TAH' => 'INVOLVE',
         'SEIS' => 'IS',
         'SEIS-KEYAH' => 'ISLAND',
         'BIH-TSA-NEL-KAD' => 'ISOLATE',
         'WOH-DI-CHIL' => 'JUNGLE',
         'NAZ-TSAID' => 'KILL',
         'NAS-TSAID-A-KHA-AH-YEH-' => 'KILOCYCLE',
         'NA-NISH' => 'LABOR',
         'KAY-YAH' => 'LAND',
         'TKA-GHIL-ZHOD' => 'LAUNCH',
         'AH-NA-GHAI' => 'LEADER',
         'DE-BE-YAZIE-HA-A-AH' => 'LEAST',
         'DAH-DE-YAH' => 'LEAVE',
         'NISH-CLA-JIH-GOH' => 'LEFT',
         'BI-OH' => 'LESS',
         'DIL-KONH' => 'LEVEL',
         'DA-A-HE-GI-ENEH' => 'LIAISON',
         'BA-HAS-AH' => 'LIMIT',
         'NI-DAS-TON' => 'LITTER',
         'A-KWE-EH' => 'LOCATE',
         'UT-DIN' => 'LOSS',
         'GUN' => 'MACHINE',
         'NA-E-LAHI' => 'MAGNETIC',
         'HASTNI-BEH-NA-HAI' => 'MANAGE',
         'NA-NA-O-NALTH' => 'MANEUVER',
         'KAH-YA-NESH-CHAI' => 'MAP',
         'BEL-DIL-KHON' => 'MAXIMUM',
         'CHITI-A-NAYL-INIH' => 'MECHANIC',
         'CHIDI-DA-AH-HE-GONI' => 'MECHANIZED',
         'A-ZAY' => 'MEDICAL',
         'MIL-AH-HEH-AH-DILH' => 'MEGACYCLE',
         'SHIP' => 'MERCHANT',
         'HANE-AL-NEH' => 'MESSAGE',
         'SILAGO-KEH-GOH' => 'MILITARY',
         'NA-AS-TSO-SI-A-YE-DO-TISH' => 'MILLIMETER',
         'HA-GADE' => 'MINE',
         'BE-OH' => 'MINIMUM',
         'AH-KHAY-EL-KIT-YAZZIE' => 'MINUTE',
         'AL-NESHODI' => 'MISSION',
         'O-ZHI' => 'MISTAKE',
         'HA-TAO-DI' => 'MOPPING',
         'THLA-NA-NAH' => 'MORE',
         'BE-AL-DOH-CID-DA-HI' => 'MORTAR',
         'NA-HOT-NAH' => 'MOTION',
         'CHIDE-BE-TSE-TSEN' => 'MOTOR',
         'KA-HA-TENI' => 'NATIVE',
         'TAL-KAH-SILAGO' => 'NAVY',
         'YE-NA-ZEHN' => 'NECESSARY',
         'DO-YA-SHO-DA' => 'NEGATIVE',
         'NA-NES-DIZI' => 'NET',
         'DO-NEH-LINI' => 'NEUTRAL',
         'DOH-A-TA-H-DAH' => 'NORMAL',
         'NI-DAH-THAN-ZIE' => 'NOT',
         'NE-DA-TAZI-THIN' => 'NOTICE',
         'KUT' => 'NOW',
         'BEH-BIH-KE-AS-CHINIGH' => 'NUMBER',
         'BI-NE-YEI' => 'OBJECTIVE',
         'HAL-ZID' => 'OBSERVE',
         'DA-HO-DESH-ZHA' => 'OBSTACLE',
         'YEEL-TSOD' => 'OCCUPY',
         'TOH-NI-TKAL-LO' => 'OF',
         'BIN-KIE-JINH-JIH-DEZ-JAY' => 'OFFENSIVE',
         'TA-LAI-DI' => 'ONCE',
         'TA-EI-TAY-A-YAH' => 'ONLY',
         'YE-NAHL-NISH' => 'OPERATE',
         'ASH-GA-ALIN' => 'OPPORTUNITY',
         'NE-HE-TSAH-JIH-SHIN' => 'OPPOSITION',
         'EH-DO-DAH-GOH' => 'OR',
         'TCHIL-LHE-SOI' => 'ORANGE',
         'BE-EH-HO-ZINI' => 'ORDER',
         'LEI-AZ-JAH' => 'ORDNANCE',
         'DAS-TEH-DO' => 'ORIGINATE',
         'LA-E-CIH' => 'OTHER',
         'CLO-DIH' => 'OUT',
         'BE-KA-HAS-TSOZ' => 'OVERLAY',
         'ATSANH' => 'PARENTHESIS',
         'A-YO-AD-DO-NEH' => 'PARTICULAR',
         'DA-SHA-JAH' => 'PARTY',
         'NA-ELI-YA' => 'PAY',
         'TAH-NI-DES-TANH' => 'PENALIZE',
         'YAL' => 'PERCENT',
         'DA-AHL-ZHIN' => 'PERIOD',
         'DA-AL-ZHIN-THIN-MOASI' => 'PERIODIC',
         'GOS-SHI-E' => 'PERMIT',
         'DA-NE-LEI' => 'PERSONNEL',
         'BEH-CHI-MA-HAD-NIL' => 'PHOTOGRAPH',
         'BOX' => 'PILL',
         'DOWN' => 'PINNED',
         'TSIDI' => 'PLANE',
         'DIL-DI-GHILI' => 'PLASMA',
         'BE-SO-DE-DEZ-AHE' => 'POINT',
         'TKOSH-JAH-DA-NA-ELT' => 'PONTOON',
         'BILH-HAS-AHN' => 'POSITION',
         'TA-HA-AH-TAY' => 'POSSIBLE',
         'SAH-DEI' => 'POST',
         'HASH-TAY-HO-DIT-NE' => 'PREPARE',
         'KUT' => 'PRESENT',
         'BIH-TSE-DIH' => 'PREVIOUS',
         'ALTSEH-NAN-DAY-HI-GIH' => 'PRIMARY',
         'HANE-PESODI' => 'PRIORITY',
         'DA-TSI' => 'PROBABLE',
         'NA-NISH-TSOH' => 'PROBLEM',
         'NAY-NIH-JIH' => 'PROCEED',
         'NAH-SAI' => 'PROGRESS',
         'AH-CHANH' => 'PROTECT',
         'YIS-NIL' => 'PROVIDE',
         'DINL-CHI' => 'PURPLE',
         'COH-NA-CHANH' => 'PYROTECHNIC',
         'AH-JAH' => 'QUESTION',
         'SHIL-LOH' => 'QUICK',
         'ESAT-TSANH' => 'RADAR',
         'DEZJAY' => 'RAID',
         'A-DE-GEH-HI' => 'RAILHEAD',
         'KONH-NA-AL-BANSI-BI-THIN' => 'RAILROAD',
         'A-LAH-NA-O-GLALIH' => 'RALLYING',
         'AN-ZAH' => 'RANGE',
         'GAH-EH-YAHN' => 'RATE',
         'NA-A-JAH' => 'RATION',
         'CHUSH-KA' => 'RAVINE',
         'IL-DAY' => 'REACH',
         'KUT' => 'READY',
         'BE-KA-DENH' => 'REAR',
         'SHOZ-TEH' => 'RECEIPT',
         'CHE-HO-TAI-TAHN' => 'RECOMMEND',
         'HA-A-CIDI' => 'RECONNAISSANCE',
         'TA-HA-NE-AL-YA' => 'RECONNOITER',
         'GAH-AH-NAH-KLOLI' => 'RECORD',
         'LI-CHI' => 'RED',
         'TSA-ZHIN' => 'REEF',
         'EH-NA-COH' => 'REEMBARK',
         'NA-NA-COH' => 'REFIRE',
         'NA-YEL-N' => 'REGULATE',
         'NAL-DZIL' => 'REINFORCE',
         'AGANH-TOL-JAY' => 'RELIEF',
         'NAH-JIH-CO-NAL-YA' => 'RELIEVE',
         'HA-DIT-ZAH' => 'REORGANIZE',
         'NI-NA-DO-NIL' => 'REPLACEMENT',
         'WHO-NEH' => 'REPORT',
         'TKA-NAZ-NILI' => 'REPRESENTATIVE',
         'JO-KAYED-GOH' => 'REQUEST',
         'HESH-J-E' => 'RESERVE',
         'BA-HO-CHINI' => 'RESTRICT',
         'AH-HOS-TEEND' => 'RETIRE',
         'JI-DIN-NES-CHANH' => 'RETREAT',
         'NA-DZAH' => 'RETURN',
         'WHO-NEH' => 'REVEAL',
         'NA-SI-YIZ' => 'REVERT',
         'BA-NAS-CLA' => 'REVETMENT',
         'GAH-GHIL-KEID' => 'RIDGE',
         'BE-AL-DO-HOSTEEN' => 'RIFLEMAN',
         'TOH-YIL-KAL' => 'RIVER',
         'BOMB' => 'ROBOT',
         'LESZ-YIL-BESHI' => 'ROCKET',
         'YEH-MAS' => 'ROLL',
         'NAZ-PAS' => 'ROUND',
         'GAH-BIH-TKEEN' => 'ROUTE',
         'NIH-DZID-TEIH' => 'RUNNER',
         'A-TKEL-YAH' => 'SABOTAGE',
         'A-TKEL-EL-INI' => 'SABOTEUR',
         'CHA-LE-GAI' => 'SAILOR',
         'NA-HAS-GLAH' => 'SALVAGE',
         'BIH-LA-SANA-CID-DA-HI' => 'SAT',
         'BEH-EH-HO-ZINI' => 'SCHEDULE',
         'HA-A-SID-AL-SIZI-GIH' => 'SCOUT',
         'BESH-NA-NES-DIZI' => 'SCREEN',
         'TKAL-KAH-DINEH-IH' => 'SEAMAN',
         'BAH-HAS-TKIH' => 'SECRET',
         'YOEHI' => 'SECTOR',
         'YE-DZHE-AL-TSISI' => 'SECURE',
         'YEEL-STOD' => 'SEIZE',
         'BE-TAH-HAS-GLA' => 'SELECT',
         'COLON' => 'SEMI',
         'DZEH-CID-DA-HI' => 'SET',
         'DI-BAH-NESH-GOHZ' => 'SHACKLE',
         'BE-AL-DOH-BE-CA' => 'SHELL',
         'TAH-BAHN' => 'SHORE',
         'BOSH-KEESH' => 'SHORT',
         'BOSH-KEESH' => 'SIDE',
         'YE-EL-TSANH' => 'SIGHT',
         'NA-EH-EH-GISH' => 'SIGNAL',
         'ALAH-IH-NE-TIH' => 'SIMPLEX',
         'TKIN-CID-DA-HI' => 'SIT',
         'A-HO-TAY' => 'SITUATE',
         'LIT' => 'SMOKE',
         'OH-BEHI' => 'SNIPER',
         'BE-TKAH' => 'SPACE',
         'E-YIH-SIH' => 'SPECIAL',
         'YO-ZONS' => 'SPEED',
         'AH-NA-HO-NEIL' => 'SPORADIC',
         'EEL-TSAY-I' => 'SPOTTER',
         'KLESH-SO-DILZIN' => 'SPRAY',
         'NAH-GHIZI' => 'SQUADRON',
         'NE-OL' => 'STORM',
         'NA-WO-GHI-GOID' => 'STRAFF',
         'CHY-NE-DE-DAHE' => 'STRAGGLER',
         'NA-HA-TAH' => 'STRATEGY',
         'TOH-NI-LIH' => 'STREAM',
         'DZHEL' => 'STRENGTH',
         'DESZ-TSOOD' => 'STRETCH',
         'NAY-DAL-GHAL' => 'STRIKE',
         'HA-TIH-JAH' => 'STRIP',
         'NIL-TA' => 'STUBBORN',
         'NA-NISH-YAZZIE' => 'SUBJECT',
         'TKAL-CLA-YI-YAH' => 'SUBMERGE',
         'A-NIH-LEH' => 'SUBMIT',
         'AL-KHI-NAL-DZL' => 'SUBORDINATE',
         'YAH-TAY-GO-E-ELAH' => 'SUCCEED',
         'UT-ZAH' => 'SUCCESS',
         'UT-ZAH-HA-DEZ-BIN' => 'SUCCESSFUL',
         'UT-ZAH-SID' => 'SUCCESSIVE',
         'YIS-CLEH' => 'SUCH',
         'TO-HO-NE' => 'SUFFER',
         'SHIN-GO-BAH' => 'SUMMARY',
         'TKA-GO-NE-NAN-DEY-HE' => 'SUPPLEMENTARY',
         'NAL-YEH-HI' => 'SUPPLY',
         'SHIP' => 'SUPPLY',
         'BA-AH-HOT-GLI' => 'SUPPORT',
         'NE-NA-CHA' => 'SURRENDER',
         'NAZ-PAS' => 'SURROUND',
         'YIS-DA-YA' => 'SURVIVE',
         'DI-BA-TSA-AS-ZHI-BI-TSIN' => 'SYSTEM',
         'E-CHIHN' => 'TACTICAL',
         'GAH-TAHN' => 'TAKE',
         'CHAY-DA-GAHI' => 'TANK',
         'DESTROYER' => 'TANK',
         'WOL-DONI' => 'TARGET',
         'TAZI-NA-EH-DIL-KID' => 'TASK',
         'DEH-NA-AS-TSO-SI' => 'TEAM',
         'ALI-KHI-HO-NE-OHA' => 'TERRACE',
         'TASHI-NA-HAL-THIN' => 'TERRAIN',
         'KA-YAH' => 'TERRITORY',
         'TAZI-CHA' => 'THAT',
         'CHA-GEE' => 'THE',
         'BIH' => 'THEIR',
         'TA-ZI-KWA-I-BE-KA-DI' => 'THEREAFTER',
         'CHA-GI-O-EH' => 'THESE',
         'CHA-GEE' => 'THEY',
         'DI' => 'THIS',
         'TA-BILH' => 'TOGETHER',
         'LO-BE-CA' => 'TORPEDO',
         'TA-AL-SO' => 'TOTAL',
         'BEH-NA-AL-KAH-HI' => 'TRACER',
         'DIAGRAM' => 'TRAFFIC',
         'COH-NAI-ALI-BAHN-SI' => 'TRAIN',
         'A-HAH-DA-A-CHA' => 'TRANSPORTATION',
         'E-GADE' => 'TRENCH',
         'TKA-IH' => 'TRIPLE',
         'NAL-DEH-HI' => 'TROOP',
         'CHIDO-TSO' => 'TRUCK',
         'ALTH-AH-A-TEH' => 'TYPE',
         'BI-YAH' => 'UNDER',
         'DO-BAY-HOSEN-E' => 'UNIDENTIFIED',
         'DA-AZ-JAH' => 'UNIT',
         'NO-DA-EH-NESH-GOHZ' => 'UNSHACKLE',
         'UH-QUO-HO' => 'UNTIL',
         'NA-HOS-AH-GIH' => 'VICINITY',
         'CHAH-HO-OH-LHAN-IH' => 'VILLAGE',
         'NAY-ES-TEE' => 'VISIBILITY',
         'TA-EH-YE-SY' => 'VITAL',
         'BILH-HE-NEH' => 'WARNING',
         'NE-TEH' => 'WAS',
         'TKOH' => 'WATER',
         'YILH-KOLH' => 'WAVE',
         'BEH-DAH-A-HI-JIH-GANI' => 'WEAPON',
         'TO-HA-HA-DLAY' => 'WELL',
         'GLOE-EH-NA-AH-WO-HAI' => 'WHEN',
         'GLOE-IH-QUI-AH' => 'WHERE',
         'GLOE-IH-A-HSI-TLON' => 'WHICH',
         'GLOE-IH-DOT-SAHI' => 'WILL',
         'BESH-TSOSIE' => 'WIRE',
         'BILH' => 'WITH',
         'BILH-BIGIH' => 'WITHIN',
         'TA-GAID' => 'WITHOUT',
         'CHIZ' => 'WOOD',
         'CAH-DA-KHI' => 'WOUND',
         'A-DEL-TAHL' => 'YARD',
         'BIH-NA-HAS-DZOH' => 'ZONE');

sub encrypt
{
    my $str = shift;
    $str =~ tr/[a-z]/[A-Z]/;
    $str =~ s/[^a-zA-Z\d\s]//g;
    my @words = split /\s+/, $str;
    
    foreach my $i (0..$#words)
    {
    if(exists($CDICT{$words[$i]}))
    {
        $words[$i] = $CDICT{$words[$i]};
        next;
    }
    my @letters = split //, $words[$i];
    foreach my $j (0..$#letters)
    {
        next if($letters[$j] =~ /\d/);
        if(exists $CALPHA{$letters[$j]})
        {
        $letters[$j] = 
            $CALPHA{$letters[$j]}->[rand @{$CALPHA{$letters[$j]}}];
        }
        else
        {
        die "Letter not found in encryption dictionary: ", 
        $letters[$j], "\n";
        }
    }
    $words[$i] = join ' ', @letters;
    }
    return join '  ', @words;
}

sub decrypt
{
    my $str = shift;
    my @words = split /\s\s/, $str;
    foreach my $i(0.. $#words)
    {
    next if $words[$i] =~ /\d/;
    if($words[$i] =~ /\s/)
    {
        my @letters = split /\s/, $words[$i];
        $words[$i] = '';
        foreach my $j (0..$#letters)
        {
        if($letters[$j] =~ /\d/)
        {
            $words[$i] .= $letters[$j];
        }
        elsif(exists $DALPHA{$letters[$j]})
        {
            $words[$i] .= $DALPHA{$letters[$j]};
        }
        else
        {
            die "Letter not found in decryption dictionary: ", 
            $letters[$j], "\n";
        }
        }
        next;
    }
    if(exists $DDICT{$words[$i]})
    {
        $words[$i] = $DDICT{$words[$i]};
    }
    elsif(exists $DALPHA{$words[$i]})
    {
        $words[$i] = $DALPHA{$words[$i]};
    }
    else
    {
        die "Word not found in decryption dictionary: ", $words[$i], "
+\n";
    }
    }
    return join ' ', @words;
}

return 'DIBEH AH-NAH TSIN-TLITI BI-SO-DIH DZEH DAH-NES-TSA  CHUO TKIN 
+BE AH-JAH AH-JAD YEH-HES KLESH';


=head1 NAME

Crypt::Navajo - Navajo Code Talkers encryptionl

=head1 SYNOPSIS
  use Crypt::Navajo qw/encrypt decrypt/;

  my $string = "PERL HARBOR IS UNDER ATTACK";
  my $ciphertext = encrypt($string);
  my $plaintext = decrypt($ciphertext);

=head1 DESCRIPTION

This module implements the code the Navajo Code Talkers used during WW
+II in the
Pacific theater.  The code was devised by Navajo Marines and proved un
+breakable
to the Japanese.  The cipher as it appears in the Perl code is taken f
+rom the 
Navajo Code Talker's Dictionary, revised as of 15 June 1945 (available
+ at
http://www.history.navy.mil/faqs/faq61-4.htm).
This module is not intended for use in modern cryptography--anybody wi
+th the
algorithm can decrypt anything encrypted with it.

=head1 AUTHOR

 Perl code written by Michael J. Iatauro, miatauro@zahadum.com
 Navajo Code suggested by Philip Johnston, developed by the first 29 N
+avajo 
 Marine recruits.

=cut
Replies are listed 'Best First'.
Re: Crypt::Navajo
by zengargoyle (Deacon) on Jan 17, 2003 at 04:23 UTC

    i don't know if this is faster or slower, but it seems like it would be easier to maintain if you built %DALPHA from %CALPHA and the same for %DDICT

    my %CALPHA = ( 'A' => [ 'wanker', 'tweet', 'bonk' ], 'B' => [ 'ping', 'zilch' ], ... ); my %DALPHA; foreach my $k ( keys %CALPHA ) { foreach my $l ( @{$CALPHA{$k}} ) { $DALPHA{$l} = $k; } }

    then you just have to update one hash instead of two

    if updates are frequent go a step further and pull them in from a DATA section.

    ... while (my $l = <DATA>) { my ($plain,$crypt) = split /\s+/, $l; %CDICT{$plain} = $crypt; %DDICT{$crypt} = $plain; } ... __DATA__ CORPS DIN-NEH-IH DIVISION ASHIH-HI REGIMENT TABAHA ...

    you may have to use a different delimiter depending on your code.

    HOT HEAD:DEF-DUM-DEE CRUISE MISSILE:BOOM-BOOM

    then you can add a new word way easy...

    echo "JAR HEAD:UG-GO-GRUNT" >> /path/to/Crypt/Navajo.pm

    cool anyways... now i can decode the blood-stained documents that mysteriously turned up in my mailbox

    Update: merlyn is correct, i meant to say $CDICT{$plain}=$crypt; $DDICT{$crypt}=$plain;

      I'd thought about writing the code in almost precisely this fashion, but since the Navajo Code hasn't been updated since 1945, it seemed unnecessary. =-)
      ~Cybercosis

      nemo accipere quod non merere

Re: Crypt::Navajo
by Arien (Pilgrim) on Jan 17, 2003 at 07:27 UTC

    Some things I noticed when reading through your code...

    Both your encryption and your decryption dictionaries have duplicate entries. Of course, only one of these (the last) will be used as the key in the hash. After seeing a couple, I wrote a script to find all duplicates. This is the output:

    Plain words with multiple translations: EXCEPT: NEH-DIH, NA-WOL-NE HIGH: WO-TAH, EXPLOSIVE SUPPLY: NAL-YEH-HI, SHIP TANK: CHAY-DA-GAHI, DESTROYER Code words with multiple translations: AH-DEEL-TAHI: DEMOLITION, DETONATOR ALI-KHI-HO-NE-OHA: ELEVATE, TERRACE ALTH-AH-A-TEH: CLASS, TYPE BIH-TSE-DIH: BEFORE, PREVIOUS BILH: CONSIST, WITH BOSH-KEESH: SHORT, SIDE CHA-GEE: THE, THEY CLO-DIH: FIELD, OUT IL-DAY: ARRIVE, REACH KUT: NOW, PRESENT, READY NAHL-KIHD: CALIBER, DEGREE NAZ-PAS: ROUND, SURROUND NEH-DIH: BUT, EXCEPT SHIL-LOH: EXPEDITE, IMMEDIATELY, QUICK SHIP: MERCHANT, SUPPLY TA-A-TAH: ALL, ENTIRE TAH-BAHN: BEACH, SHORE WHO-NEH: REPORT, REVEAL WO-CHI: FLARE, ILLUMINATE

    You can use Carp's croak (and carp) instead of die (and warn) to help the user of your module to find where things went awry in his code.

    tr works with character ranges, not regular expressions.

    Why use indexes in your foreach loops? You can use (implicit) aliases for the current element, leading to clearer and less cluttered code, eg this chunk from your encrypt sub:

    my @words = split /\s+/, $str; foreach my $word (@words) { $word = $CDICT{$word}, next if exists $CDICT{$word}; my @letters = split //, $word; foreach (@letters) { next if /\d/; if (exists $CALPHA{$_}) { $_ = $CALPHA{$_}->[ rand @{$CALPHA{$_}} ]; } else { croak "Letter '$_' not found in encryption dictionary"; } } $word = join ' ' => @letters; } return join ' ' => @words;

    — Arien

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: sourcecode [id://227633]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2020-05-31 04:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If programming languages were movie genres, Perl would be:















    Results (173 votes). Check out past polls.

    Notices?