Yes, they are rubbing it on their hair and hide....to help remove parasites. Part of the reason they 'wallow' as well (besides cooling off)... is to trap parasites in the mud...which is then rubbed off on trees, posts, etc.
You can actually make an area more attractive to hogs by either placing 'rub poles' in the ground at strategic spots or spraying/coating trees that are in convenient areas (along travel routes or close to bedding areas).
You can't purchase Creosote any more...but you can buy 'rendered' less potent products such as 'Kreso-D' (a livestock dip) which has a VERY potent Creosote smell to it.
I mix it (a few ounces to 3 gallons) in a back-pack sprayer and saturate the bark of selected trees. IF there are hogs nearby...it won't be long before they find it and use the newly created 'rub'.
It will NOT attract hogs from long distances, nor will it redirect their path of travel, but if you will take the time to find established trails or 'staging areas', you can make that area more 'attractive' to them.
Here is an example of a tree I sprayed...and how it was subsequently used. Note how the bark was quickly rubbed smooth.
Then... here is just your 'garden variety' rub (see mud) that you see all over the place.