Line 4 baking sheets with parchment paper. Make cookies: Whisk together flour, cocoa powder, and salt in a medium bowl. Cream butter and confectioners' sugar with a mixer on medium-high speed until light and fluffy, about 5 minutes. Scrape down sides of bowl. Add eggs one at a time, beating to combine after each addition and scraping down sides of bowl; then beat in vanilla. Slowly add flour mixture, beating until combined.
Turn out dough, and divide in four. Shape into flat rectangles, and wrap each in plastic wrap. Freeze until firm, about 15 minutes.
Working with one piece at a time, roll dough to 1/8-inch thickness on a lightly floured work surface. Using a pastry cutter, cut dough into 1 1/2-by-2 1/2-inch rectangles. (Return dough to freezer for several minutes if it softens.) Transfer to prepared baking sheets, spacing cookies 1 inch apart. Place baking sheets in the freezer until dough is firm again, about 15 minutes. Brush off excess flour. While dough is chilling, preheat oven to 325 degrees.
Bake cookies, rotating sheets once, until edges are firm, about 12 to 14 minutes. Let cool briefly on baking sheets, then transfer to a wire rack and let cool completely. While cookies are cooling, make filling.
To assemble cookies, spread 1 1/2 teaspoons of filling on the underside of a cookie. Sandwich filling with another cookie. If desired, drizzle assembled cookie sandwiches with chocolate, and refrigerate until set.