In 1864 the French government under the Emperor Napoleon III, taking advantage of the Civil War in the United States, occupied Mexico and placed Maximilian on the throne as emperor. As soon as the war was over, Mr. Seward took steps to force the French to retire from that country, and by that means enabled the people to choose between Maximilian as emperor and Juarez as president, without being influenced by the presence of the French military forces. A cabinet meeting was called, at which General Grant was present by invitation. The result of the conference was that an instruction was prepared by Secretary Seward to our minister at Paris that plainly stated the sentiments of the United States, which was to the effect that the French must evacuate Mexico at once, or the United States would send her troops into that country and help the forces of the republic. The Atlantic cable had only just been completed, and the president of the company wanted the patronage of the Government to aid the enterprise. He called upon Mr. Seward and requested him to use the cable, promising that the rates should be entirely satisfactory to the Government, notwithstanding those to the public were ten dollars per word. In addition to the ordinary charge, the cable company imposed double rates upon all messages in which a cipher code was used. The instruction was given to the writer to put it in cipher, when he called the attention of the secretary to the great expense that would attend its transmission by cable, as each syllable in the instruction would be represented by four figures, and the cable company considered each figure as an equivalent for a word, and charged double rates accordingly. Having in view the assurances of the president of the company that the charges would not be excessive, Mr. Seward gave directions to have the instruction put in cipher and sent by cable, which was done. The instruction would occupy in print about a page and a quarter of an ordinary congressional document. The bill of the cable company was afterward submitted, and it amounted to over $23,000, which Mr. Seward, not considering it reasonable, refused to pay. The rates were soon reduced to the public one half, and several other reductions followed, but the bill which Mr. Seward refused to pay was never paid.

During the occupation of Mexico by the French, cipher telegrams were sent to General Bazaine, commander of the French forces. Some of these coming into the possession of the authorities of the United States were deciphered by an army officer and much valuable information was obtained.

The value and importance of secret writing is of course obvious, but the advantages which have accrued from it, while easily surmised, have become known only in a vague and general way. A specific illustration of a particular benefit derived from it by the United States in a very important matter and at a very critical time relates to the treaty of 1871 between this country and Great Britain, whereby the so-called “Alabama Claims” were to be adjusted by a Tribunal of Arbitration at Geneva, and which came very near being nullified in consequence of our presentation to that tribunal of what was known as “indirect claims,” namely, claims not for actual losses, but for the deprivation of prospective profits, etc. Great Britain sought to use the presentation of these claims as a ground for setting aside the jurisdiction of the tribunal, and consequently subverting it. Our agent before the tribunal, Judge J. C. Bancroft Davis, devised a plan for saving the case of the United States and preserving the tribunal. The nature of this plan was such as to require the approval of the President before it could be put into operation, and had to be communicated to him quickly as well as secretly. In anticipation of some such emergency, the writer, at Mr. Davis’s request, had prepared for him, just before his departure for Geneva, a cipher which, while perfectly secret, could be easily managed and the key of which could be memorized. Mr. Davis and Secretary Fish had recourse to this cipher for the purpose of the important correspondence above referred to, which could not have been conducted openly and which resulted in the maintenance of the Geneva Tribunal. An amusing feature of this correspondence was the perturbation it caused our minister at London, General Schenck. The messages were relayed through his office, and he, not being in the secret of the cipher, insisted upon having them repeated, because, as he said, he found them to be only “a jargon of unmeaning words.”

The Government, as such, has no distinct cipher, but each of the three departments, State, War, and Navy, the only departments really needing methods for secrecy of correspondence, is provided with a cipher of its own.

During the Civil War the Navy Department devised a cipher which was simply a substitution of one letter of the alphabet for another, and this was operated by a mechanical contrivance consisting of disks, one of which was stationary and the other movable. The stationary disk contained the letters of the “true reading,” and the movable disk the cipher substitutes. The process of its operation was tedious and awkward, but it was continued in use until the middle of the eighties, when several naval officers were designated to prepare a more convenient code. The new system is a combination of numerals and cipher words to represent words and phrases, following the general principle of most commercial codes. While not as full as it might be, it answers its purpose very well. Through overcaution, however, its operation has been made unnecessarily complicated, two translations being required to decipher a message, while one should be sufficient. Words have to be translated into figures and the figures then translated into the true meaning.

