On computing the 2-diameter-constrained K-reliability of networks