It is now time for oral questions. I recognize the leader of the official opposition. Thank you, Speaker. My first question is for the Premier. Last Friday, a woman named Christine visited Queen's Park to talk about the minimum wage. She works four different jobs, all of them paying the minimum wage. Even working four jobs, she finds it hard to make ends meet. Raising the minimum wage to $15 an hour would make a big difference in her life. Does the Premier think she deserves a raise? Through you, Mr. Speaker and the Leader of the Opposition, everywhere I go, no matter if it's small businesses, medium businesses or large businesses, they tell me that Bill 148 is a failed liberal policy that is driving jobs and investment out of Ontario. Our Minister of Economic Development is reviewing Bill 148, holding roundtables with stakeholders and investors to determine the best way to move forward.  It is worse than the carbon tax. Matter of fact, it's equal to the carbon tax when it comes to job killings. TD Economics predicts that Bill 148 will result in 80 to 90,000 jobs lost on top of the thousands and thousands of jobs that have already been lost. Well, Speaker, it's my understanding that the Premier is visiting Alberta on Friday, and you might want to note that Alberta's NDP government just raised their minimum wage to $15 an hour. 16,000 jobs they gained in August, where this government lost 81,000 jobs. They're leading the country in GDP growth, Speaker, so he should learn those facts when he goes there. But one of the realities is that Christine is one of thousands of people who are struggling to get by on two or more minimum wage jobs, and she's scheduled to get a raise in January. If the Premier thinks that's too soon for Christine to get a raise, how long does he think she should have to wait to get one? Through you, Mr. Speaker, and the Leader of the Opposition, we're actually protecting the minimum wage. We aren't touching the minimum wage. We're going to make sure we attract investment, and I can't wait to go out west and talk about the worst tax ever with Premier Moe and Saskatchewan about the carbon tax. And then I look forward to visiting our friend, Jason Kenney out in Alberta. Mr. Speaker, because Alberta has dropped so low, I predict Jason Kenney will sweep Alberta and bring proper reform and create more great paying jobs like we are here in Ontario. This is about job creation. We said we're there for the people. We're going to continue representing the people by making sure we create an environment for great paying jobs. Start the clock. Final supplementary. Well, Speaker, the last time the Conservatives were in office, they protected the minimum wage and froze it for eight years running. For eight years running, people suffered greatly under that regime. But for Christine and thousands of other people struggling in tough jobs, the current minimum wage leaves them falling behind. As she put it, and I quote, you can't live in Toronto on that. You can't live anywhere in Ontario on that. You just can't. I'd like to say that that's after taxes. This is still the quote. But the truth is I don't earn enough to pay taxes. Eureka Moment. A young woman on four jobs earning minimum wage does not earn enough to pay taxes. She's looking forward to that race, Speaker. Why does the Premier think that she doesn't deserve one? Premier. Through you, Mr. Speaker. If the Leader of the Opposition would like to sit down at the round table with her, my minister, and listen to the job creators, listen to the small businesses, listen to the medium and large businesses, that Bill 148 is a job killer. We're going to protect the minimum wage. We're going to protect the frontline workers by lowering their hydro rates, by lowering their gas, gas by 10 cents a liter, making sure that we thrive in Ontario. We have seen 300,000 jobs leave Ontario. The biggest concern, Ohio is terrified, Michigan is terrified, and Seoul's New York State, because we're going to be more competitive than all the states that we've lost at 300,000 jobs. Question. Leader of the Opposition. Well, thank you, Speaker. My next question is also to the Premier. You know, the law in Ontario allows working people to take up to two paid sick days when they are ill. Does the Premier think Christine and working women and men like her should be able to take a paid sick day when they're ill, or is that a benefit that he plans to take away? Premier. For you, Mr. Speaker, we're going to send a clear message to the world that Ontario is open for business. They come to Ontario because we will be competitive. We'll create thousands and tens of thousands of jobs. Mr. Speaker, I'll never forget when I went to Renfrew, Minister of Transportation, John Yakibusky, and I saw 20 people, 20 people with disabilities come up to me and say, Doug, I lost my job because of Bill 1 of 48. These are young people and young adults with autism that thousands across the province lost their job because of Bill 1 of 48. Students lost their jobs because of Bill 1 of 48. We're going to create jobs. We're going to make sure we hire students, hire people with special needs. We're going to support the frontline workers of this province. Supplementary. Well, Speaker, it's really taking the province backwards when a Premier believes that open for business means being punitive to workers. I think we can have it open for investment and business, but at the same time treats its workers with dignity and respect. That's right. The law in Ontario allows working people to take leave, to care for family members in an emergency without losing their job. Does the Premier think Christine should be able to care for a sick family member in an emergency and still keep her job? Or is that a protection that he plans on taking away? Premier. For you, Mr. Speaker, I just want to remind the Leader of the Opposition there's 385,000 regulations here in Ontario. Those are job killers. We have a round table put together and I encourage the Leader of the Opposition rather than penalized companies, small companies, medium and large companies, why doesn't the Leader of the Opposition sit around the table? The red tape, we're going to cut the red tape, we're going to cut the regulations, we're going to make sure we make Ontario open for business. Well, Speaker, I've been talking about sick days. I've been talking about emergency leave and I certainly haven't heard the Premier once stand up for everyday working people and say they deserve a fair shake. And this province are falling behind and they fell behind when the Conservatives were in office and froze the minimum wage for eight years. They fell behind for 15 years and the Liberal Government raising the wage for 15 dollars an hour in our province allowing people to take the sick day and care for loved ones or always to ensure that hardworking people can pay the bills, can pay the rent to see our ways rather to make sure that people can pay the rent, pay the bills, see their families. These are things that we would expect any worker should be able to enjoy. This is not Victorian England Speaker, this is the province of Ontario in 2018. Why is the Premier opposed to things like a 15 dollar minimum wage? Pay time off when you're sick and making sure people can take an emergency day when their family needs them. For you Mr. Speaker, I just want to remind the Leader of the Opposition of the Ray days, the NDP days. Thousands of people, 700,000 people lost their jobs. They increased our debt by 60 billion dollars. That was the beginning of the end of the NDP. We saw the five years of destruction under the NDP. We're turning the corner. We're going to be the most prosperous province in the country. We will thrive with opportunity and prosperity, the likes of which this province has never seen. Next question, Leader of the Opposition. Thank you Speaker. My next question is also for the Premier. Almost a year ago today the Health Minister for the Liberal Government proudly announced that they would be investing 100 million dollars to help hospitals deal with hallways during the flu season. A year later patients are still stacked in hallways but it's a conservative government making the same empty announcement. Patients languishing in hospital hallways expect real action. Why is the government offering Liberal Band-Aid funding repackaged as a conservative plan instead of doing something tangible to end hallway medicine? Mr. Health. Leader of the Official Opposition for Primary Campaign Commitments was to end hallway healthcare. We are working on having an advisory council that is advising the Premier and me on ways that we can take because it's a multi-faceted problem. It involves moving patients or alternate level of care who don't need to be in hospital to appropriate places, long-term care homes. That was another one of our major commitments which we are also working on. It's also about developing a comprehensive mental health and addiction system so that people don't need to be in crisis and have to go to emergency departments that they can receive care in a proactive way. We are working on both of those issues right now. We are investing more money into it and we have a further announcement after today we will have an announcement that we will be making with respect to that specific issue. Complementary. I may be incorrect speaker but what the minister was acknowledging is that the 90 million is not for hallway medicine. Patients who need care are left sometimes for days in hospital hallways. I saw this myself when I visited Thunder Bay Regional Health Centre where they have been operating at surge capacity for years now and instead of help the Conservatives offered cuts to mental health funding to the opioid crisis all of which forced people back in the emergency rooms. We here really believe that warming up the same tired liberal plan is going to make a difference for patients stuck in hallways in hospitals. Minister Bell. Thank you Mr. Speaker and through you speaker to the leader of the official opposition you are not correct with what you just stated. We are investing addiction system which is an increase. $3.8 billion over 10 years is a major increase in intensive and coordinated system to get people the help that they need but we also do recognize that with flu season upcoming a lot of the hospitals that are already at 100% capacity are going to face additional stresses and strains. We have dealt with that. We have a plan with that and we will be announcing that later today. So I hope you will be listening to that. Next question. The member for Kitchener South Hespler. My question is for the minister of economic and trade. The constituents in my riding followed the free trade negotiations between Canada, the United States and Mexico closely. Hundreds of thousands of jobs across Ontario depend on free and fair trade with our largest trading partner. Nearly 9 million American jobs depend on Canada, US trade and investment. And approximately 400,000 people and $2 billion in trade every day travel across our border. And the uncertainty for our dairy farmers and steel producers is of great concern to our premier and to myself and the people in my riding. Can the minister please inform the legislature how our government for the people is protecting job creators like Toyota in Kitchener South Hespler? Minister of economic development. Thank you Mr. Speaker and I thank my honorable colleague for a very good question and like the member for Kitchener South Hespler I was fortunate enough to tour the and met with the Toyota plant in her riding and met with the workers and the management and we were very much impressed with the work that they do, the cars they produce they've won many international awards in fact I think one of the companies in the world that's won so many awards in the automotive sector and the workers really asked us to look after their jobs and protect their jobs and that's exactly what our government for the people has been doing to do that every single day and more recently more recently we're disappointed the federal government hasn't been able to get the tariffs taken off of steel and aluminum that's starting to affect companies like Toyota so there's more work to be done and Premier Ford will be there, I'll be there I know their honorable member will be there we will protect those jobs and stand up for Ontario workers Thank you, supplementary Thank you Speaker and thank you to the minister for his response I appreciate the work our government is doing to protect the auto industry and by extension the Toyota plant in my riding I was certainly honoured to tour that facility this summer with Minister Wilson Parliamentary Assistant Skelly and MPP for Cambridge Carahalios Parliamentary Assistant Skelly has also been speaking to businesses large and small and workers across the province including in my riding on trade relations between Canada, the US and Mexico After 13 months of uncertainty and free trade with the United States and Mexico it is positive to see a deal and to know that our government stood up for the people every step of the way Can the minister please inform the legislature what work is left to be done Minister Thank you Thank you colleague and speaker indeed you know we have mixed reviews on the new NAFTA on the one hand as the honorable member said it's good news the threat of tariffs of future tariffs on auto and auto parts this is a special section to protect us against 232 should the US ever decide to do that they can't do it under NAFTA however the 1962 law of national security allows them to continue to do in spite of NAFTA to continue to put punitive tariffs on steel and aluminum they're there today and on any other commodities services that they may want in the future and the heck with NAFTA so the federal government left a NAFTA and you can drive a truck through hopefully a Toyota truck right through because these 232 tariffs so what work is left to do they have to get back to the table before they sign this deal at the end of November and look after those punitive tariffs Restart the clock Thank you Mr. Speaker this question is for the minister of health and long-term care years now hospital throughout our province have been operating at over capacity that means that every night there are thousands of Ontarians patients that are crammed into bathroom, shower room, TV room, storage closet anywhere you can fit a bed or a stretcher in Sudbury health sciences north is presently at over capacity and they are expecting a surge with the flu season just around the corner the Ontario hospital association tells us that they need a minimum of 300 million dollars just to maintain what we have not to fix it does the minister believe that 90 million share between 150 hospitals will fix hallway medicine in Sudbury and prepare them to care for us when the flu season surge starts Mr. Vell from long-term care the member very much for the question is we are aware that many hospitals across Ontario are operating at over 100% capacity and this puts good patient care in jeopardy with the flu season approaching and any one patient that's being treated in a hallway is one patient to many as far as I'm concerned they deserve better many are seniors they deserve to be treated in a proper hospital room and for healthcare professionals that are attending for them that is not the kind of care that they want to provide either so we have anticipated the flu season we are providing relief across Ontario we are injecting 90 million dollars into it but there's more than that we will be making an announcement about that shortly afternoon today so should you have any questions following that I would be very pleased to answer them supplementary thank you speaker Thunderbury regional hospital like so many other hospitals has been operating at over 100% capacity last January they had 447 patient in 375 beds strong and mad speaker that 72 patient who were cared for in corridors bathroom TV lounge anywhere but a hospital room the situation in Thunderbury is still very dire as they continue to provide quality care while trying to provide quality care you cannot provide quality care in a hallway it is not possible does the minister think that investing a thousand beds among 150 hospital will fix the hallway medicine crisis in Thunderbury and will prepare them for the surge with the flu around the corner minister I would say to the member that this is a situation that has been growing over a number of years this didn't just happen after June 7th it's been growing for 15 years so we need to deal with that and there's not going to be one simple solution that's going to come forward that we're going to be able to instantly end hallway medicine I agree with you no one deserves to be treated in a hallway or a storage room we are taking steps to deal with it it is a multi-faceted problem it does involve people that are ending up in emergency departments but can't get to a room with the alternate level of care patients who don't need to be in hospital but can't go home they can't get enough services and there's no long-term care home to go to for them so we have to build in steps along the way to make sure that patients get the care that they need we are working on it are the steps that we're going to take today going to end hallway healthcare no unfortunately not we are working on a long-term health capacity plan that we will be working on thank you next question the member for atopico lake shore thank you mr. Speaker my question is for the minister of economic development job creation and trade our government for the people is committed to creating and protecting Ontario jobs by setting the message that Ontario is open for business after 15 years of failed liberal policies that voted for the radical NDP that voted for the formal government 97% of the time on June 7 voted for relief while relief is here could the minister please inform the legislature of the details surrounding Spotify's recent investment announcement in Ontario minister of economic development thank you mr. Speaker and thank you the member for atopico lake shore for the question was pleased Shopify's recent announcement I was pleased to tour Shopify this summer when I was in Ottawa and last week Shopify announced its plan to invest up to half a billion dollars in a new Toronto office this office will be home to thousands of new employees our government for the people is thrilled the suspension is taking place right here in Ontario you know Shopify had the world to look at mr. Speaker and they chose Ontario and they made that promise on June 7 and a series of meetings that we had so we are very very very pleased that Shopify has got the message that Ontario is open for business and in the supplementary I'll mention some other companies they got the message thank you speaker and thank you to the minister for his response and for all the great work you are doing to getting our economy in Ontario moving once again last many years I have heard in the riding of atopico lake shore that life under the previous Liberal government has gotten far too expensive that is why our government for the people is cleaning up the hydro mess consulting with businesses on red tape and lowering taxes can the minister inform the legislature of recent investments in Ontario I should know that Shopify is making this half a billion dollar investment in Ontario without a government so Mr. Speaker those days they have the insurances of the and the word of the premier of Ontario and all of our caucus on the PC side that we are going to cut red tape we are going to make the regulatory environment easy for businesses to create jobs and Ontario is open for business and all that entails including bill 148 I say to the people on the other side as I've already mentioned this legislature Mr. Speaker Amazon and Instacard have both recently announced Ontario CBS television studios just this week announced it will open a 2,600,000 square foot production hub in mississauga and AP AG electronic and automotive electronics and lighting company is setting up its headquarters in Windsor creating 148 jobs together these announcements means thousands of new jobs good paying jobs across Ontario and Mr. Speaker jobs are our number one priority and we're not going to give up and work in this province as a job Thank you Speaker the Minister of Environment Conservation and Parks last week the Auditor General released a special report on the Niagara Peninsula Conservation Authority the report shows the MPCA is having difficulty fulfilling its mandate it is plagued by financial mismanagement a high employee grievance rate and conflict of interest issues we've seen the MPCA fire key staff censure board members lobby the government to develop on provincially significant wetlands and even sue a private citizen the Auditor General herself recommended that the province could do more to oversee the MPCA will the minister hold the MPCA accountable and appoint a supervisor to oversee the implementation of the Auditor General's recommendations Minister of Environment Conservation and Parks Mr. Speaker I thank the member for his question as not everybody may know the Standing Committee on Public Accounts asked the Auditor General to look into the the MPCA as a result of some concerns that were raised that report was delivered last week by the Auditor I do want to make sure that we thank the Auditor for her recommendations they were a very balanced set of recommendations and we have reviewed them and are going to be working with municipalities to see where we can support conservation authorities better in terms of the governance of those authorities and how we work with them to make sure they have the resources involved I should say Mr. Speaker that we are assured both by the Auditor's reporting and her review as well as the other work we've done that this does not the concerns that were raised in Niagara are not concerns we have for all conservation authorities but be assured we take this we take the report very seriously including the area to support the conservation authorities Supplementary Thank you for the response Minister former MPP Cindy Forrester has asked the previous government to interview in the issue of the MPCA since 2014 Conservation authorities are created to advocate for conservation in order to maintain the balance between the environment and development Speaker the MPCA continuously advocates for the latter one of the major findings in the audit is that the MPCA is not responding to local complaints when the Conservation Act is violated it's clear we need a supervisor a clean sweep of the board and changes to the Conservation Act to ensure that at least 50% of the board are community members with a working knowledge of conservation to the Minister as he prepared to make these changes and work with local area MPPs to implement the Auditor General's recommendation Minister to be clear the Auditor General's recommendation was that there needs to be work done I was pleased to see that the Conservation Authority in question did embrace the recommendation and has agreed to and is already implementing a number of them there are interesting issues raised by the Auditor General with regards to governance in particular the role of board members vis-a-vis the municipality and how they need to approach that in the future so we're looking closely at those items and we'll ensure that we work with municipalities to make sure that the 36 Conservation Authorities across the province are well managed and governed next question the member for Guelph thank you Mr. Speaker I'll direct my question to the Minister of Economic Development Minister I think your government is making a false choice between supporting small businesses and minimum wage workers to $15 an hour makes life more affordable for families and provides them with more money to spend in the local economy supporting local businesses and lowering payroll taxes on small businesses provides them with immediate cash flow relief to create more jobs and to pay higher wages so I asked the Minister if the government will support local job creation by committing to lowering payroll taxes on small businesses by doubling the employer health tax exemption and at the same time raising the minimum wage to $15 an hour on January 1st Minister of Economic Development well thank you to the Green Party for the question we just had the most significant lowering of payroll taxes in my 28 years here with a $1.45 billion injection into businesses particularly small businesses with the decrease in the premiums of the WSIB that's the largest investment I've seen in job creation in years the books are balanced now at WSIB so premiums can come down I think Minister Labour tells us an average of 30% some sectors much higher than that that's fantastic news I think that's what we believe of Ontario is open for business I know that our hard-working finance minister Mr. Fidelli is looking at every tax we have and every burden we bring in as I'm doing as my parliamentary assistant Mike Parsa is doing to make life easier for small and medium-sized businesses the greatest dignity we can give a human being is the opportunity for a job that's what we believe like we saw on the previous Liberal Government Order Order House will come to order Minister of Transportation will come to order I can hear you start the clock supplementary Minister the Canadian Federation of Independent Businesses for years has been calling for lowering payroll taxes on small businesses by increasing the exemption level for the employer health tax at the same time raising the minimum wage to $15 an hour will put an additional $2,000 in the pockets of minimum wage families both of these policies provide more money for small businesses to create jobs and more money for local workers to spend with small businesses and local economies so I ask again will this go through you Mr. Speaker will you give government support minimum wage workers by raising the minimum wage at $15 an hour while supporting small businesses at the same time by lowering their payroll taxes Minister Minister of Finance Minister of Finance Thank you very much and thank you for the question everything that we have done is for the people we are bringing relief for families we are returning prosperity to the people of Ontario Wilson said we're open for business, a billion and a half dollars back into businesses to reinvest through the WSIB. Scrapping the cap and trade, putting 285 dollars, 4.3 cents on its way to 10 cents a liter. Lowering corporate tax rates from 11.5% to 10.5% so those businesses can hire again. Lowering the small business tax rate by 8.75%. 20% tax cut for middle income families. Hydro rates going down 12%. Getting out of costly wind and solar projects. Saving 790 million dollars over 16 years. That is all about bringing real, real relief to families. Order. Start the clock. The member for Mississauga Center. Education. This week we learned that for the third time in history, a woman was awarded the Nobel Prize in physics. From Guelph, Ontario, Dr. Strickland is an associate professor of physics and astronomy at the University of Waterloo. Her work has mostly been focused in the laser physics field. Alongside her colleague Dr. Marou from France, she developed technology known as chirped pulse amplification. This work has led to a number of inventions that we are all familiar with such as laser eye surgery. Dr. Strickland is a testament to the potential of our students and girls right here in Ontario. Can the Minister of Education tell us what our government is doing to ensure that Ontario students will continue to be global leaders in subjects like math, science and technology? Thank you to the member for Mississauga Center. She herself is a wonderful role model for girls and women throughout Ontario. I am proud of the PC government and as Minister of Education to recognize and congratulate Dr. Strickland for her incredible achievement. As we heard earlier today, October 11th is National Day of Girls. It is important that we recognize her role models. Her success is also a tribute to the calibre of academics we need right here in Ontario. Since day one, it is the PC government that has been committed to providing that quality of education. In today's world, our needs are constantly evolving and it is important that we provide world-class education fields like STEM, science, technology, engineering and math. We have already started by scrapping discovery math, a failed method of teaching that only left our students behind. In Ontario, we have some of the best teachers in the world, but it is up to the government to set the baseline for what students should be learning and we are doing it. To the Minister, thank you for that response and thank you for all the hard work that you are doing to ensure that our students succeed today and tomorrow. I am happy to hear about how important teachers are to this province. Many of my good friends chose teaching as their vocation and I am so proud of the work that they do in inspiring students to reach their full potential. I am equally as pleased to see that as part of the education consultations, parents can tell the government about a teacher who has gone above and beyond to support their child's learning. However, Mr. Speaker, parents in my writing have also expressed their interest in doing more to ensure their child is prepared for the future, especially when it comes to skills and subjects like math, science and technology. I think we can all agree that parents, guardians and student support systems are the most important partners that we have in education. Can the Minister explain how the government will continue to involve parents in their child's education? Minister. Thank you, Speaker. There is no doubt that in order to prepare our students for the future, we need to support students starting right here within our homes. It's all about getting back to the basics. We've provided parents with a fax sheet so that they can be engaged as well, outlining learning expectations when it comes specifically to mathematics. This fax sheet suggests how parents can involve their parents and children in everyday opportunity to learn the fundamentals of both math, whether it be at school or at home, there's always an opportunity to engage children in mathematics fundamentals. Our government believes its attitude and plans for the education of our children that will prepare our students for success, like Dr. Strickland's. Mr. Speaker, I would like to remind every member in this House that our education consultations are now open. We're welcoming written submissions. Thank you very much, Speaker. My question is to the Minister of Economic Development and Trade Speaker. Yesterday, we heard a lot of talk from that side of the House on what the federal government needs to do to support our dairy farmers in the wake of the renegotiated NAFTA agreement. But what we didn't hear was what this government is prepared to do and going to do to help farm families that have been hurt by this deal. This government talks a big game about supporting our farmers. Well, here is your chance to actually prove it. Will the minister step up to the plate and support our farm families if federal support is not forthcoming? Minister of Agriculture and Food and Rural Affairs. Minister of Agriculture, Food and Rural Affairs. Well, thank you very much, Mr. Speaker, and I think the member for the question. And obviously it's a grave concern with us about the impact that this trade agreement will have on our farming communities. Obviously, the farmers are the bedrock of our communities. And when one sector of the economy in rural Ontario is hurting, the whole community is hurting. So we want to make sure we put, as we started this process, we had a federal government said they were going to stand with them protecting our supply-managed sector in our society. We said we would stand shoulder to shoulder with them. That they've let us down here. They've also now said that they are going to make us whole by presenting a package, a funding package, that will in fact cover the cost of what this trade agreement, the impact this trade agreement will have on our rural communities. And we will hold it free to the fire. The rural government has a responsibility to live up to the actions of the cost of their actions. Thank you very much, Speaker. With all due respect, Speaker, the members of the opposition don't have the same blind faith in Justin Trudeau to come to the rescue as the Minister of Agriculture does. The question is back to the Minister of Economic Development. If the government is not going to do anything to help support our farm families, maybe they'll do something for our steel and aluminum industries. The steel and aluminum tariffs have been in place since June 1st. Our other provinces have stepped up and offered support for their producers, but Ontario so far has done absolutely nothing. Will the Minister commit today to developing a support package for Ontario steel and aluminum producers, now that we know that those tariffs will continue to be in place? The Minister of Agriculture and Food. He can refer back to the Minister of Economic Development. Well, thank you, and I just say to the honourable member across the way, ye of little faith. Well, the Prime Minister has put forward $2 billion to offset the damage that's been done with U.S. tariffs on steel and aluminum. And, you know, the premise of the question that Ontario doesn't do anything, I, this government, moments after we got the text of the agreement on Sunday night and all of Monday, were the only ones in Canada saying, hey, he's left us out to dry on dairy. It took days, it took a couple days for other people stood up, and we pointed out that the truck that you can drive through NAFTA, which are these punitive tariffs, beginning with steel and aluminum, and God knows what else they feel like doing in the United States to hurt our economy, to drive jobs to their economy. We're the ones standing up for jobs in Ontario and in fact for jobs in Canada. Member for Timmons, come to order. Start the clock. Next question. Member for Mississauga Streetsville. Thank you, Mr. Streetsville. My question is for the Minister of Children, Community and Social Services. I, like many of my colleagues in this house, have had requests for assistance from individuals who have come to Canada through proper immigration channels to work in fields where we have a shortage of skilled trades. We welcome people who want to work hard and contribute positively to our economy. As a prime example of how the federal immigration system is ineffective, an individual case caught my attention. This individual went through the legitimate application process and obtained a work visa. Unfortunately, through a minor clerical error, this individual and his family will be deported this Friday. As a result, we are told that Immigration Ontario cannot assist with his claim, but must be referred to the federal level. Mr. Speaker, what is Ontario doing to help legitimate immigrant claimant issues? Minister of Children, Community and Social Services. Thank you very much. I appreciate the members question from our side of the house. As I previously mentioned on this matter, Ontarians are quickly losing faith with the federal government's ability to handle the issues at the border, our immigration process and the refugee process. I'll remind this House that the federal government has sole jurisdiction over border security and refugee claimants. As a result of that, that's why we're calling as a part of this government, for the federal government to pay $200 million and growing as a result of the pressures on our social assistance costs, temporary shelters in our two largest cities, $20 million in growing and education costs, as well as additional costs with respect to legal aid, child welfare and the Red Cross. So I will simply continue to call on the federal Liberals to fix their flawed system so that legitimate claimants will have a shot at actually getting in. Thank you. Supplementary. Thank you, Mr. Speaker, and thank you to the Minister. I'd like to describe this situation a little further. Minister, this individual came to Canada with his family on a work visa, and as a result, the individual and his family wished to stay. He withdrew his original application and reapplied to the Ontario immigrant nominee program, but realised that he had applied to the incorrect job. We have a federal government who ignore their responsibility for those crossing at illegal points of entry, but throw the book at you for checking off the wrong box on an application form. Will the Minister stand up for skilled newcomers looking to make Ontario home and urge the federal government to take responsibility for their policies that have led to illegal border crosses? Good question. Minister. I very much appreciate that question, and almost immediately after becoming the Minister responsible for immigration, it did two things. One is to hold the federal Liberals to account on the escalating costs that we have seen as a province, which is $200 million in growing. The second thing is we've requested and we are going to hopefully receive more additional economic immigrants so we can work with the Minister of Economic Development and trade to ensure that there are more skilled workers coming into Canada as a result of that program. But let me be perfectly clear, we have a broken border. Canadians, particularly Ontarians, are losing confidence in the federal government's ability to manage the illegal border crosser issue in the province of Quebec that is having a very big impact on us in our province. So I just want to be very clear. There are people right now that are on welfare roles in Ontario that could be there for up to two years and then deported. We are calling on the federal government to process with refugees and I'm not the only one because I'm going to read with John McKay of Federal Liberal MPP that says the only fair thing to do for everybody is to process them quickly and I think that's where the government's weakness is. Thank you. Next question to the member for Windsor West. Thank you, Speaker. My question is to the Minister of Health. On Friday the Minister received an open letter signed by 18 healthcare leaders across Ontario urging her to take immediate action and open more overdose prevention sites. One of the signatories is the Windsor Essex Community Health Centre. The letter states, and I quote, since supervised consumption services and overdose prevention sites began opening in mid 2017, they've already saved 917 lives by reversing overdoses. That's 917 families who didn't receive the worst news possible. That's 917 people who still have a chance to build a better life. Will the Minister listen to these experts? Will she open more life-saving sites? Minister Health. Thank you to the member very much for the question because every loss of life is tragic and we have lost too many lives in Ontario so I do take this very seriously as does everyone. I'm sure in this House and so that is what I have been listening to for the last several months I have been listening to the people who are the experts, the people who run the supervised consumption sites and overdose prevention sites, people with lived experience, neighbours, community centres and so on. I have been speaking to all of the people that want to have something to say on this issue. I am in the process you are no doubt aware that we have applied to Health Canada in order to have the exemption extended for another six months while I finalised my recommendations to the Premier which will be finalised very shortly. Complimentary. Thank you Speaker. Back to the Minister. Windsor continues to startle with rising poverty. One in four children now grow up in low income households. Our community has also been hit particularly hard by the opioid crisis. So much so that local harm reduction workers and advocates are planning to open an unsanctioned overdose prevention site because they just can't wait any longer for this Conservative government to step up to the plate while members of our community die needlessly. But opening this site means that they are risking criminal prosecution. Is this government really comfortable with harm reduction workers and advocates being treated like criminals just because they are trying to save lives? There is no doubt that this is a very serious issue and one that I know that everyone wants an answer right away but the Premier has indicated that he wants to make a proper evidence based decision and I don't think anyone in this house would disagree with that. So that is what I have been studying. That is what I am going to be recommending to the Premier and of course there besides saving lives is of course very important. But the other part of it is also very important that you want to be able to help people get into treatment and rehabilitation so they can help improve their lives. You have to do both. Both are very important but that is part of the recommendations I am going to be making to the Premier to discuss these situations and he will be making a final determination we are working with his office right now and there will be a decision and announcement to be made in very short order. Next question the member for Carlton. Thank you Mr. Speaker. My question is for the Minister of Agriculture Food and Rural Affairs. As we celebrate Ontario's 20th Agriculture Week I am reminded of farmers in my writing of Carlton. Farmers like Graham Green and Janet Aker Smiley and all they do to put food on Ontario's tables. However it has also been a tough week. The USMCA will result in significant market access being given to the US and Ontario's farmers. It is disappointing that our federal counterparts have created this uncertainty for our agriculture industry. Last week our Premier and Minister of Economic Development job creation and trade went to Washington sending a strong message that Ontario's farmers remain top of mind. Mr. Speaker through you. What will the Minister do to ensure the federal government will keep the concerns of our farmers? Thank you very much Mr. Speaker and thank you very much to the member for the question. Our farmers are the bedrock of our community and we are reminded of their contributions during Ontario's 20th Agriculture Week. Indeed it has been a rough start for the week for our supply managed sector following the USMCA. However the Premier and I have taken immediate action to do everything in our power to help our farmers manage stakeholders to assure them that we are calling on the federal government to compensate our farmers for their losses. The federal Minister Freeland has mentioned our farmers will be compensated fully, fairly and for the concessions that they've made and we will hold them to account for that. Protecting our farmers ensures that our food is protected safe and of the best quality. Our farmers will continue to review the USMCA. Thank you very much Mr. Speaker. Supplementary. Thank you to the minister for that answer. I'm proud to be part of a government that stands up for its farmers and appreciates their contributions to our communities. I look forward to working with our government to ensure we can assist Ontario's farmers to the best of our abilities and to urge the Trudeau Liberals to support our farmers. Mr. Speaker, back to the minister. Can the minister please tell us what else he is doing to what else he is going to do to create an environment that is supportive and open for business for our farmers. Thank you very much Mr. Speaker and I thank the member for the supplementary question. I also wanted to thank all the caucus members yesterday who took time to visit and take pictures of our farmers this week. Mr. Speaker, as mentioned before, our government is committed to standing up for our farmers. As we continue to review the USMCA, we will work with our farmers and urge the federal government to compensate them accordingly. Our natural gas expansion plan, if passed, will put more money into the pockets of farming families and businesses so they can continue to provide for more of the best quality food. Our plan is to put more money back into the pockets of taxpayers. We're cutting red tape and regulations as seen first through our changes to our wildlife damage compensation program with more announcements to follow. On June 8, our government was elected to make Ontario open for business again. We have taken immediate action to make life more affordable and efficient for our farming. Thank you very much. Thank you. Start the clock. Thank you very much, Mr. Speaker. My question is to the Minister of Community Safety and Correctional Services. Four years ago, Maureen Trask, a parent, came to me looking for help to find her missing son, Daniel. After countless petitions to this house and a motion calling for missing persons legislation, Ontario's First Missing Persons Act was passed this past spring. I want to thank Maureen for her advocacy. She turned her grief into action in this province. But because it is part of the Safer Ontario Act, it's on hold. This government has put that act on a pause. Can the Minister provide an update as to when the Missing Persons Act will come into effect in the province of Ontario? Minister of Community Safety and Correctional Services. Thank you, Mr. Speaker, and thank you for the question and for giving me the opportunity also to give an update. I'd like to begin by stating that, in fact, my staff has already been instructed to begin the work on developing the necessary regulations to bring the Missing Persons Act to life. Mr. Speaker, the Missing Persons Act once enforced will address a current barrier faced by police in Ontario in investigating missing persons occurrences by providing police with tools to use of circumstances where there is a crime has been committed. The Missing Persons Act will allow police to apply for judicial orders to access records such as information about travel or telephone and other electronic communications or to authorize entry into premises to search for a missing person. Thank you, Mr. Speaker, and it's good to hear that the ministry is working on the regulations, but the act needs to be brought to this legislature in order for those regulations to be brought to action. Maureen is one of the strongest advocates for the Missing Persons Act, and Ontario is one of the only provinces that does not have this legislation. Maureen was briefed by ministry staff on the legislation development, but because it was her family's experience, losing Daniel drove the creation of this act in the province of Ontario, yet since the election, that communication has unfortunately broken down. After Maureen's tireless effort and to people across this province to provide an answer and to bring the legislation back into this house, what is the status of the Missing Persons Act coming back to the Ontario legislature so that we can have this act across? Thank you, Mr. Speaker, and thank you once again for that question. I'd like to repeat that my ministry takes this matter very seriously, and my staff has already been instructed to begin development of the necessary regulations to bring the Missing Persons Act to life. The Missing Persons Act will provide the men and women of our police services with the tools necessary to more effectively conduct investigations into matters regarding missing persons. Thank you. Next question, the member for Burlington. Thank you, Mr. Speaker. My question is for the Minister of Seniors and Accessibility. I learned yesterday that we have a lot of seniors from across the province on National Seniors Day. Can the Minister share with this house why seniors like myself are important to this government? Minister responsible for seniors. Minister responsible for seniors. Thank you, Mr. Speaker. Through you, I'd like to thank the hardworking MPP from Burlington. I appreciate the opportunity to speak to Monday's celebration and acknowledging the contribution of seniors was important to me and worthy of collective support. Our seniors are the foundation of our society, this province and this great nation, Canada. Mr. Speaker, great deal to the women and men who helped build our province and our country. Right now there are 2 million seniors in the province and in 25 years the number will double to 4 million. I want to be clear, Mr. Speaker. We intend to support every step of the way. Seniors are living healthier, independent and more socially engaged. Mr. Speaker. Supplementary. Thank you, Mr. Speaker. Back to the minister. Can the minister let this house know just how this government intends to support the seniors of Ontario? Minister. Thank you for your practical question. Mr. Speaker, Premier Doug Ford and this government have the highest regard for Ontario's seniors. I stand with respect to be at the heart of everything we do as a government. At the AMO conference last August I met so many mayor and councillors. They are working so hard to build the age friendly initiative in their municipality. I have also attended many events such as the recent Ontario seniors community association where I met Alison. I also visited two excellent senior living centre in Ottawa. Mr. Speaker, we reached out to Ontario seniors through so many excellent hard-working stakeholders who share our passion and commitment. Next question, the member for London North Centre. Thank you, Speaker. My question is to the minister about the Government's services. Mission services which operates London's Roth home, women's and family shelters in crisis. The shelters operating at 195% capacity with 20 families filling the shelter and another 19 spending their nights in motels. In July we asked this Government if they would open provincial and federal owned properties to deal with the unprecedented and alarming demand for housing. I would like to know how many children and community in social services will continue to serve our most vulnerable? Thanks very much for the question. I very much appreciate it particularly since today we will be celebrating marking International Day of the Girl later on this afternoon. I can tell you that violence against women is a very important priority for me and I have been working on this for a long time. I appreciate your question. I'm interested in learning more about your specific issue and so we'll have that conversation after question period if that's okay with the member opposite. But I want to be very clear. It's really difficult for the member opposite to equate what's happening with the illegal border crossing and the asylum seekers that are filling up the shelter capacity in the City of Toronto and in the City of Ottawa when at the same time we're trying to help the minister responsible for community and social services to working with the member opposite and we're going to continue to invest more money into this area and I can say that in 2017-2018 we invested $160 million into this area. Thank you Speaker. While I look forward to meeting with the minister I'm concerned about the people who are not being served right now. Calling this a refugee crisis is calling it by a different name than what it actually is. There are people who are in crisis right now. There are people who are homeless and that answer does nothing for people who are homeless right now. Shelters like Roth will need the government to step in immediately. We've seen social assistance increases and social housing repair funding slash by all of this government all while misusing the word compassionate. We need something done now. We need the minister to step in today and deliver the relief that the people of London desperately need. Minister. The opposite is confusing the situation that is happening in the City of Toronto and the City of Ottawa with what's happening in London and I can tell you that the capacity that we have in our shelter systems has been impacted significantly and I would like the member opposite to join us in asking for the federal government to come to the table with $200 million so that the people who are most vulnerable in my ministry which are women escaping violence which are women who are being trafficked which are children at risk and children in the justice system and those who are developmentally disabled they deserve the funding Mr. Speaker I have no idea why the members opposite won't join Ontario's calls every single previous. It's the time for question period today someone sent me a message indicating they wanted a point of order but didn't sign it. Someone wanted to correct their record is there a point of order? OK Minister of Agriculture Food and Rural Affairs Thank you very much Mr. Speaker on a point of order I'd like to collect my record my memory was on my first election rather than on my most recent election it should be the 7th of June rather than the 8th We have a deferred vote on the amendment to government notice of motion number 9 relating to allocation of time on bill 4 and act respecting the preparation of a climate change plan providing for the wind down of the cap and trade program and repealing the climate change mitigation and low carbon economy act 2016 call on the members this will be a 5 minute bell I would ask the members please take their seats October 2nd, Mr. Bisson moved an amendment to government notice of motion number 9 relating to the allocation of time on bill 4 All those in favour of Mr. Bisson's motion please rise one at a time and be recognised by the clerk Mr. Borglamp Mr. Glover Mr. Morrison Mr. Hardin Mr. Montefarro Mr. Wester Mr. Frazer Mr. Schreiner Mr. Bisson's motion will please rise one at a time and be recognised by the clerk Mr. Smith-Gabe-Quincy Mr. Thompson Mr. Fidelli Mr. Wilson Mr. Clark Mr. Yacobusky Mr. Hardin Mr. Pettipi Mr. Marto Mr. McDonnell Mr. Bailie Mr. McDonnell Mr. Follerton Mr. Scott Mr. Jones Mr. Jones Mr. Jones Mr. Rickford Mr. Kelly Mr. Martin Mr. Sarkarian Mr. Ostra Mr. Hilly Mr. Nicol Mr. Raman Mr. Harris Mr. Gammari Mrs. Hoga Mr. Downey Mr. Pachino Mr. Cramp Mrs. Tangry Mr. Rossi-Mar Mr. Rashid Mr. Sander Mr. Crawford Mr. Smith-Peterborough-Corker Mr. McKenna Mr. Dunlop Mr. Kanapati Mr. Rabikia Mr. Bauma Mr. Anaya Mr. Pang Mr. Tenegasso Mr. Robert Mr. Nicholas Mr. Darwin Mr. Sh clubs Mr. Amid Mr. Weston Mr. calculator Mr. D charisma Mr. Twent Gunman Mr. Reid Mr. annat Mr. Ac nucleus Mr. Green Mr. Lions Mr. Crakes All those in favor of the motion will please say aye. All those opposed will please say nay. In my opinion, the ayes have it. Calling the members, this will be another five-minute bill. Once again, Mr. Bethlen-Falvey has moved Government Notice of Motion No. 9 relating to allocation of time on Bill 4. All those in favor of the motion will please rise one at a time and be recognized by the clerk. All those in favor of the motion will please rise one at a time and be counted by the clerk. The ayes are 70, the nays are 39. The ayes being 70 and the nays being 39, I declare the motion carried. Next, we have a deferred vote on Government Notice of Motion No. 10 relating to allocation of time on Bill 36. An act to enact a new act and make amendments to various other acts respecting the use and sale of cannabis and vapor products in Ontario. Calling the members, this is a five-minute bill. Same vote? Same vote? The ayes are 70, the nays are 39. Motion's carried. Point of order, the member for Algoma, Manitou. Thank you, Speaker, and he almost escaped, but I've always got my eye on him. Today is the birthday for the member from Toronto, Danforth. Happy birthday to you. This House stands in recess until 3 p.m. this afternoon.


