Attach socket to socket between two static meshes?


How can I attach one socket from static mesh A to another socket from mesh B. The problem is that I have multiple sockets on the static meshes.
I cannot use AttachToActor, since this will attach the pivot point from mesh A to the socket from mesh B. And I need the socket from mesh A to be attached to a socket from mesh B.

So I want to attach socket 11 (from mesh A) to socket 21 (from mesh B)
Here is a picture that describes this:

Any help would be appreciated.