Terrorism is a persistent global threat today. It is extremely hard to predict where and how an attack can take place as it practically knows no border, nationality or religion. Efficient screening and appropriate security measures are therefore essential for protecting buildings and objects during largely attended events. Since this is an expensive operation, an optimal use of human resources is needed to prevent it and minimize the damage. In this work, we study a model of a building with multiple distinct rooms and a single terrorist who can move between the rooms. The terrorist can activate a bomb in different rooms depending on the crowd occupancy of the room. There are under cover policemen who are moving and protecting the object by trying to capture the terrorist. We propose a model using an absorbing Markov chain where the absorbing states are when either when the terrorist is captured or he activates the bomb. The transient analysis of the Markov chain will derive the probabilities that the terrorist succeeds (activates the bomb) or fails (gets intercepted by the law enforcement). It will also derive the average time to success or defeat. The goal is to maximize the probability of capturing the criminal and minimize the capture time.