Encryption and decryption main algorithm. Let's start with a symmetric cryptography again. An encryption is defined by three things. Algorithm, block size, key size. Algorithm, we'll see triple SOS, okay. Block size. You don't take all your data or all your information and say just encrypt. But it will be, I would say, cut in some blocks. And the block size is something important and is a characteristic of your encryption. Here I'm talking about padding. Padding is when your data is not aligned on this block size. Can imagine if I've got a block size of five and if you've got some data of six. So I have five information to add at the end. This is a pad. It's something important. I would say it should be done in a specific way. I won't deal with this. It's some detail that you can find in some other literature. Here it's just to say that we are on a block size. Then we've got the key size. Key size is very important because it's often linked regarding a same algorithm with the same block size. It's a characteristic of the strengths of your algorithm. The bigger is the key, the more strength is your security on the encryption for a same algorithm, of course. Main encryption algorithm we see together. Triple S. Triple data encryption standard. And iOS advanced encryption standard. Again, you remember it's fast in software and hardware. And why? Because internally, you only use some permutations. Substitution, shift, or XOR. So it's something a microcontroller or any computers manage to do it very quick. So it's why it's so fast. Let's start with TDS. Triple S. Triple data encryption standard. In fact, it's based on a simple, I will say encryption, which is a simple desk which relies on a faster, safer mathematical problem. I won't detail this because I'm not good on mathematics at all. But okay, I'll just give you the name. The block size here is 64 bits for this algorithm on a key size of 56 bits. But we don't choose this one. We use a triple data encryption. So we will run three times this death algorithm with three different keys. First, the plain text, or I will say the block of the plain text, will be encrypted with the first key. We will be decrypt with another key and we will be re-encrypt the result with the third key. If you decrypt something with another key than the one that has been used to encrypt, it's like a new encryption, I would say. So here the key size for the triple desk would be three multiplied by 56 because we've got three key of 56 bits, 168 bits. But you can also use triple desk algorithm with only two different keys. This time you will encrypt the block of plain text with the key one, decrypt it with key two and re-encrypt it with key one. In this case, the key size will be one hundred and twelve bits. So the second one is not as strong as the first one, but the key size is smaller. Sometimes it's important to have a small key. That's all for the tedious. Now we will deal with advanced encryption standard ROS. I would say it's the main standard used today. It's based on the substitution permutation network. The block size is one hundred and twenty-eight bits and the key size is one hundred and twenty-eight bits or one hundred and ninety-two or two hundred and fifty-six bits. In fact, internally, the ROS algorithm operates on a two-dimensional array of four by four bytes. That explains the block size of one hundred and twenty-eight bits. And internally, I would say, ROS will work with this array and will do some round. The transformation to this two-dimensional array. On four key of one hundred and twenty-eight bits, it will do ten rounds. For the key of one hundred and ninety-two, twelve rounds. For a key of two hundred and fifty-six bits, fourteen rounds. So just to show that if you have a bigger key, the algorithm will be, I would say, more long or it will take more times to compute encryption or decryption. So the complete name when you encrypt block by block is IOS ECB. ECB for Electronic Code Book Mode Encryption. So here we've got the plain text or a block of plain text. So one hundred and twenty-eight bits. And it will be cypher as input with the key. And then you will have the cypher text block by block. And then you go to the next block. You encrypt it with the key and you've got the cypher text until the last block where you may need to add some padding and you encrypt it. The encryption will take the cypher text decrypted block by block. I propose that we do now a short hands-on with about these topics. This time we will use OpenSSL. Before, in the previous hands-on, we used some bad files I created for you that rely on OpenSSL. Now I think it's a good time to use directly these tools. And it's a very useful one that you can use for tests or maybe also for your application. Now let's do the first hands-on with OpenSSL directly. So now we're prepared for you just an input file, example abb.bin and one with one bit modified. In the hands-common.txt file, you've got all the commands that have been already typed if you want to copy past.  First, let's check our content of the example file. So this is the input I will use for mainly all the examples I will do. So first we want to encrypt with a harass 128 bits. So it's a command OpenSSL. Then we want to do encryption. The algorithm is harass 128 bits. Electronic code books encryption. Then TRK will give here the key. Let's take, I don't know, deadbiff. Deadbiff. Why not? Then we've got an option, no salt. That may, it won't have some special correctness. So we don't just, I want to encrypt what we provided to it. Then no pad. We don't want to add some things because it's already aligned on the block size. So the input file will be my example. And the output file. Let's call it example. Encrypted a CB. So if I check the results. Okay, as you can see, the same size. It's being encrypted block by block. Do you notice something? Okay, I'm nearly sure that you will find it. Here we've got the line of AABB and it's one block. So here we've got one block encrypted, another encrypted, another encrypted. As you can see, you can see some pattern. So, okay, with a CB, it's block by block, but the problem is that when you encrypted two blocks that are equal, you've got the same results. That could be an issue. I will come back to this in the theory after. But now let's decrypt. So, open SSL again. So this time, we always use encrypt but charity to precisely who want to decrypt. We just give the algorithm OS128 bits, electronic code book. The key, we have decided dead beef, dead beef. We say that we have no sort and no pad. So, the input this time would be the encrypted file. Encrypted a CB and the output file. I hope we'll find the good one. So, decrypted a CB. Okay, I hope I forget nothing. So, let's check the results. So it was a decrypted a CB and I found again my data. So, quite simple. So, this is again a basic example but open SSL is very powerful so you can really use it to experiment things. Here I give you just the basic commands after you've got many options but I don't want to go into much details. Here again, it was to fix your hiding. So, we have seen together that with a CB block by block, that's mean when I encrypted one block twice we've got the same result for this block. And it could be an issue. Let's see in the theory now. Let's talk about block ciphering mode. We've seen just in the answer that we managed to find out some pattern. When you encrypt one block and if the block is exactly the same you will have the same results. So, if you encrypt a clear image, images from numerical point of view is just some colors on each byte and such kind of coding. So, if you encrypt such kind of pictures with just a high os and the cbc mode you will manage to see a pattern and it's really, really easy to see. So, there is two ways to address this two possible solutions. The first one is to use some data from the previous block to encrypt the next block. This is a chaining mode. We will see just after the description of the cbc one cfb and ofb. Another possibility is to combine each block of data with a counter and this is conterm mode. We will see the CTR. There is also the CCM and the GCM. GCM will be addressed later in this presentation but CCM I won't address it. But you can find information really easily on it. So, let's see the first one, oscbc. Don't be afraid by these schematics. It could seem to be complicated but not so much. So, here we've got the first block of plain text. The first thing, we have a new input. Initialization vectors. And we will XOR this first block with the initialization vectors and encrypt the results. This is the first suffer text block. And this one will be the input for the next XOR done with the second block of plain text. And it's gone that way. So, you seem okay. For encryption, I catch what is the algorithm but how it works for decryption. You take the ciphertext. The first ciphertext block. You decrypt it. And you XOR it again with the same initialization vector. And you will find plain text. Exactly the same for the next ciphertext. You decrypt it with the key. You XOR it with the previous ciphertext and you will have the plain text. So, this is really a chaining mode and that way you ensure that you won't see any pattern anymore. For sure. The back of this is that you can't parallelize. I need to encrypt the next block. I need the first block to be encrypted. So, this is the main drawback for this algorithm. Let's do a short hand zone again and see that we don't see any pattern anymore now. So, now we'll experiment the Havas CBC. We have seen the problem of this pattern that we could see. So, let's try to use it. So, open SSL again. We want to encrypt. The algorithm is 100 128 bits. And this time it was with the CBC. Ascii, we will use JetBiff again. Why not? And this time I will put an initialization vectors. So, I don't know. Dead, for example. It was advised to change the IV for each encryption. Then the argument no salt. I should not have some space. No salt. Then no pad. The input file will be stillmyexample.bin And the output file will be example. But I want encryption. And it will be with CBC. So, if we check now the results with Xtemp. So, example with CBC. Here, no pattern anymore. If I compare with the one with a CBC, we generated previously. Here, we got two pattern. So, we will address this problem now with the CBC. So, when we want to decrypt, we will also need the IV. So, let's do it. So, we see ink, but minus D to say we decrypt. Then how else? 128 bits. We are in a CBC chaining. My key will be deadbiff. Deadbiff. My IV which is dead. We put no salt. No pads. And as input here we got the encrypted CBC. And the output will be the example with decrypted decrypted, sorry, CBC. I missed something somewhere. Okay, no pad. Not no pass. Sorry. Okay. So, let's check the results. So, it was a decrypted CBC and we found out our input. So, here we just seen together that with CBC we don't have the pattern that could be seen now. That's it. Quite simple, I think. Okay, going on with theory. Let's see another chaining mode. CFB, cipher feedback mode encryption. This time it's a little bit different. As you can see, the input of the encryption this time will be the initialization vectors. And it was this one that will be encrypted with a key. And we just saw the plain text with it to have the cipher text. That's really changing from what we have seen before because before we were always encrypted, I would say some kind of plain text we think. Here we just encrypt the initialization vectors. So, you can see the cipher text which is really unpredictable if you don't have the key and you've got the plain text. And this one is the block for the next input.  For the decryption, as you can see, it's not a decryption. We will encrypt again the initialization vector with the key. And we have, I will say, the same resultant here. So, when we will cipher text with the same value we will find out again our plain text. So, from the next one, the block will be the input of the next encryption and so on and so on. Here the main advantage regarding the previous algorithm is that you only unbedded encryption algorithm. You don't need the decryption one. This could be an advantage because for the highest encryption algorithm and the decryption algorithm are not the same code or same way of working. So, when you have some constraint on the size of unbedded code and things like that, you can select this one because you can just unbed the encryption mechanism. You don't need the decryption one. Now, we will talk about the OFB. It was the output feedback mode. So, here again we will encrypt the initialization vector with the key. And the result of this will be so with the plain text. So, I will say this block is exactly the same that previous. But the difference is now it's before using the plain text before XORing with the plain text will take the result of this encryption as the input of the next one. What is the advantage of this? You don't need to wait to have the type of text to manage to prepare the next one. If you've got the initialization vector and the key, you can prepare in advance all those coefficients. So, I would say it's a kind of optimization. You can do some parallelism computing. So, it could be very interesting from a performance point of view. And again, if you look, we are using encryption and encryption. But I would say something is not good. Imagine you managed to have an example of a cipher text on a plain text. So, you will manage to get this algorithm, this value and this value and this one. Because it's really easy. You just have to take one block to XOR with this block and you will get the result of this. If Alice will encrypt another message with the same IV and the same key you will have all the key in advance or you will have all those resistance events, you will manage to decrypt it. So, I would say initialization vector in this case should be changed for each message. Of course, it's not easy for a hiker to manage to get a cipher text but if you manage to get this and if you don't change your initialization vectors you can, I would say, crack the message. So, this is the drawback of this one. Another mode is the cunter mode and this time we are not using some data from the previous block or chaining mode I would say. Here we will use some random data and also added cunters and this is called the cunter mode. Main cunter mode has the CTR, CCM and GCM. Here I will just introduce you to the CTR. CCM and GCM have a particularity. They are doing encryption for sure but they also do some authentication so it's a little bit early in the presentation to introduce you about those. I will come back on GCM once we have seen together authentication. What are the details about CTRs? So again we've got this schematics. I take a lot of points. Here we've got nouns. Nouns mean a random data and with these nouns there is a part that will be a cunter and to encrypt a block of the plain text we will first encrypt the key with these nouns and the cunter and we show the result with the plain text. As you can see, there is no link between each block. It's just the cunter that will change for the decryption we should take the same random value so it should be shared. It's always an initialization vector I would say but this time this initialization vector would change from value due to the cunters. So we take this initialization vectors we encrypt with the key and we show with the cipher text and get the plain text. So here you've got the difference between the other mechanism we've seen of Schenning and what are the advantages of this. Again, we just embedded the encryption so for the constant of the size that's good. Another particularity we can compute in advance all those values so we can do some parallelism but what is also interesting you can just access or we say encrypt or decrypt one block in all your text because in advance you just change the cunter value and you can cipher or decrypt. Here it's a decryption even if you are using encryption for the coefficients and that's it. So very interesting. I think now we have seen the different Schenning mode and the cunter mode I don't give you too much details it's just to give you a flavor about those and it's important when you selected an algorithm to be aware of which Schenning mode or cunter mode is used if you need it of course and now let's do again a short hands-on with open SSL on CTR just to see the results. So now with the cunter mode so I think you have seen we will just change the argument to which specifier what is the algorithm use but let's do it it's good to experiment it I think. So open SSL sorry open SSL again so this time I still want to encrypt the RS 128 bit and this time with the CTR mode we still need the key to encrypt dead beef dead beef we will use an IV also but this time just I will say in a symbolic way I will use this one just to show you or to have the image that this IV will be incremented to have the cunter you got it so let's put dead 0 0 0 but it's symbolic because if I put dead that it will also incremented then we've got the no salt option the no pad option the input is always the same my example my output input with the example and I change the extension with encrypted and I put CTL ok that's it if I do xdamp if we manage to see some button but I don't think so so that's what we already down encrypted CTL this one ok no button could be seen here let's decrypt it so open SSL again and we want to decrypt so here it was the RS128 bits not space but just this ok and it was a cunter mode the key to use dead beef the IV really important and should be changed each time you encrypt the new data ok the no salt option the no pad option no salt no pad then the input so this time would be the encrypted CTL and the output would be this one with decrypt CTL let's check the results decrypted CTL and we find out how our inputs so quite simple you can see with open SSL it's really easy to change the chaining mode and do some experimentation ok let's continue with theory so we finish with the house we have seen some chaining mode we have seen the CTL mode, cunter mode sorry and now I want to do a short comparison with the algorithm because you can wonder which one TDS or RS should I use in fact RS could be considered as the successor of the triple S so in every new new scheme you are using you will probably use RS TDS could encounter some issues more than 32 GB of data with the same key just a weakness to be known but the main argument is that RS is faster than TDS with a lower memory footprint so I would say there is no main advantage to use triple S but it's already using some system so sometimes for compatibility point of view you will need to use this algorithm also and that's it for all the algorithm symmetric where do we stand now let's check our agenda first we've seen together different principle for symmetric encryption let's mean using the same key to encrypt and decrypt symmetric you remember we are using the public key of the recipient to encrypt data and you will decrypt it with this private key combination of the both is a way to encrypt a huge volume data in an efficient way and a shared secret generation Diffie-Hellman which is another way to generate a shared secret to encrypt with symmetric after then we have seen together the main algorithm symmetric triple S, RS is associated with a chaining mode or CTR if needed CTR counter mode sorry now we will see together asymmetric main algorithm RSI, elliptic curves and Diffie-Hellman I will give you here more details about what are the mathematical behind I won't go too deep in this detail because I'm not good at math at all so it's just to give you a flavor about what is the mathematical problem behind those so the asymmetric cryptography main algorithm so the encryption characteristic of the algorithm and the associated key size so two main algorithm we see together RSI and SCC for the RSI the commonly key size is 2048 bits and up to 4096 bits you can use smaller key if you want but today is not considered as secured enough to waste a lot of computation for the SCC the key commonly uses 160 bits and up to 512 bits so really smaller than the RSI one but that doesn't mean that is less secure again and you remember I already told you in the part of theory it's a complex operation so even for hardware or software so generally it's not used to encrypt big data let's start with RSI so RSI stands for reversed shami at demand in fact it based on the difficulties to factorize the product of two large numbers so if you get two large numbers PNQ even if you know the product N it's quite complicated to manage to find PNQ or it's nearly impossible in practice so commonly used key size is 2048 bits and up to 4096 bits so all those numbers will be large I want to give you detail about RSI key creation so let's compute it manually first we need to choose two prime numbers PNQ and compute the product of them so we'll do this with very tiny value because I want to do it manually so I chose P equal 5 and Q equal 11 so the product is 55 then we need to choose another prime number which should be no prime factor with the product of P-1 with Q-1 so in our case this product of P-1 multiplied by Q-1 is 14 so I just check the prime numbers and he could be equal to 7 so now our public key will be the E and N then we compute the private part of the key so we need to choose a number D who will respect one rules E multiplied by D modulus the P-1 multiplied by Q-1 should be equal to 1 so D equal 23 could be a good candidate for us and the private key will be D and N N is public because it's already in the public key but you will need with a private part D why? because if I just give you details about encrypted number N the algorithm to do that it just put M to the power of E modulo N and you've got the encrypted value and when you want to decrypt you will use the same algorithm but this time you will put encrypted number C to the power of D modulo N and you will get the value so it just to show you then a new circuit is composed of many different numbers but the important one are public and the private exponent so public exponent is E the private exponent is D and the modulus which is N so here is CK pair as I've just said we've got a public exponent and modulus this is a public key we've got a private key which is component of the private exponent and the modulus and P and Q is not used anymore to encrypt and decrypt but they have to be kept secret so they managed to find the private exponent so the private key so this is just to show you how a key pair Eresa is composed and what is the important component in it let's do a hands on just to check this with Hopon SSL so now I propose that we generate an Eresa key together so Hopon SSL again we want to generate some Eresa and there how it put fire will be private key dot POM is the extension used by Hopon SSL for the key then I see the size of this key 2048 bit for example here generated and the result is in the file mypref key dot POM if I just dump it with a type we talk about Eresa private key but we don't see all the information in fact it's a proprietary format so there is utilities in Hopon SSL to manage to extract the public key and also all the information inside so let's do it Hopon SSL we are in Eresa domain we will put as input the key and we would like to see the public key with pubouts here we've got the public key but we can also say that I want to store it in a file so with the argument out and say this is my public key this is a way to have a key pair now we can also request to see some detail about this Eresa I will put my private key and I will say I would like to see something under the understance table ok, many information but here you have link with what we studied before you find the modulus it's a public exponent the private exponent the prime number one prime number two ok so really here we've got all the information we know that to encrypt or to decrypt we only use this part but this one could remain secret there is other value after which is exponent one exponent two and coefficient this is partial value that can be used to optimize the algorithm of Hopon SSL but I would say it was deduced from the other part of the key if we check what we've got in the public key so I will put my public key I have to say that it was a public key or it will not be happy and text file you remember what we should see only the modulus and the exponent ok so let's face a idea like I said before in the theory so now I propose that we encrypt our file with eresa so Hopon SSL this time we do eresa utility we want to encrypt so let's say we want to encrypt we will encrypt with the public key you remember that so the key will be my public key.pm I need to say this is a public key I won't be happy what I want to encrypt will be my example and the result will be stored in my example dot onk eresa for example ok I think everything is there seems happy with that if I do extend of the result so example underscore and eresa ok as you can see now it's encrypted so let's decrypt it we encrypt with the public key so we will decrypt with the private key not so complicated so Hopon SSL again we still using eresa utility we say that we want to decrypt this time the in key will be my private key the input will be the example and encrypt eresa and the output will be an example decrypted eresa let's check the result decrypted eresa and we found out our inputs so it's working you have seen how you encrypt with the public key and decrypt with the private key if you try to encrypt with some private key and think like that you will have some warning from Hopon SSL so here I just give you I would say when it works but it's really a good basics and you can do some trial with this ACC let's talk about elliptic curves cryptography so it's based on the elliptic curves and the commonly used key size is 160 up to 512 bits so mathematics behind elliptic curves are quite complicated I want to give you just a flavor about what is this problem and how we can use it so first let's see what is an elliptic curves elliptic curves over a finite field order n satisfies this equation so if I draw it I can have something like that that's really depending on the different coefficient A B let's take this example just to simplify and on these curves I will define a point G the generators then I will define a specific operation on this point G I will show the tangent who go through this point there will be a new intersection with my curves a new point and I will take the symmetric of this one regarding the x-axis and I will define this new point P like G plus G take care this plus is not like you do some addition of two numbers this is really doing this tangent plus the symmetric and I define this point as 2G so I can go on with this algorithm if again I draw the tangent through P I will have a new intersection with the curves I will take the symmetric and it will be 3G on I can go on go on I can add the point P which is equal to KG okay so you know now how I managed to draw G and P and in fact it just keep those two points if I give you the curves if I give you G and P it's quite impossible to find the number K okay and all the problems of ACC rely on these difficulties we managed to compute it because we do just G plus G plus G why can't I do it again so I would say if you try to compute G plus G and check if it's P it would take a very very very long time but if you know the value K and you just compute KG there is some mathematical shortcut to find the final point P so really when you've got some public data like the curves G and P it's impossible to find the K which will be the private key so now I will explicitly just give you some details about the different coefficients obviously we need to have a view for all those coefficients and even for K so INB are the characteristic of the curves selected there is many curves already defined by good mathematical guys and you have to select it carefully some curves are recommended to do signatures, orders for encryption and such kind of things frankly speaking I'm not expert on this domain just remember that you have to select good curves that have been recommended again which is the order of our finite field is the number of points P possible on the curves because you could imagine that we need to have something finite and it's this coefficient that will define the number of points P is the modulus and it's the prime numbers our CCT pairs first we've got G and P two points on the curves linked with the property P equal KG remember G is not just a product it's really this specific operation just to draw a tangent and take the symmetric regarding the X axis so G and P could be considered as the public component of the key on K will be the private key so if you got G, P and the curves quite difficult to compute K but if you select key when you created your key pair it's not so complicated to do the product KG quickly so now we will switch to Diffielman do you remember the Diffielman purpose? I hope so so it's create a shared secret between Bob and Alice without communicate some private information in the previous part I introduced this with some color mixing and color selection so now it's time to use some mathematics in fact it will lie on the discrete logarithm problem if you go at Y which equal to G power of X modulo P with P of prime numbers Y, G and P and X large number it's quite difficult if you know Y, G and P to find X to fix idea I just give you an example with tiny value in Diffielman can you find X quickly? not so easy with the calculator it will manage but it's really tiny value so let's go to the algorithms and check how it works Bob and Alice first they will agree on the common color you remember the yellow here they will select two numbers they will select G and P of prime numbers those data are public because they need to be shared by the both then each one will select his private parts of the key for Alice it will be X, A for Bob it will be X, P then we will apply the previous formula we've seen of before so Alice will compute G power of X, A modulo P and find a Y, A Bob will do the same so we got 15 Alice 8 then they will exchange the value and you remember you know Y, you know P G, you can't find the X it's quite complicated something's very difficult to be done then Alice will take the Y and will apply again the formula she will find Z equal to Bob will do the same and will find exactly the same value now we have a shared secret Z value on the both sides without sharing any private data X can be found thanks Y, P and G that's it so now let's do a differential with OpenSSL it's a little bit tough I mean there is many comments but it's a good exercise so first let's choose the parameters I will say the common colors OpenSSL GenPiki and we've got GenParam the algorithm we want to use it's differentialman for sure and the output would be for example DHP.Pam so here we generated the common color you remember so it would be the modulus and the G because when the case of the discrete logarithm that's done let's check the result so we'll use a OpenSSL command for that with Piki.Param at input we've got DHP.Pam and the output we would like to have something we can read so we find our generators and our prime good so next step Alice will choose a color and I will say the private part of the key and we compute the public part of the key thanks the common color and this private color so OpenSSL again we'll generate a key we will use as param file the common color and the output will be the differentialman key of Alice let's check what we've generated together OpenSSL now the input will be we'll use a key the input will be the key generated for Alice and I would like to see it in a text way to understand what we generate so we've got our private key or Alice private key the public key the prime and generators so everything in one file let's extract the public part of this open SSL again we still use pk command the input will be the Alice public key we want to extract the public part of the key and we put this in the dh pub Alice we can check the results so it's a public key as input we put the Alice public key and I want to see the result in text also though here the private part of the key has been removed okay so now pub should do the same because it's symmetrical and we want to see how they will generate the different circuits so I will do it now with I will say the same so no need to generate again the command color because we've got it and we have to give it so open SSL gen the pk run file the run file it's the command colors as parameters and the output will be dh key pub that's it I won't check this time because we have done it with Alice so it will be exactly the same so let's extract the public part of the key of pub now SSL pk we've got dh pk from pub we want to extract the public part of it and we put it in the dh pub of pub so now we've got all the information so we can try to generate the circuits so the first one we will use I will say the rule of Alice so we will use the open SSL we will use the pk and we say that we want to derive what are the mk that we will use we will use Alice key and the full one with the private parts and we will use the public key of pub pk dh pub of pub the output will be to create Alice that bin so symmetrically pub can do the same command k derive the input k this time will be the pub's one the pk should be the Alice public key and the output would be the secret of pub so let's compare the secret of the secret of Alice we've got this if I do an example of the secret of pub it's exactly the same so here we have done the hands on with Diffierman many commands frankly speaking it's nearly impossible to know them by heart so remember that I gave you some files with all the commands inside but it's just to show you that you can compute it more and more in fact Diffierman could be also associated with elliptic curves that means you don't rely on the discrete logarithm problem but you will use elliptic curves the name of this algorithm is ecdh, elliptic curves Diffierman so let's try to compute this with pub and Alice again so we've got g generators, a curves pub can select a private kb and do the product of kbg with the rules we've seen before it will have a point pb and will send this point to Alice you remember even if you know g, pb and the curves quite complicated or impossible to find kb at least do the same things so you've got the same generators select a private value ka and compute a final point pa and send this to pub then pub will compute based on the point received from Alice the kb value on this point and you will get a final point Alice will do the same she takes the point received from pub and will apply this value on it and she will get a final point and you can see the two final points are equal we've got a common shared data between pub and Alice what we've shared on the public side will be the pb, pa, g and the curves so impossible to find ka and kb if you look at the equation maybe to fix the idea I think it's quite obvious it's just a point in terms of the difference in the case but the final point is exactly the same so now we have finished with the asymmetric cryptography algorithm so let's check the agenda again encryption theory down symmetric asymmetric with differentialman the main algorithm in symmetric for the asymmetric elliptic curves and associated with elliptic curves and just the last point it was a standard combination of symmetric and asymmetric more precisely between differentialman and the symmetric so it's IES just a couple of words because it's important to give this in mind in fact it was standard and there is two main standard for this so the discrete logarithm integrated encryption scheme so I will say the basic differentialman associated with asymmetric encryption and another one the elliptic curves integrated encryption scheme so the name is elliptic curves here if you well remember in the previous part I don't tell you about encryption with elliptic curves because you don't encrypt with elliptic curves you will always do some kind of differentialman elliptic curves associated with a symmetric encryption so where do we stand now we have seen how to encrypt message I mean how we manage to protect the data but there is two remaining points you remember about Bob and Alice okay now imagine Alice is not so shy she don't want to hide the message she's ready that Eve was aware about what she want to write but she want two things first she don't want that anybody manage to modify this message it was the integrity and the other point she want that Bob when you receive it is sure that it's coming from her it's not something written by somebody else who just write Alice at the end of the letter so it was the authentication so let's continue with integrated check