[DO NOT PUBLISH]

IN THE UNITED STATES COURT OF APPEALS

FOR THE ELEVENTH CIRCUIT

________________________

No. 12-14419

Non-Argument Calendar

________________________

D.C. Docket No. 1:11-cv-23580-JAL

ROBERT RAMESES, 

Petitioner-Appellant,

versus

UNITED STATES DISTRICT COURT, 

for the Eastern District of California, 

US DEPARTMENT OF JUSTICE, 

RICHARD SCRUGGS, 

United States Attorney, 

DAVID DEMAIO, 

United States Attorney, 

HERBERT COUSINS, 

FBI Agent, et al.,

Respondents-Appellees.

________________________

Appeal from the United States District Court

for the Southern District of Florida

________________________

(July 22, 2013)

Case: 12-14419 Date Filed: 07/22/2013 Page: 1 of 9 
2

Before TJOFLAT, HULL and PRYOR, Circuit Judges.

PER CURIAM: 

Robert Rameses, a California state prisoner proceeding pro se, appeals the 

district court’s dismissal of his “Motion for Extraordinary Remedy of Specific 

Performance as Part of Plea Agreement” (“Motion”). The district court construed

the Motion as a petition for a writ of habeas corpus under 28 U.S.C. § 2254 and 

dismissed it for lack of subject matter jurisdiction. After review, we affirm.

I. BACKGROUND

On October 3, 2011, Rameses filed his Motion in the United States District 

Court for the Southern District of Florida. Rameses’s Motion named various state 

and federal actors, as well as the “United States District Court, For The Eastern 

District” as respondents.

In the Motion, Rameses asserted that in 1988 he entered into a plea 

agreement with the United States and the State of Florida. Rameses attached a 

copy of the 1988 plea agreement to the Motion. As memorialized in the plea 

agreement, Rameses agreed to plead guilty to four counts of second degree murder

in Florida state court and to cooperate with federal and state law enforcement in 

solving certain crimes. In exchange, the State agreed to dismiss other criminal 

charges against Rameses, to recommend that Rameses receive a 22-year sentence 

of imprisonment on the four murder counts, and to grant Rameses “the broadest 

Case: 12-14419 Date Filed: 07/22/2013 Page: 2 of 9 
3

type of use and derivative use immunity (but not transactional immunity)” for 

crimes he committed before signing the plea agreement.

The United States was not a party to this 1988 plea agreement. However, in 

two letters written to Rameses by an Assistant United States Attorney for the 

Southern District of Florida, the United States agreed to “consider[] itself bound by 

the terms of the written Plea Agreement between the State of Florida and 

[Rameses].” These letters referenced the 1988 plea agreement’s immunity 

provision and set forth that the United States “agreed that no federal charges will 

be filed against [Rameses] for any of the criminal acts disclosed . . . during the 

course of his interviews with federal and state law enforcement.”

Rameses ultimately served a sentence of fewer than ten years’ imprisonment 

for his four Florida murder convictions. After his release from prison, Rameses 

made his way to California.

Twelve years after executing the 1988 plea agreement, Rameses in 2000 was 

convicted by a jury in California state court for passing bad checks. Pursuant to

California’s three-strikes law, the California state prosecutor submitted Rameses’s 

four prior Florida second degree murder convictions to the jury. The jury, in turn, 

enhanced Rameses’s sentence for the bad-checks offense to a term of 25 years to 

life imprisonment based on these prior convictions. Rameses is currently serving 

this enhanced sentence in California state prison. 

Case: 12-14419 Date Filed: 07/22/2013 Page: 3 of 9 
4

Before filing his Motion in the Southern District of Florida, Rameses made 

at least two prior attempts in California to obtain federal post-conviction relief

related to his California bad-checks conviction. In 2005, Rameses filed a § 2254 

petition in the Eastern District of California—where he is incarcerated—which that 

district court denied on the merits in 2008. See Rameses v. Kernan, No. CIV 

