After you get married, he would have to file to sponsor you for permanent residency. You can read about it here: http://www.cic.gc.ca/english/immigrate/sponsor/spouse.asp
If you pick the forms for "my spouse is living with me in Canada", it is called an inland application and you would send it to Vegreville along with a request for an open work permit. If everything goes well and they are convinced your relationship is legitimate and your husband is approved as a sponsor, you can expect to see your open work permit in 5-6 months and PR maybe in 1-2 years. Two downsides with inland, you are not advised to travel while it's in process because it's based on you living in Canada and if it doesn't go well and they want an interview, they will send your file to your local CIC office for processing without the first stage approval and work permit. If that happens, it depends on how busy the local office is how soon you will get this interview. It can in some cases take up to 3 years. In the meantime, you are stuck in Canada waiting with no work permit.
If you pick the forms for "my spouse lives overseas" it's called an outland application and you can still stay in Canada and you can give a mailing address in Canada but write on the sponsorship forms that you request processing in your home country. Since you are legally working in Canada, you can also request processing in Buffalo. If you did this, there is no open work permit but the PR itself is normally faster. The file would be sent to Mississauga, they currently take 44 days to approve sponsor, see http://www.cic.gc.ca/english/information/times/canada/process-in.asp#sponsorship and after that the file goes to the country of processing and you can see the timelines to get PR here: http://www.cic.gc.ca/english/information/times/international/05-fc-spouses.asp The downside to outland is that if an interview is requested, you have to go to the country of processing for it.