Here is the pin-out for the dry contact sensor. The RJ-45 the combination is: White/orange, orange, white/green, blue, white/blue, green, white/brown, brown.
On the sensor on the black wire: white/green , green and brown. On the red wire: only orange, the rest are cut off. Please see these diagrams below. it is the same sequence for the security sensor the difference is the screwing with the blue lugs.