S-04-1173, 2008 WL 883108 (E.D. Cal. Mar. 31, 2008) (adopting magistrate 

judge’s report, 2007 WL 4200814 (E.D. Cal. Nov. 27, 2007), and denying 

Rameses’s petition in its entirety). One of the claims Rameses raised in his 2005 

§ 2254 petition was that California “prosecutors were motivated to pursue [his]

case as a Three Strikes case by relying, at least in part, on immunized testimony.” 

Rameses, 2007 WL 4200814 at *1. On May 13, 2011, Rameses filed a “motion 

for extraordinary remedy of specific performance as part of plea agreement” in the 

Eastern District of California, which that district court construed as a successive 

§ 2254 petition and dismissed in January 2012.

In his instant 2011 Motion, Rameses argued that the California prosecutor’s

pursuit of a three-strikes enhanced sentence, based on Rameses’s four 

“immunized” Florida murder convictions, violated the immunity provisions of the

1988 plea agreement. Rameses requested an evidentiary hearing and “specific 

performance of [his] plea agreement.”

The federal government appeared on behalf of the federal respondents and 

Case: 12-14419 Date Filed: 07/22/2013 Page: 4 of 9 
5

filed a response to Rameses’s 2011 Motion. In pertinent part, the federal 

government contended that (1) the district court should construe Rameses’s Motion 

as a petition for a writ of habeas corpus filed under § 2254, in light of the injury 

Rameses alleged and the relief he requested; and (2) the Motion was a nearly 

verbatim copy of the earlier, successive § 2254 petition that Rameses had filed in 

2011 in the Eastern District of California. The government argued that a person in 

state custody could file a § 2254 petition but only in the federal court for the 

district where he was incarcerated or where the state court is located that convicted 

and sentenced him to that custody. Because Rameses was convicted and sentenced 

in a state court located within the Eastern District of California, and was in state 

custody within the same district, the district court in the Southern District of 

Florida lacked subject matter jurisdiction over the Motion.

Following the federal government’s response, a magistrate judge issued a 

report and recommendation (“R&R”) concerning Rameses’s Motion. In the R&R, 

the magistrate judge construed Rameses’s Motion as a petition for a writ of habeas 

corpus filed under § 2254, explaining that the Motion necessarily relied upon 

§ 2254 because Rameses was in state custody and he sought post-conviction relief 

in federal court related to his California bad-checks conviction and sentence.

However, the magistrate judge then noted that § 2241(d) governs where persons in 

state custody can file § 2254 petitions challenging their state convictions and 

Case: 12-14419 Date Filed: 07/22/2013 Page: 5 of 9 
6

sentences. Under § 2241(d), Rameses could file a § 2254 petition challenging his 

California conviction and sentence in either (1) “the district court for the district 

within which the [s]tate court was held which convicted and sentenced him”; or (2) 

“the district court for the district wherein [he was] in custody.” See 28 U.S.C. 

§ 2241(d). 

Thus, pursuant to § 2241(d), because a state court located in California 

convicted and sentenced Rameses for passing bad checks, and because he was “in 

custody” serving his sentence in California, the magistrate judge found that 

Rameses’s Motion, filed in the Southern District of Florida, did not satisfy 

§ 2241(d). And, because § 2241(d) was not satisfied, the district court in the 

Southern District of Florida did not have subject matter jurisdiction to consider the 

merits of the Motion. Accordingly, the magistrate judge recommended dismissing 

Rameses’s Motion.

1

The district court adopted the magistrate judge’s R&R without objection 

from either party and dismissed Rameses’s Motion. Rameses then timely 

appealed.2

 1

In the R&R—which the district court later adopted—the magistrate judge recommended 

that Rameses’s Motion be “denied.” However, despite the use of this terminology, we construe 

the district court’s disposition of Rameses’s Motion as a dismissal, rather than a denial, in light 

of the district court’s determination that it lacked subject matter jurisdiction to consider the 

Motion.

2

We review de novo a district court’s dismissal for lack of jurisdiction. Diaz v. Fla. 

