By the way, the though came to me while I was watching a GREAT episode of "The american experience" about the laying of the first transatlantic cable. The episode narrates a very fascinating story about how the telegraphic connection betwteen america and europe was achieved.
Here the link ::: https://youtu.be/cFKONUBBHQw
Edit :: corrected a typo
While I am not an expert on telegraphs, I can tell you that it was possible to intercept telegraph messages.
During Sherman's March to the Sea in the midst of the American Civil War, Union cavalry under the command of Hugh Kilpatrick overran a confederate telegraph station in a small Georgia town. The confederate garrison evacuated so quickly that it did not have time to transmit that it was pulling out of the station. A few minutes later a Confederate telegrapher from savannah sent a message asking if any yankees had been seen.
Kilpatrick had his own communications officer reply that no yankees had been seen and then ask about the troop dispositions in Savannah. At this time, however, the confederate telegrapher that had been forced to evacuate the original station hopped into the line from a station down the road, informing his comrade in Savannah that he was being played by Union troops. The game up, the two sides exchanged insults for a few minutes (much to Kilpatrick's delight) before the Union troops pressed on down the road.
Source: Noah Troudeau Southern Storm
While this is a little later than the 19th century, the classic example of hacking into the world wide cable system was when the British intercepted the Zimmerman Telegram, during World War One. First, the Royal Navy severed all of Germany's trans Atlantic cables. Then they intercepted a message the Germans sent from Portugal to Brazil, with instructions to forward it to the German embassy in Mexico. After decoding this message, the British sat on it, until it would have the maximum impact. When Germans resumed unrestricted submarine warfare in early 1917, the British showed the US State Department the Zimmerman telegram. The Germans were trying to get Mexico to start a war with the United States. The full story is told in the book "The Zimmerman Telegram" by Barbara Tuchman (1985)
A couple of possible examples.
One way to 'hack' the telegraph system was to send a telegram with bogus content and a false signature. In A Nation of Conterfeiters, an example is given of a swindler sending a telegram to a printing firm that prints banknotes, forging the signature of one of the printer's bank customers, asking the printer to print up another couple of million in notes and promising to show up to pick up the notes on a specified day. Of course, this swindle appears in the book only because it was detected, but the scheme almost succeeded.
The Big Con: The Story of the Confidence Man includes some lengthy explanation of the con that unfolds in the movie "The Sting," asserting that it was regularly practiced in America for a few decades. It traces the origin of that swindle to 19th century telegraph operators who got the idea that by tapping telegraph lines, they could gain information ahead of the market, either for sports betting or for investing in securities. But the smarter operators soon learned that bigger money could be made not by exploiting such information, but by convincing suckers that such information existed and could be exploited, The book is a delightful read supposedly based on long study of con men by the authors, but it is so delightful that the reader is sure to suspect that it, too, is bogus.