(CNN) -- The border with Mexico must be secure.
This requirement is the cornerstone of an immigration reform bill a bipartisan group of senators are to file on Capitol Hill on Tuesday. There will be no path to legal residency for migrants without it.
Undocumented immigrants may also not reach the status of fully legal residents under the proposed legislation, until the Department of Homeland Security has implemented measures to prevent "unauthorized workers from obtaining employment in the United States."
The bill drafted by the "Gang of Eight" senators stipulates that the security of "high risk border sectors along the Southern border" must be verified, before most undocumented immigrants can access pathways to legal residency laid out in the proposed legislation.
The bill makes exceptions for those eligible for the DREAM Act, law-abiding immigrants who arrived in the United States as minors and completed high school in the country. It also includes allowances for certain agricultural laborers.
Conservative senators have insisted upon the border preconditions, and some Democrats have agreed to it. The latter party holds the majority of seats in the Senate.
Once border security has been established via criteria laid out in the legislation, many undocumented migrants would get a shot at gaining legal footing in the United States, according to a summary of the proposed legislation passed on to CNN.
But it will take time to establish border security, and the pathway to residency can be costly and take more than a decade to complete, although it is quick to reward successful applicants with the right to participate freely in America's workforce.
Quota-based border security
The bipartisan bill lays down strict criteria for the creation of a secure border.
It calls for $3 billion to beef up border security, which includes fortifying fences, staffing up patrols and acquiring surveillance technology from the Department of Defense, including drones and drone pilots.
Border officers must keep "High Risk Sectors along the Southern Border" under constant surveillance, and they must apprehend and turn back at least 90% of those who cross into the United States illegally each year.
A high-risk border sector is defined as a section where the number of apprehended illegal crossers tops 30,000 per year, according to the summary.
The achievement of border security is based on maintaining that quota.
"If an Effectiveness Rate of 90% or higher for all High Risk border sectors is reached during the first 5 years after the bill is enacted -- the 'Border Security Goal' has been achieved," the summary reads.
The path to legal residency? Border security
The bill summary introduces two statuses on the pathway to legal residency: registered provisional immigrant (RPI) and lawful permanent resident. Neither is attainable without border security, with the exception of immigrants eligible for the DREAM Act.
"No immigrant in undocumented status may be adjusted to 'Registered Provisional Immigrant' (RPI) legal status until the Secretary has submitted to Congress the Notice of Commencement upon completion of each of the Comprehensive Southern Border Security Strategy and the Southern Border Fencing Strategy," the summary says.
To become an RPI, an undocumented immigrant cannot have arrived in the United States after December 31, 2011, and cannot have any felony convictions here or abroad.
But smaller offenses can also block residency; for example, if the applicant has three misdemeanor convictions, such as reckless driving, trespassing or vandalism. Voting illegally also makes one ineligible, and authorities can turn back applicants if they have certain infectious diseases or questionable "morality."
Time and money
Legal status can also be pricey. To become an RPI, the undocumented immigrant has to belly up a $500 penalty for having come to the country illegally and also pay any owed back taxes.
But once the applicant receives the status, the registered provisional immigrant may work for any U.S. employer and is free to travel outside the country. The status lasts for six years and can be extended for an additional $500 fee, if the applicant has not gotten into any trouble with the law.
After 10 years as an RPI, an immigrant may become a lawful permanent resident by following the same guidelines other immigrants must use to receive a green card, which includes a fee of $1,000.
Again, before any RPI is allowed to transition into lawful permanent resident status, the Southern border must be certifiably secure.
In addition, the secretary of Homeland Security must have "implemented a mandatory employment verification system to be used by all employers to prevent unauthorized workers from obtaining employment in the United States," according to the bill summary.
Meeting with Obama
Two senators from the "Gang of Eight" -- John McCain, R-Arizona, and Chuck Schumer, D-New York -- are to discuss the bill with President Barack Obama on Tuesday at the White House, according to a source familiar with the meeting. But the bomb attacks in Boston could disrupt scheduling.
Out of respect for the victims of the violence that marred the marathon, Schumer and McCain have canceled a news conference scheduled for Tuesday, when they had planned to present the proposed legislation to the public.
The other legislators in the "Gang of Eight" are Sen. Michael Bennet, D-Colorado; Sen. Marco Rubio, R-Florida; Sen. Lindsey Graham, R-South Carolina; Sen. Jeff Flake, R-Arizona; Sen. Robert Menendez, D-New Jersey; and Sen. Dick Durbin, D-Illinois.
Members of the Republican-dominated House of Representatives, which is typically more conservative than the Senate, are working on their own separate immigration overhaul, which also includes border security measures.