Fourth Judicial Circuit ex rel. Duval Cnty., 683 F.3d 1261, 1263 (11th Cir. 2012).

Case: 12-14419 Date Filed: 07/22/2013 Page: 6 of 9 
7

II. DISCUSSION

 A federal court may recharacterize a pro se litigant’s motion to create a 

better correspondence between the substance of the motion and its underlying legal 

basis. Castro v. United States, 540 U.S. 375, 381–82, 124 S. Ct. 786, 791–92

(2003). “[A] state prisoner seeking post-conviction relief from a federal court has 

but one remedy: an application for a writ of habeas corpus.” Medberry v. Crosby, 

351 F.3d 1049, 1062 (11th Cir. 2003). 

All applications for writs of habeas corpus, including those filed under 28 

U.S.C. § 2254 by persons in state custody, are governed by 28 U.S.C. § 2241. Id. 

Under § 2241(a), federal district courts may grant writs of habeas corpus only 

“within their respective jurisdictions.” 28 U.S.C. § 2241(a). For a person who is 

“in custody under the judgment and sentence of a [s]tate court” and who wishes to 

file a § 2254 application, § 2241(d) specifies the “respective jurisdictions” where 

such an application may be filed. Under § 2241(d), a person in custody under the 

judgment of a state court may file his application for a writ of habeas corpus in the 

federal district (1) “within which the [s]tate court was held which convicted and 

sentenced him”; or (2) “wherein [he] is in custody.” 28 U.S.C. § 2241(d); see also

Eagle v. Linahan, 279 F.3d 926, 933 n.9 (11th Cir. 2001). 

Further, “[a] petitioner is not ‘in custody’ to challenge a conviction when the 

sentence imposed for that conviction has completely expired.” Van Zant v. Fla. 

Case: 12-14419 Date Filed: 07/22/2013 Page: 7 of 9 
8

Parole Comm’n, 104 F.3d 325, 327 (11th Cir. 1997). However, a habeas petitioner 

may challenge the use of a prior conviction with an expired sentence to enhance 

the sentence imposed for a later crime if he is currently serving the later, enhanced

sentence. Id. For purposes of the “in custody” requirement, the petitioner is 

deemed to be challenging the sentence for his later conviction, which, in 

Rameses’s case, is his California bad-checks conviction. Id.

Here, the district court properly construed Rameses’s Motion as an 

application for a writ of habeas corpus filed under § 2254 and governed by 

§ 2241’s jurisdictional requirements. See Castro, 540 U.S. at 381–82, 124 S. Ct. at 

791–92. Because Rameses’s Florida sentence for his state murder convictions “has 

completely expired,” Rameses is not “in custody” for the purpose of challenging 

those Florida convictions directly. Van Zant, 104 F.3d at 327. Rather, Rameses is 

“in custody” for purposes of challenging the three-strikes enhancement to his 

California state sentence that resulted from his expired Florida murder convictions. 

See id.

Accordingly, Rameses’s problem is that because he is “in custody” pursuant 

to a sentence imposed by a state court located in California, and he is incarcerated 

in California, he plainly has filed his Motion in the wrong court. Here, the district 

court in Florida correctly concluded that it lacked subject matter jurisdiction over 

the Motion because, under § 2241(d), Rameses may only petition for a writ of 

Case: 12-14419 Date Filed: 07/22/2013 Page: 8 of 9 
9

habeas corpus in federal district court in California, which is both where “the 

[s]tate court was held which convicted and sentenced him” and “wherein [he] is in 

custody.” 28 U.S.C. § 2241(d); see Eagle, 279 F.3d at 933 n.9. The district court 

in the Southern District of Florida lacked subject matter jurisdiction over 

Rameses’s Motion, which challenged his enhanced California sentence.

In light of the foregoing, we affirm the district court’s dismissal of 

Rameses’s Motion. 

AFFIRMED.

Case: 12-14419 Date Filed: 07/22/2013 Page: 9 of 9