U.S. officials say they have uncovered evidence that the Islamic State was using Mosul University laboratories to develop bombs that could pass through airport screeners undetected.

When the Islamic State, also known as ISIS, captured Mosul, it also took possession of the modern screening equipment at Mosul’s airport that would allow it to test its new bomb designs.

This previously classified information is thought to be the reason that the Department of Homeland Security barred laptops and other electronics larger than a smartphone from the cabins of incoming flights to the U.S.

In March, Homeland Security Secretary John Kelly implemented a ban that affected 10 cities from the Middle East and Africa. The ban affects about 50 flights a day from these areas in total.

Shortly after the U.S. announced the ban, the United Kingdom announced a similar standard for incoming flights to its own territory.

The Trump administration is also debating whether or not to expand the ban to European airports. However, expanding the laptop ban to include Europe would be much more costly than the existing ban and would affect up to 65 million people per year.

The Department of Homeland Security and Congress should consider a cost-benefit risk analysis and seek out alternatives to the ban.

The benefit of a laptop ban is that it makes it harder to use a bomb on a plane—though terrorists could overcome the ban by traveling from other regions not affected by the ban, or by designing bombs to go off remotely.

On the cost side of the equation, this policy would likely result in several billion dollars in losses to travelers and tourism, as well as increased potential for losses from theft or damage to devices and possible aircraft fires from electronics in the cargo hold.

In terms of alternatives, there seem to be several options.

First, the ban could be expanded even further, excluding large devices from planes altogether and extending the ban globally, as this would undoubtedly increase international security, though at even greater cost.

Second, risk-based screening policies could be applied at checkpoints that allow lower-risk passengers to proceed normally through airport checkpoints, but subject higher-risk individuals and bags to more stringent screening.

Third, an increase in bomb detection capabilities, like bomb-sniffing dogs or bomb detection equipment, could be deployed, though certainly at some cost.

Similarly, airports could improve their baggage screening equipment to stop bombs. Indeed, the Transportation Security Administration is testing new 3D checkpoint scanning technology to do just that.

This technology, called computed tomography, has been used on checked baggage for almost a decade, and it is now small, quiet, and cheap enough to be placed at security checkpoints across the country.

The scanner works by producing a 3D image that can be manipulated for a more thorough analysis. Moreover, this technology is expected to speed up the long lines that currently exist in airports because liquids, gels, aerosols, and electronic devices could remain in passengers’ carry-on bags.

Computed tomography is an example of a potential alternative that the Department of Homeland Security should consider when looking to improve aviation security. Going forward, the department should constantly explore solutions to keep pace with the constantly changing threat environment.