In Chapter Fifteen of To Kill a Mockingbird, Tom Robinson will be shortly standing trial for the rape of Mayella Ewell; consequently, the man has been moved to the Maycomb jail. Atticus leaves with the car early one night for mysterious reasons, which are discovered when Jem, Scout, and Dill follow him: Atticus is sitting outside the jail with his newspaper.
A mob of angry men soon forms outside the jail, and they demand that Atticus moves away from the door. These men plan to steal Tom from his cell and to lynch him as their own form of personal "justice" for the his alleged crime. Although Atticus is at the end of an implied threat that the men will do whatever it takes to get to Tom, Tom himself is the real target--a black man whose life is at stake because of the racist attitudes of a faction who believe it is their responsibility to dole out punishment for a crime that has not even been tried in court.
Thankfully, Scout intervenes and unconsciously manages to talk sense into the men by reminding them of their ties to Maycomb. Thus, both Tom and Atticus remain safe for the night.
The mob was a lynch mob, plain and simple, with the purpose of removing Tom Robinson from the jail and carrying out vigilante justice the old fashioned Southern way. . .by lynching Tom Robinson. Atticus anticipated this, of course, which is why he was sitting outside reading a newspaper; what no one did anticipate, of course, was the arrival of Scout and Jem, nor did anyone expect the mob to disperse after Scout's innocent inquiries into Mr. Cunningham's well-being and the state of his "entailment". Some have argued that this scene is not realistic, but many believe that Scout's innocence in the face of such hatred and dangerous mob mentality was completely realistic.
This question has already been answered right here on eNotes. Here is a comprehensive link for you: http://www.enotes.com/to-kill-a-mockingbird/q-and-a/tags/jail