A movie about 2 kids looking for pirate treasure, but they found barrels with deadly gas instead

I’m looking for a movie that I’ve watched almost 20 years ago. All I remember: I watched it in early 2000s, don’t know when this movie was made. 2 kids were looking for buried treasure, they had map leading to treasure. At the end of movie those kids found barrels with Zyklon B (gas that was used by Germans in gas chambers), they saw ghost of either pirate or man in SS uniform, the ghost warned kids that the gas is deadly and they shouldn’t open barrels. Kids called for military to help them with barrels. It was adventure movie. Action took place in modern times.