Many other people have pointed out the information paradox of black holes, which, based on our understanding of black holes today says that you could not input information into black holes and obtain meaningful results from any type of output (Hawking radiation) in this case.
But, we're talking about a black hole that sits inside a planet, so I would wager that whoever built this probably has a better understanding of black holes than we do. If you want to stay within the realms of our current understanding, I would put forward two possible scenarios (both from 30,000 ft so as not to get bogged down in the muck and mire of all the unknowns surrounding black holes):
Decoding Hawking Radiation
The black hole was created (and permanently exists within) a larger planet aka. a closed system, unlike any black hole we know of. The circumstances surrounding the construction and implementation of this theoretical information-storing black hole are known. It is possible that under these circumstances all variables can be accounted for - all matter and energy that has ever entered the black hole is known - and an algorithm was developed based on this in order to obtain meaningful information.
This depends on the nature of your weapon though. If it is a physical device, you won't be able to put it into and out of a black hole like it's a box. 43
If it's some sort of cyber-weapon consisting of data alone, it's doable.
Black Hole is the Weapon
If you don't want to interpret the radiation that is coming from the black hole, perhaps the black hole itself is the weapon. When ready for use, the black hole could be expelled from the planet on a trajectory that sends it to the target destination - wiping out everything along the way - and eventually destroying the planet or solar system it is targeting. In the meantime, the planet is at work gathering resources to construct another black hole.
Going to destroy the weapon would be a suicide mission, as disabling the planet would cause it to implode and anything in the vicinity would be destroyed as well.
This is also the ultimate dead-hand weapon. Containing a black hole would require substantial energy and matter. Assuming you could contain a continuously growing black hole indefinitely, it would require an indefinite amount of resources - depleting the surrounding space in turn. If the weapon is never used, it sits until the heat-death of the universe or close to it, where it will be used regardless, ensuring that it wipes out 99