Earnings season for the quarter that ended Sept. 30 is underway, and while it's important to pay attention, one quarter won't cement your returns over the long run. It's best to take a much wider view of the stocks you're looking to buy.

So far this year, Palo Alto Networks (PANW -1.22%) and Zscaler (ZS -2.01%) have been delivering blockbuster results. By some metrics, growth in their respective businesses is even accelerating despite the slowing economy, and yet each stock is in the red for 2022.

Both companies sell unique cybersecurity products, and that's one expense their corporate customers have no intention of cutting -- even in the event of a recession, according to a recent survey of leading chief information officers by investment bank Morgan Stanley

Both Palo Alto Networks and Zscaler will report their third-quarter earnings in the middle of November, but here's why the results might simply be another piece in an exciting long-term story. 

Palo Alto Networks: An industry leader in multiple categories

Few technology companies have found immunity against the broader decline in the Nasdaq-100 stock market index, which lost 31% of its value year to date. But Palo Alto stock is holding up well, declining by just 11% over the same period thanks to its strong operational performance during 2022. 

The company leads the cybersecurity industry in 11 different categories, each of which is a subset of its three core areas of specialty: cloud security, network security, and security operations. The cloud is a particularly lucrative opportunity, as more companies shift their operations online, which balloons the attack surface and calls for advanced, around-the-clock protection from attackers that could be anywhere in the world.

Palo Alto's industry-leading position, combined with heightened cyber risks, resulted in large organizations rushing to use the company's products. At the close of fiscal 2022 (ended June 30), Palo Alto had 1,240 customers spending $1 million or more annually, which jumped 25% year over year.

This helped the company generate $5.5 billion in revenue for the fiscal year, a 29% increase compared to fiscal 2021, and it marked a faster growth rate than both the prior two years. In other words, despite the numbers getting larger and the economy slowing down, Palo Alto's business keeps accelerating. 

The company's heavy investments in growth and innovation come at the sacrifice of profitability. But fiscal 2023 could reverse those fortunes, as it estimates it will flip its bottom line into positive territory for the year on the back of as much as $6.9 billion in revenue.

And if that's not enough, Palo Alto stock has the overwhelming support of Wall Street, with not a single analyst recommending selling. Whether investors choose to buy in before or after its upcoming earnings report, November is as good a time as any to take a long-term position. 

Zscaler: A pioneer in Zero Trust technology

Zscaler solves some very important problems created by cloud computing technology, and it has become a cornerstone of many companies' cybersecurity strategy. As large organizations migrate to the cloud, it enabled them to assemble workforces that can be located anywhere in the world. While that's an advantage, it also presents significant challenges.

Granting network access to employees working remotely poses obvious cybersecurity risks: Are the employees' credentials secure? Can the organization be certain at all times that it's them accessing the network? If an employee's password or two-factor authentication method is compromised, how will the company know, and can it respond to the threat quickly? 

Zscaler developed Zero Trust to confront some of those difficult hurdles. As its name suggests, the technology assumes that all interactions with an organization's digital assets are hostile. All employees, regardless of existing permissions, will have their location, device, and role analyzed by Zero Trust so that it can form context around the interaction, increasing the likelihood of identifying threats.

But that's not the best part. Zero Trust only connects the employee to the application they're authorized to access, not the broader network, so in the event of a breach, the malicious actor can't move laterally across the organization's digital assets. 

Like Palo Alto Networks, Zscaler saw an acceleration in its business during fiscal 2022 (ended June 30). Zscaler's revenue topped $1.09 billion, a 62% jump year over year, marking the fastest growth rate since it became a publicly traded company in 2018. 

Past performance doesn't predict future results, but with another earnings report around the corner, a positive surprise isn't out of the question. Zscaler has several tailwinds, but increased cloud adoption is arguably the biggest because it means demand for Zero Trust will only grow over time. With Zscaler stock down 50% in 2022, investors might do well to buy the dip and hold for the long term.