The magnitude struck at a depth of 10 km (6.2 miles), the German agency said.