toebes / ciphers

Cipher Generators
BSD 3-Clause "New" or "Revised" License
13 stars 4 forks source link

Fractionated Morse auto-solver issues. #496

Open RanTheLab opened 6 months ago

RanTheLab commented 6 months ago
          Circling back to this one:

Today I'm working on this quote: I used some magic to make some fog laugh. It was mist tickle.

Here are some places where the auto-solver made decisions I didn't understand: Key: HOMESICK Crib: IUSED

This seems to have follow-on consequences for the possibilities it predicts for the letters between K and N - a human solver would know these have to stay within the first half of the alphabet. 

Same quote, key: FORECASTING Crib: MAGIC

This might be the same issue in two different instances, but I leave that to you.

Originally posted by @Agilus in https://github.com/toebes/ciphers/issues/410#issuecomment-1959758777

RanTheLab commented 6 months ago

Thanks for the feedback.

For HOMESICK, the code algorithm 'approximates' the keyword length. It obviously isn't always accurate. I do know the keyword length, but let the algorithm display its approximation in the output. One (easier) thing I can think of is if the approximation is vastly different than the actual length, display a message (along the lines of 'Pick a different keyword/crib combination). The more difficult (and correct) approach is redesign the algorithm to come up with a better approximation, especially since I already 'think' K is in the keyword. The crib of IUSED isn't a great choice because it only gives 4 mappings, even though that crib covers 7 cipher characters, there are 3 Ms and 2 Rs.

For FORECASTING, the approximation for keyword length is 10, in reality it is 11. The letters between D and J are all possible. But then something goes horribly wrong that is a real issue.

This is going to take some digging into to get working, but we appreciate the feedback...it makes the tool better and that helps everyone!

Agilus commented 6 months ago

Thank you! I agree that the crib isn't great - that's why I opened a second issue about the suggested keyword length on these, because I was working along various axes trying to get the right difficulty level. It was a struggle to get this one where I wanted it this morning.