The Muramasa can't be crafted. It is a 1 in 7 find in the locked Gold Chests of the Dungeon and in Golden Lock Boxes, and this covers getting Golden Keys, opening the chests and fishing for more tries.
The Muramasa is a pre-Hardmode sword in Terraria that you can't craft. Each locked Gold Chest in the Dungeon has a 1 in 7 chance (14.29%) to hold it, and so does each Golden Lock Box you fish up in the Dungeon.
Every locked chest and every lock box needs a Golden Key, and you have to beat Skeletron before you can explore the Dungeon. The Muramasa is also one of the four swords that make the Night's Edge, so it is worth finding even if you don't plan to use it.

Muramasa stats:
Talk to the Old Man at the Dungeon entrance at night and choose "Curse" to fight Skeletron. Until he is dead, going deeper than the entrance spawns Dungeon Guardians, which kill almost any player in one hit and can't be beaten for access.
After the fight the whole Dungeon is open, along with all of its locked chests. For the boss itself, see How To Summon Skeletron.
A Golden Key opens one locked Gold Chest or one Golden Lock Box, and it is used up when you do. Collect at least as many keys as the chests you plan to open:

Dungeon Slimes are the reliable source, so kill every one you see. Breaking pots on the way adds a few more.
Note: Keys you pick up before beating Skeletron still work later, so keep every one you find near the entrance.
Locked Gold Chests are spread through the whole Dungeon, from the upper halls down to the depths near the Underworld. Each one holds a single main item, picked from seven with a 1 in 7 chance each:
Gold Chests sparkle when light reaches them, which helps you spot them in dark rooms. The Biome Chests in the Dungeon can't be opened with a Golden Key. They need a Biome Key, which only drops after Plantera, so skip them for now.
Chests don't refill, so a world has a fixed number of tries. If every chest is open and no Muramasa came up, move on to fishing.
Fishing in the Dungeon after Skeletron can pull up Dungeon Crates, or Stockade Crates in Hardmode. Every one of them holds a Golden Lock Box, and that box gives one of the same seven items when you open it with a Golden Key. The Muramasa has the same 1 in 7 chance, and you can keep fishing until it shows up.

You have to stand in front of the Dungeon's natural brick walls for your catch to count as Dungeon loot. Make a small pool near the outer wall, where fewer enemies spawn, and bring a Calming Potion or swap any Water Candles for Peace Candles so the enemies don't knock you around while you fish.
The Muramasa swings very fast, and the first enemy you hit in each swing also takes a blue slash for half the damage that ignores 5 defense. That makes it a strong sword for the rest of pre-Hardmode, including the Dungeon itself.

Only the first hit of each swing creates a slash, so it does more against one strong enemy than against a crowd.
Note: Don't sell it once you find a better sword. Together with the Light's Bane or Blood Butcherer, the Blade of Grass and the Volcano, it becomes the Night's Edge, and that sword leads to the Terra Blade. For the recipe, see How To Get The Night's Edge. For the end of that chain, see How To Get The Terra Blade.