But after the scantron counts the votes - there has to be some way of collecting that data to send it to some central system, right? And I assume it is done through the internet. Does anyone have any details on how this step is done? Are there any security vulnerability on this step?
They read them on the machine and call them in by phone. Conceivably that could be hacked, but if so, it could easily be unhacked by recounting the votes. That may well be the most robust part of the process.
The most likely hacking method would be interfering with the software that runs the machines. This would have to be done by manually updating the machines after they are tested or hidden in the machine such that testing doesn't show it.
The most likely fraud method would be fraudulent absentee ballots. Since there is no verification of identity, they are essentially on the honor system. There have been some small scale frauds that way. For example, in Ohio in 2012, a woman's daughter filled out her absentee ballot for her. That was caught when the woman voted. However, many argue that this would be difficult to do on a large scale.
Did the polls miss?
A 4% polling miss (about the swing from the final polls to the actual election) is not that big. It's within the margin of error. Note that most polls don't rely purely on sampling. Instead, they adjust this year's voting patterns based on the demographics of past votes. So this year used the demographic assumptions from 2012. If those were incorrect, e.g. more whites and fewer blacks voted, then the polls would have been adjusted incorrectly.
What would cause that? There will be a lot of discussion in the coming days, but there are some obvious candidates. There is the "shy Tory" effect, which suggests that some people lie to pollsters because being a Trump supporter is unfashionable. There is also the Obama effect. As the first black president, he uniquely motivated the African-American community to vote for him. An uninspiring Clinton may simply not have motivated her supporters to vote. Trump actually won fewer votes than Romney in 2012, but Clinton did even worse.
Give it a week or so and people will probably work out an explanation. Someone will probably propose the correct explanation today, but it will take a few days for consensus to develop.