There are multiple ways to teach the ignore behavior.
Just like training the dog to Pass an object. Research different methods.
I have been successful training the command "Pass" during our walks. My dog would desire to stop and sniff and dribble on every tree during our walk. This became troublesome. After I knew he had emptied his bladder and was shooting dust. I began saying the word "Pass" and at the same time I would shorten my leash grip and just keep walking. After a few days, my dog understood the "Pass" command. I no longer needed to shorten the leash and could just keep walking. The "Pass" command has since expanded to include any item, animal, people, car, tree, bush........ Many times, my dog doesn't pay any attention to other animals, he just ignores them and we keep walking. He may look, but that is the extent of his attention to "Pass" items.
Be aware, I never dragged my dog, just a firm steady pull on the leash to keep moving forward. I only gave verbal praise. I was also training the command "WC" for potty time during the first part of our walks. "WC" became meaningless when he was empty, then I would shift to the "Pass" command
I guess the key is to make the "Ignore" item not interesting by offering a more interesting item. In my case, the continued walk was the reward along with verbal praise. You could try a similar technique with the litter box.
Save a bit of the used litter minus any special buried treats. Remember, dogs key on smell. Place the litter into a box, leash the dog, walk past the box, say command and shorten leash, keep walking. When the dog shows any reduced interest, give a reward. Repeat, Repeat, Repeat, until the dog is showing no interest. Now, you continue, but quite saying the command, dog still on leash. Soon, you will be able to walk past on a slack leash. Then work to a no leash situation. Then try with the box located where you can observe it, let the dog roam and do his normal thing. If the dog shows interest, say the command, don't forget the reward when he respond.
In the mean time, take steps to place the litter box out of the dog's access.
Sorry, almost forgot. The command word you use to ignore can be anything you want. Just stay consistent.