You will be returning to the Hazy Maze for this star, so take the right path at the beginning and find the wooden door in the Work Elevator area. Once you reach the toxic maze, go straight and put on the Metal Cap, then run around the corner. Ignore the ledge with the Blue Coin Block this time and continue on the other path to your left. Once you pass/near the lone Monty Mole, you will probably see a metal door in an alcove ahead. Head on over to this door and jump up to it. You will enter a small hallway with two Swoops and an elevator at the end.
This elevator will take you to the area above the Black Hole area, where there will be some red grating overhead. Make sure you absolutely keep the jump button held down when you’re clinging onto the grating, as you will let go and fall down into the area below. There are two paths here, with one taking you to a platform with a yellow box and the other leading to the star. If you want the yellow box, which contains a 1-Up by the way, go ahead and do that. From that platform, you can actually perform a Long Jump to the one with the star. If you don’t wish to go through the Hazy Maze, there is an alternate method in obtaining this star.
At the beginning of the stage, go down the left path and enter the Black Hole area. As soon as you enter, take care of the Scuttle Bug and pay no heed to the nearby Swoop. Looking in “first-person” mode, you should see the one platform above you, which will be the one with the yellow box. Your goal is to Wall Jump to reach that ledge, which you will want to do just to the left of the very first light on the wall. A Side Somersault or Double Jump are more than enough to get to it. Once you get to the ledge, you can Long Jump over to the star.