The square box in the camera view represents the renderable area as defined by the render resolution. The red dotted-lined-box (created with SHIFT + B) defines a ‘renderable region’ which allows you to focus on specific areas of your render – It’s a great feature for fine-tuning.