Absolutely. "A great danger" is a noun. It is grammatically correct to put ANY preposition in front of it:
about a great danger
before a great danger
near a great danger
following a great danger
over a great danger
at a great danger
behind a great danger, ...
and so forth. There are over a hundred possibilities. Some will be more useful than others but none is wrong. If you give me just about any a preposition, I can make a sentence in which that preposition makes sense with "a great danger". For example:
"On their hike, Alice an Mary arrived at a swamp teeming with alligators. They became fearful as they sensed they had arrived at a great danger."