Preheat the oven to 375 degrees F, and line baking sheets with parchment.
Cream the butter and sugar, just until smooth and combined (try not to whip in any air).
Mix in the egg and peppermint extract until incorporated.
Add the cornstarch and salt, mixing on medium-low speed.
Stir in the flour (about ¼ cup at a time) until the dough gathers itself into a ball and pulls cleanly away from the sides of the bowl (it should feel soft but not sticky).
Remove ⅔ of the dough from the mixing bowl, and tint the remaining ⅓ red.
To keep things manageable, divide the untinted (white) dough into 3 equal portions, and the tinted (red) dough into 6 equal portions.
Cover the dough you aren't currently working with to prevent it from drying out.
Roll 1 portion of white dough into a short log, then roll 2 portions of red dough into logs the same length as the white log.
Stack the logs with 1 red on the bottom, 1 white in the middle, and 1 red on top, then roll into a rope about 9 inches long.
Cut the rope into 8 equal pieces (about 2 ¼-inches long), and cover all but the one you're currently working with.
Roll into a thinner rope, approx. 6 inches long, then pick it up and start laying it on the prepared baking sheet, gently twisting and shaping it as you go.
Repeat this rolling, twisting, and shaping process with each remaining portion of dough until you have 24 candy cane cookies.
Bake the cookies until set at the edges but still soft towards the centers (approx. 7 to 9 minutes).*