In 2015 Gov. Jerry Brown signed a bill that prohibited California police and other state agencies from searching our phones and online accounts without our consent, a court order, or showing it is an emergency.

But a bill now before the state legislature would take away those rights from students and staff at California’s public schools.

The legislation, Assembly Bill 165, would “end the application of the Electronic Communications Privacy Act to a local educational agency, as defined, or an individual acting for or on behalf of a local educational agency.” The bill defines educational agencies as county offices of education, school districts and charter schools.

It has long been illegal to search through someone’s personal filing cabinet or the hard drives of their home or office PC without a valid court order, but until the electronic privacy act was passed, law enforcement could obtain access to someone’s web-based email account or cloud storage service on the theory that any data left on a server is “abandoned.”

That theory dates back to the time when off-premise servers were used simply to transmit data from one machine to another but, today, many of us store our most intimate personal data on services like Dropbox, Google Drive and Microsoft OneDrive and most people now rely on cloud-based servers to store and access their email and even their diaries and personal photographs. For most people, almost everything stored on cell phones is also backed up to cloud servers.

An article by student journalists Evalyn Li and Andrew Zhao in Gunn High School’s student newspaper, The Oracle, explained the pros and cons of AB 165. It quoted a Palo Alto school official that “the school district would exercise the power under this law for the safety of its students,” and another saying that he “believes that this legislation is meant to protect students from threats such as cyberbullying.” The same article also quoted a student leader who argued that if a school wants to search a student’s phone “there should be a warrant only because staff shouldn’t just get into other people’s personal property.”

In a blog post, the Student Press Law Center raised the issue of the bill’s potential impact on student journalists. The organization worries that, despite federal law protecting against “most newsroom searches and seizures,” this bill could “cause school or campus police to believe that there is no longer such protection, since there has never been an explicit ruling about how this applies to student journalists.”

The Electronic Frontier Foundation (EFF) argues that “AB 165 would destroy the privacy and free speech protections for Californians who attend or work in the public schools,” saying that it provides for “no outside oversight for searches of electronic devices or online accounts; no notice to individuals or parents and guardians; and no safeguards for what information is searched and how it may be used or shared, including with federal agencies.”

As The Oracle pointed out, one justification for AB 165 is to enable school officials to protect student victims of cyberbullying. As CEO of ConnectSafely.org and co-author of A Parents’ Guide to Cyberbullying, I support reasonable efforts to protect children from cyberbullying but there are plenty of resources available to educators, including obtaining evidence from the those who have been bullied and those who witness bullying. It’s rarely helpful to rummage through phones and records.

The vast majority of cyberbullying doesn’t rise to the level of criminal investigation. It’s almost always best dealt with by caring teachers, counselors, parents, fellow students and – yes – school resource officers, with the goal of helping everyone impacted. In those rare cases where access to digital data is required, authorities should be able to quickly get a warrant. CalECPA already allows authorities to conduct an immediate search if anyone is in imminent danger.

An Elk Grove News article about the legislative agenda of the bill’s sponsor, Assembly member Jim Cooper (D-Elk Grove) said that the bill “seeks to close a loophole that prevents school districts from inspecting district-owned iPad and electronic tablets on loan to students,” but my reading of the bill tells me that it’s much broader than that, essentially wiping out of all CalECPA’s benefits for those attending or working in schools.

The bill is opposed by a coalition of civil rights, immigration, education, youth, LGBTQ and internet safety organizations including the ACLU, EFF, Center for Media Justice, Council on American-Islamic Relations (CAIR) and ConnectSafely.org, the non-profit internet safety organization I co-founded.

This is a particularly dangerous time to pass legislation that would take away the privacy rights of students and educators, given the uncertainty around immigration laws and policies. I have heard from teachers about the emotional and legal state of their students and families who worry that changes to immigration laws or enforcement policies could separate parents from their children. One teacher told me that a parent from her school no longer drives her child to school for fear that she might get pulled over for a routine traffic violation and face deportation.

I would hope that even those who support stricter immigration and deportation policies would want to spare school children from being terrified about the possible implications should a school official be able to rummage through their phone or online data.

But even students and teachers who have nothing to fear have the right to digital privacy, regardless of where they are or what that they’re doing. As I walked by a local school this morning, I saw signs urging visitors to drive carefully, to donate to a local education foundation, and to attend a “Night of Fun” celebration, but there wasn’t a single sign informing people that their privacy rights don’t apply on school grounds. Let’s keep it that way.