The thing that you are asking about is called the Marauder’s Map. It is a map that shows the location of every being (so far as we know) in Hogwarts. We know that it shows people, ghosts, and even Mrs. Norris, the cat. We also know that it can tell who a person is even if that person is an animagus or is using Polyjuice Potion.
We first learn about the Marauder’s Map in Chapter 10 of Harry Potter and the Prisoner of Azkaban. There, George and Fred Weasley give Harry the map in order to help him go to Hogsmeade since he does not have permission to do so. At that point, we find out that they had stolen the map from Argus Filch’s office during their first year at Hogwarts. We later find out that the map had been created by Harry’s father, James, along with his friends Sirius Black, Remus Lupin, and Peter Pettigrew. It was confiscated from them by Filch and stayed in his office (he never discovered what it actually was) until the Weasley twins stole it.
Harry uses it now and again throughout the rest of the books. He tries to use it to find Ron and Hermione in Harry Potter and the Deathly Hallows, but they are not shown because they are in the Chamber of Secrets. He also uses it in that book while he is on the run. He gets it out so that he can see the dot that shows Ginny Weasley (with whom he is in love) at Hogwarts.
The answer to your question, then, is the Marauder’s Map.
Hey There! I believe the answer you are looking for is the Marauders Map! This was originally designed by a bunch of hooligans by the names of James, Serious, Remus, and Peter, however they use aliases on the map. It was eventually stolen from Filch's office by Fred and George, whom they eventually passed on to Harry in the Prisoner of Azkaban. The parchment will appear to be blank until someone speaks: "I solemnly swear that I am up to no good."