Add the dried chilies, peppercorns and salt into the coffee grinder. If using coriander and cumin seeds, add them as well. Grind into a fine powder. *Allow chili dust to settle fully before opening the grinder, and don't put your face over it when you do to avoid inhaling chili dust!
Place the lemongrass, galangal, cilantro roots, and makrut lime zest in a narrow container, such as a glass measuring cup. Top it off with the garlic, shallots, and shrimp paste. (It is easier to blend with the moist ingredients on top.)
Use the immersion blender to blend everything until fine. You will need to lift and reposition the blender several times, stopping to scrape the bottom and bringing it to the top halfway through.
Once the mixture is fine, add the ground chili mixture and blend to mix.
Soak the dried chilies in water for at least 30 minutes, longer if possible, so they are softened. Drain and pat them dry as best you can. (Excess water will make it harder to pound.)
Grind white peppercorns and any other dry spices into a powder. Remove and set aside.
Pound the chilies with the salt into a fine paste. Once it starts to look mashed, add the ground dry spices to help absorb the moisture, then continue to pound into a fine paste.
Add the lemongrass, galangal, cilantro roots, and makrut lime zest and pound into a fine paste.
Add the garlic and shallots and pound into a fine paste.
Add the ground chili mixture and pound until well combined. Add the shrimp paste and pound to mix.
