This sounds very much like the book Eon by Greg Bear:
Description of the Stone:
The asteroid itself is an elongated prolate spheroid which appears to be virtually identical to Juno, a large asteroid in the main belt. It has been hollowed out along its long axis, and subdivided into seven vast cylindrical chambers. It rotates to provide artificial gravity. The chambers are terraformed, the second and third containing abandoned cities which appear to be built by humans from Earth's future.
The Way:
A startling discovery is that the Stone is larger on the inside than outside: the seventh chamber extends beyond the end of the asteroid and appears to go on forever. When Patricia is mysteriously abducted by a strange looking human and an alien, an expedition is sent after her. They travel down the final chamber (called "the corridor" or "the Way"), where they encounter humanity's descendants.
Wiki Eon Description