In a food processor, combine chopped onion, garlic, ginger, galangal, red chilies, turmeric, coriander, cumin, and cinnamon. Blend into a smooth paste.
Heat vegetable oil in a large pot or Dutch oven over medium heat.
Add the spice paste and cook, stirring frequently, for about 5-7 minutes, until fragrant and the oil starts to separate.
Add the beef cubes to the pot and cook, stirring occasionally, until the meat is browned on all sides.
Add coconut milk, beef broth (or water), kaffir lime leaves, and lemongrass to the pot.
Stir to combine and bring to a boil.
Reduce the heat to low, cover, and simmer gently for 1.5 to 2 hours, or until the beef is tender and the sauce has thickened. Stir occasionally and add more liquid if necessary to prevent burning.
Add tamarind paste (or lime juice), palm sugar, and salt to taste. Adjust seasoning as needed.
Continue to simmer uncovered for an additional 30 minutes, or until the sauce is thick and the oil has separated.
Garnish with fried shallots or shallot crisps if desired.
Enjoy your meal!