Match the end of one post to the end of the other. Note the diameter of each post; they must be almost identical to achieve a smooth joint. Try flipping one or both posts end for end until you have the best match.
Measure and mark the length of each post from the outside point of the 90-degree corner to the opposite end, which may be left open, or attached to another post or wall depending on your needs.
Place the post on the table of your power miter saw, with the saw set to cut a 45-degree miter. Cut the first post with the miter to the left, so that the point of the long edge of the post will be to the right. Double-check that the post is pressed flush against the saw fence, extending straight along the fence's line, and pressed down to the table.
Start the saw and make the cut through the post in one smooth motion. Make sure the post does not turn on the table of the saw as it cuts through. Repeat the process with the second post, making the cut at the opposite end of the post, so that you have one post with an end mitered to the right and one with an end mitered to the left.
Position the posts on a flat work surface. Match the ends up as smoothly as possible. Clamp the two posts in place with quick clamps. Drill two pilot holes through the end of one post into the end of the other with a 1/4-inch wood bit. Make the holes about 1 inch apart. Bore the top of each hole out slightly with a 1-inch bit to a depth of 1/4 inch to make room for the socket wrench.
Drive one 1/4-inch-by-3-inch lag bolt into each hole. Use a socket wrench to tighten them snugly. You have now joined two posts to form a 90-degree angle.