The code-book of this cipher is always kept in a canvas bag lined with zinc and heavily weighted. The bag is in the personal custody of the commanding officer, whose orders are, that in the event of danger of capture by the enemy, it is to be thrown overboard. Hence there is little likelihood of the code ever falling into improper hands.

The cipher of the War Department is very simple in its nature, and by virtue of its simplicity, easiness of operation, its inscrutability, and above all the readiness with which, in the event of its capture, a new and entirely different key can be substituted, commends itself as possessing a superiority over all others for military purposes. It may in a general way be described as an ingenious method of distorting the order of the words in a message, and further obscuring the sense by the systematic interpolation of irrelevant words and the introduction of meaning and meaningless names. The variety of distortions is great, and whenever a copy of the cipher is captured, another can be supplied and communicated to all parties interested in a very short space of time. This cipher is an elaboration of one that was designed for the governor of Ohio, at the beginning of our Civil War, to facilitate secret correspondence between him and the governors of Indiana and Illinois. Its effectiveness soon became recognized, and it was generally used during the war for the direction of military operations and the correspondence between our generals and the War Department.

In this connection it may be stated that during our Civil War the telegraph and the cipher system for the first time in history became important factors in the matter of tactics and strategy. The telegraph was first utilized as a military aid during the Crimean War (1854–55), but its use was confined to being merely a means of communication between the headquarters of the allied forces. But in our Civil War the telegraph and cipher were the principal channels for the direction of military operations, embodying, as they did, all the elements of celerity and secrecy, and rendering the signal corps picturesque but very ancient fire or flag system, in general, of very little practical value. By way of illustration, the fact may here be stated that during the siege of Petersburg, General Meade received and sent in five hours over three hundred telegrams, being more than one in every three minutes. Such a feat is readily seen to be far beyond the capacity of any system of wigwagging, fire, or flag signals, no matter how ancient or modern. It must be admitted, however, that these signal systems are at times of great and essential value, especially when telegraph lines cannot be established. The victory of the Federal troops at Lookout Mountain was mainly due to the skill of our signal corps in deciphering the signals of the Confederates and advising our generals accordingly.

For military purposes, telegraph operators were looked upon as possessing the best qualifications for enciphering and deciphering secret communications, but the sense of self-importance or esteem which seemed to attach to the person intrusted with these operations caused the staff-officers eagerly to seek such employment. As the war progressed, however, the work gradually devolved entirely upon the telegraphers, but not until after some discomfiting experiences on the part of some distinguished officers. General Grant undertook to send from La Grange, Tennessee, a cipher message to General Hamilton, who was at the front. Hamilton could not understand it, and had it repeated, but all to no purpose. Grant insisted that the message was correctly enciphered, but very soon afterward he gladly abandoned the cipher business to his operators. On another occasion General Grant, upon leaving his headquarters at Chattanooga to go to Knoxville, failed to take his telegraph operator with him. While at Knoxville he received several telegrams from Washington which he could not understand, and being consequently much annoyed, he directed his operator to turn over the cipher-key to his chief of staff, so that he would not be troubled with unintelligible telegrams in the future. For doing this he was reprimanded by General-in-Chief Halleck, who, in a letter, dated January 22, 1864, said:

A new and very complicated cipher was prepared for communications between you and the War Department which, by direction of the Secretary of War was to be communicated to only two individuals—one at your headquarters and one in the War Department. It was to be communicated to no one else—not even to me or any member of my staff.... On account of this cipher having been communicated to Col. Comstock, the Secretary has directed another to be prepared in its place, which is to be communicated to no one, no matter what his rank, without his special authority.