Opinion by
Judge TAUBMAN.Defendant, Charles Wirsching, appeals the trial court's order denying his motion for postconviction relief under Crim. P. 35(a) and Crim. P. 385(c). On July 20, 2000, we announced an opinion affirming the denial of post-conviction relief, based upon People v. Priester, 996 P.2d 766 (Colo.App.2000). One month later, the Supreme Court decided Clark v. People, 7 P.3d 168 (Colo.2000), which disapproved of Priester. Relying on Clark, defendant filed an untimely petition for rehearing, contending that he is entitled to a reduction of his sentence. Because an earlier timely petition for rehearing filed by the People is still pending, we elect to address the issues raised in defendant's petition for rehearing. See Wiggins v. People, 199 Colo. 341, 608 P.2d 348 (1980). Upon reconsideration, we now grant defendant's petition for rehearing, deny the People's petition, and reverse the order of the trial court.
Pursuant to a plea agreement, defendant pled guilty to one count of attempted sexual assault on a child. As part of the plea agreement, defendant was to receive a term of imprisonment ranging from four to eight years. Defendant ultimately received an eight-year sentence to the Department of Corrections (DOC).
Thereafter, 'defendant filed a combined Crim. P. 85(a) and Crim. P. 35(ec) motion claiming he had not been advised that he would be required to serve a five-year period of mandatory parole upon completion of his eight-year DOC sentence. Defendant also argued that the inclusion of a mandatory parole period resulted in a DOC sentence that exceeded the maximum sentence he bargained for in the plea agreement.
The trial court denied the motion after finding that defendant had been advised of the mandatory parole period and that the issue was not yet "ripe" because defendant might not actually serve his entire sentences of imprisonment or parole.
1.
Defendant's first contention is that the trial court erred in determining that his motion was not ripe for resolution. We agree that such determination was in error. A court may correct an illegal sentence at any time. Crim. P. 85(a); People v. Favors, 42 Colo.App. 263, 600 P.2d 78 (1979).
Accordingly, a defendant need not wait until he or she has served an entire term of incarceration and begun serving a period of mandatory parole before such defendant may challenge the legality of a plea agreement. See United States ex rel. Ferris v. Finkbeiner, 551 F.2d 185 (7th Cir. 1977) (mere fact that a defendant faces an additional five-year parole term, with its attendant restrictions, was sufficient prejudice to challenge legality of such parole), cert. denied, 435 U.S. 932, 98 S.Ct. 1508, 55 L.Ed.2d 530 (1978).
The situation presented here is unlike a habeas corpus claim challenging the lawfulness of continued confinement, which cannot be presented until such time as the petitioner claims he or she is entitled to immediate release. See Jones v. Zavaras, 926 P.2d 579 (Colo.1996).
*229Here, relying on §§ 17-22.5-408(7), 17-22,5-408(8), and 18-1-105(1)(a)(V), C.R.S. 2000, the trial court found that, because defendant could be discharged by the state parole board at any time during his five-year © period of mandatory parole, he may never be subject to the combined incarceration and parole time that exceeds the stipulated maximum sentence of eight years to which he agreed. However, under this analysis, defendant's ability to challenge an illegal sentence would be improperly cireumseribed.
If defendant had been inadequately advised concerning mandatory parole, his guilty plea might be invalid. See Craig v. People, 986 P.2d 951 (Colo.1999). In such cireum-stance, he should not have to defer his right to withdraw his plea and proceed to trial. Moreover, if defendant had to wait eight years before he could challenge the legality of his sentence, he would run the risk that a Crim. P. 835(c) motion filed at such time would be time-barred pursuant to § 16-5-402, C.R.8.2000.
Accordingly, we agree with defendant that his mandatory parole is properly an issue for judicial review.
II.
We also agree with defendant's contention that the trial court erred in determining that he had been adequately advised concerning the period of mandatory parole.
Cases involving a postconviction challenge to the imposition of mandatory parole require a two-part inquiry. First, the court must apply a de novo standard of review to the parties' plea agreement and determine whether, when viewed objectively, defendant was promised, as a material inducement to his or her plea, a sentence related to mandatory parole that is statutorily prohibited. If it did not, then the agreement is not invalid on this ground and the court must reach the second question: whether the defendant was properly advised that he or she would be subject toa period of mandatory parole, of the maximum possible length of that period, and of the fact that mandatory parole is a consequence distinct from imprisonment. See Craig v. People, supra.
Here, the record does not reveal that any promises concerning mandatory parole were made as part of the plea agreement. Moreover, if, as here, there is merely an agreement that a defendant will receive a specified number or range of years in DOC, then, under Craig, that agreement must be interpreted as referring only to the imprisonment component of the sentence and should not be read as encompassing the period of mandatory parole. Thus, we conclude that defendant's plea agreement was not invalid under the first prong of the Oraig test.
The dispositive inquiry then becomes whether the record as a whole demonstrates that defendant was properly advised that he would be subject to a period of mandatory parole, of the maximum possible length of that period, and of the fact that mandatory parole is a consequence distinct from imprisonment. See Craig v. People, supra.
Defendant's written plea agreement recited the possible penalties "plus a period of parole." At the providency hearing, the court again advised defendant of the potential range of penalties and mentioned "a period of parole." However, defendant was not advised of the maximum possible length of the parole period. We conclude that this omission rendered the parole advisement deficient. See Craig v. People, supra.
In Clark v. People, swpra, the supreme court held that when a defendant enters into a plea agreement and he or she is advised that the sentence will include a term of parole, but is not advised of the duration of such parole, the only remedy is to give the defendant an opportunity to withdraw his or her guilty plea.
Here, although defendant was notified of the possibility of parole, he was not informed of the duration of such parole period. Therefore, under Clark, the appropriate remedy is to remand the case to the trial court to give defendant an opportunity to withdraw his guilty plea. We also note that while defendant seeks reformation of his sentence pursuant to Clark, that remedy is not available.
However, we note that neither Craig nor Clark appears to prohibit the parties from *230agreeing to a reduced three-year DOC sentence followed by a five-year period of mandatory parole. The People do not presently seek such sentence modification, and we express no opinion regarding the appropriateness of such a reduced sentence. However, such agreement could render the incomplete advisement harmless under Craig.
Defendant did not raise, and we do not address, the question of whether defendant's term of parole was mandatory or discretionary. See People v. Martin, 987 P.2d 919 (Colo.App.1999), cert. granted (Colo. No. 99SC602, Nov. 2, 1999), petition for rehearing granted (Oct. 6, 2000).
The order is reversed, and the cause is remanded for further proceedings in accordance with this opinion.
PLANK and NIETO, JJ., concur.