Confidential computing with SQL secure enclaves  – BRK3157

August 16, 2019 posted by


GOOD MORNING EVERYONE. OKAY. WELCOME ON THE FOUR DAY OF IGNITE. THANKS FOR COMING. MY NAME JAY CAN BE SZYMASZEK. I’M PROGRAM MANAGER AND SQL TEAM I WORK ON SECURITY FEATURES FOR SQL SERVER AND AZURE SQL SERVER DATABASE WITH WE HE HAVE DEAN WELLS PM IN WINDOWS SERVER BASE. HE WORKS ON SECURITY FEATURES IN WINDOWS. SO IN THIS SESSION WE GOING TO SHARE WITH YOU INFORMATION ABOUT SOME EXCITING AND TRULY GAME CHANGING DATA PROTECTION. THAT WE ARE INTRODUCING IN THE SQL PLATFORM BY LEVERAGING WHAT IS CALLED SECURE ENCLAVE TECHNOLOGY. AND A BUMP OF OTHER TECHNOLOGY THAT IS DEAN’S TEAM HAS WORKING ON IN WINDOWS. SO THAT’S WHY I INVITED DEAN SO THAT HE CAN PRESENT TO YOU THE WINDOWS PART OF OUR END TO END SOLUTION. OKAY. SO LET ME KICK IT OFF BY GIVING YOU SOME CONTEXT HERE ABOUT THE PROBLEMS THAT WE ARE TRYING TO SOLVE WITH THE TECHNOLOGY. SO MANY OF YOU ARE PROBABLY FAMILIAR AND ARE EVEN USING TECHNIQUES, MECHANISMS FEATURES FOR PROTECTING SENSITIVE DATA AND DATABASE SYSTEM IN SQL, ADDRESS IN TRANSIT. WE HAVE FAIRLY MATURE TECHNOLOGY THAT IS PROTECT DATA ADDRESS, PROTECT DATA IN TRANSITAND DATABASE ENCRYPTION IS A PRIME EXAMPLE OF THAT. A TECHNOLOGY THAT EXISTED IN SQL SERVER FOR ABOUT TEN YEARS OR MORE. WE HAVE TLS, SSL, AND THAT IS ALSO SUPPORTED IN SQL SERVER FOR PROTECTING SENSITIVE DATA IN TRANSIT. SO NOW THE CHAEJ IS THAT PROTECTION THAT TD PROVIDES IT ENDS THE MOMENT YOUR TODAY IT IS A LOADED FROM DISK INTO MEMORY. PROTECTION THAT TLS OR SSL PROVIDE AND THE MOMENT YOU’RE DATABASE SERVER RECEIVERS DATA FROM YOUR APPLICATION. AFTER THAT, THE DATA APPEARS IN MEMORY OF SQL SERVER PROCESSES IN PLAIN TEXT. SO, THE PROBLEM IS THAT RECENTLY, WAS MISSING WAS MECHANISMS TO PROTECT SENSITIVE DATA IN USE. BY THAT WE MEAN DATA THAT IS USED IN MEMORY OF DATABASE SYSTEM DURING QUERY PROCESSING. AND THAT’S EXACTLY THE PROBLEM THAT ALWAYS ENCRYPTED TECHNOLOGY THAT WE INTRODUCE AD COUPLE YEARS AGO. ATTEMPT TO SOLVE, RIGHT? SO LET’S DOUBLE CLICK ON THAT. THE CHALLENGE, THE ISSUE WE’RE TRYING TO ADDRESS IS HOW TO PROTECT SENSITIVE DATA INSIDE A SQL SERVER ENVIRONMENT FROM POWERFUL ADVERSARIES BASICALLY HIGH PRI LEMS UNAUTHORIZED USERS THAT INCLUDE DATABASE ADMINISTRATORS, ADMINISTRATORS OF MACHINE HOKING SQL SERVER, CLOUD OPERATORS OR ANYTHING MALICIOUS PROCESS THAT MAY HAVE INFECTED THE HOSTING MACHINE, THE ENVIRONMENT THAT HOSTS YOUR DATABASE. AND NOW THE CHALLENGE IS THAT IT’S EASY TO ACHIEVE PROTECTION OF SENSITIVE DATA IN USE IF THIS IS YOUR ONLY GOAL. YOU CAN BASICALLY ENSURE THAT THAT DATA THAT YOU STORE IN DATABASE GETS ENCRYPTED BEFORE IS TORRIDED IN AND ALGORITHM LIKE AS256 FOR EXAMPLE. THE CHALLENGE IS ONCE YOU DO THAT YOU HAVE COMPROMISED THE QUERY PROCESSING CAP AIBLTS OF YOUR DATABASE ENVIRONMENT. AND SQL SERVER AND ANY DATABASE SYSTEM WILL NOT BE ABLE TO COMPUTE PERFORM COMPUTATIONS ON YOUR DATA AND PROCESS YOUR QUERIES. SO THAT’S WHAT WE DON’T WANT. SO IDEALLY OUR GOAL IS TO ACHIEVE WHAT WE CALL CONFIDENTIAL COMPUTING OR COMPUTATIONS WITHOUT SEEING THE DATA WE WANT SQL SERVER PROCESS TO A PERFORM RICH COMPUTATIONS ON DATA ARIT MAT CALL OPERATIONS WHATEVER YOU CAN THINK OF, SORTING, ORDERING AND SO ON. IN SUCH A WAY THAT DATA IS NEVER A DIRECT EXPOSED TO POTENTIAL ATTACKER IN SERVER ENVIRONMENT. THAT’S CHALLENGE WE’RE TRYING TO SOLVE HERE. AS YOU CAN SEE WE’RE TRYING TO ACHIEVE TWO GOALS UNTIL RECENTLY HAVE BEEN KIND OF MUTUALLY EXCLUSIVE AND NOT ACHIEVABLE TOGETHER. AND ON ONE SIDE PROTECTING SENSITIVE DATA USE FROM THE POWERFUL ADVERSARIES ON OTHER A PORT RICH FUNCTIONALITY OF SQL INQUIRIES. ABOUT TWO YEARS AGO WE MADE FIRST STEP TOWARD THIS VISION. OKAY. AND THIS FIRST STEP WAS THE RELEASE OF THE FIRST VERSION OF ALL ENG CRYPTED IN SQL SERVER 2016. HOW MANY OF YOU ARE USING OR FAMILIAR WITH ALWAYS ENCRYPTED WE. OKAY. QUITE A FEW HANDS. LET ME MAKE SURE THAT WE ARE ON THE SAME PAGE BECAUSE I WANT TO, WE NEED TO UNDERSTAND THE MECHANICS OF THIS ALWAYS ENCRYPTED WORK FLOW AND TECHNOLOGY SO THAT WE CAN DIVE INTO HOW ENCLAVES ENHANCE IT. SO ALWAYS ENCRYPTED IS CLIENT SO I ENCRYPTION IT WORKS BY ENCRYPTED AND DECRYPTING DATA ON THE CLIENT SIDE. AS YOU CAN SEE THIS DIAGRAM THE DATA APPEARS IN PLAIN TEXT ON THE CLIENT SIDE. A CLIENT APPLICATION OWNS THE DATA. BUT THE MOMENT THAT THE DATA LEAVES THE CLIENT APPLICATION THE DATA GETS ENCRYPTED. SO SQL SERVER NEVER SEES DATA IN PLAIN TEXT, DOESN’T SEE THE KEYS THAT WE’RE USED TO ENCRYPT THE DATA IN PLAIN TEXT EITHER. SO THIS CLIENT SO I ENCRYPTION HAS TWO OTHER IMPORTANT PROPERTIES. ONE ENCRYPTION TRANSPARENCY. THIS ENCRYPTION DECRYPTION HAPPENS INSIDE A CLIENT DRIVER, AND THAT CLIENT DRIVER ENCRYPTS THE ENCRYPTED DATA AND WHICH DATA NEEDS TO BE ENCRYPTED BEFORE IT IS SENT TO THE DATABASE. AND WHICH QUERY NEEDS TO BE DECRYPTED. APPLICATION DOESN’T HAVE TOAL CALL CRYPT ROUTINESES TO TRIGGER THE CRYPT OPERATIONS. SO IT MAKES PROGRAMMING ENOUGH DEVELOPMENT EASIER. THE OTHER KEY PROPERTY AS I MENTIONED EARLIER THIS INITIAL VERSION WAS THE FIRST STEP TOWARDS ACHIEVERING THE CONFIDENTIAL COMPUTING VISION. SO IN THIS, INITIAL VERSION, WE MANAGED TO SUPPORT SOME OPERATIONS ON ENCRYPTED DATA TO BE PRECISE IT IS JUST ONE TYPE OF COMPUTATION. NAMELY QUALITY COMPARISON. WHEN WE ACHIEVE THAT BY USING WHAT WE CALL THE ENCRYPTION. THAT IS TYPE OF PROPERTY PRESERVING ENCRYPTION WHICH INSURES IF YOU HAVE TWO VALUES THAT ARE EQUAL TO PLAIN TEXT VALUES AFTER ENCRYPTING THOSE VALUES THE RESULTING VALUES ARE ALSO EQUAL. RIGHT SOME SO WHAT THIS MEANS IS THAT, SQL SERVER NOW CAN THEN REASON, CAN, CANDY DID YOU SAY THAT TWO PLAIN TEXT VALUES ARE THE SAME BY COMPARING THEIR CIPHER TEXT DOESN’T HAVE TO UNDER KNOW LYING PLAIN TEXT. VERY BASIC AND VERY SIMPLE. BUT SURPRISINGLY IN DATABASE SYSTEMS AND SQL THERE ARE QUITE A FEW TYPES OF QUERIES THAT LEVERAGE COMPARISON THAT ARE QUITE USEFUL. SO POINT LOOK UP SEARCHS ARE ONE EXAMPLE. EQUALITY JOIN IS ANOTHER EXAMPLE. WE ALSO CAN SUPPORT SIMPLE AGGREGATIONS USING GROUP BY OPERATIONS. SO THAT’S, THAT IS WHAT WE DID ABOUT TWO YEARS AGO. THAT WAS OUR FIRST STEP TOWARDS THIS CONFIDENTIAL COMPUTING VISION. NOW LET ME DOUBLE CLICK AND SPEND A FEW MINUTES ON THIS ARCHITECTURE THAT EXISTS TODAY WHICH WE GOING TO BUILD ON TOP OF TO SUPPORT MORE FUNCTIONALITY WITH SECURE ENCLAVES. WHAT ENCRYPTED THOSE OF YOU KNOW COLUMN LEVEL ENCRYPTION. THEY ARE ENCRYPTED WITH WHAT WE CALL COLUMN ENCRYPTION KEYS. THESE PROTECTED WITH SYMMETRIC KEYS. AND IT’S MANY, TOO MANY RELATIONSHIPS YOU CAN HAVE MANY COLUMNS MANY KEYS. NOW THE IMPORTANT THING NOTICE IS THAT NEITHER KEYS ARE VISIBLE. TO THE DATABASE SYSTEM. RIGHT? SO YOU HAVE MASTER KEYS STORED IN ENCRYPTED FORM AND DATABASE ON PLAIN TEXT AND MASTER KEYS THAT ARE UNDER CONTROL OF THE APPLICATIONS. SO THE APPLICATION IS RESPONSIBLE FOR MANAGING THOSE KEYS AND TO WE SUPPORT OUR OUT OF BOX ABILITY TO STORE THOSE KEYS IN WINDOWS CERTIFICATES KEY CALLED H S M DEVICE SO YOU CAN ALSO CHOOSE TO STORE THEM IN A KUS M KEY STORE, RIGHT? NOW, LET ME WALK YOU THROUGH THE TYPICAL QUERY PROCESSING WORK FLOW FOR ALWAYS ENCRYPTED. SO IN CHARM ON RIGHT-HAND SIDE YOU CAN SATISFACTORY A TABLE WITH TWO COLUMNS ENCRYPTED OH ON LEFT-HAND SIDE CLIENT APPLICATION THAT IS TRYING TO ISSUE A POINT LOOK UP QUERY. SO WE’RE LOOKING FOR ARE A MATCHING NAME FOR A GIVEN SOCIAL SECURITY NUMBER WHICH IS GOVERNMENT ID IN THE U.S. AND THESE TWO CLUMENTS ARE ENCRYPTED ON THE SERVER SIDE. SO FIRST THING NORMALLY WOULD HAPPEN IN THIS CASE, CLIENT DRIVER AFTER RECEIVING THIS QUERY WOULD JUST SEND TO THE SQL SERVER SUBMIT IT FOR PROCESSING, RIGHT? NOW WITH ALWAYS ENCRYPTED IN PLACE, INSTEAD, THE CLIENT DRIVER WILL MAKE TRANSPARENTLY THIS DATA META DATA DISCOVERY CALLED BY CALLING THE PROCEDURE SP DESCRIBED ENCRYPTION. WHAT IS HAPPENING HERE, THE DRIVER IS SUBMITS THE QUERY STATEMENT THAT WAS INVOLVED BY THE APPLICATION. AND THE SQL SERVER ANALYZES STATEMENT. PROCESSES ANALYZES IT TO FIGURE OUT WHICH PARAMETERS QUERY PARAMETERS IN THE STATEMENT NEED TO BE ENCRYPTED ON THE CLIENT SIDE SO BASICALLY CONCLUDES IN THIS CASE THAT THE FSSN PARAMETER IN THIS QUERY HAPPENS TO CORRESPOND TO THE DATABASE COLUMN SSN WE JUST ENCRYPTED. SO WHAT IT DOES IT RESPONDS WITH ALL THE META DATA, ALL THE INFORMATION IT KNOWS ON HOW THIS COLUMN IS ENCRYPTED. THIS IS THE KEY PART. SOMEHOW THE WAY TO DESCRIBE ALWAYS ENCRYPTED TO SAY THAT THIS IS ENCRYPTION TECHNOLOGY THAT IS INFORMED BY SERVER CLIENT I ENCRYPTION INFORMED CONTROLLED BY SERVER META DATA. SO THE SERVER KNOWS ABOUT WHICH COLUMNS ARE ENCRYPTED HOW HER ENCRYPTED AND SUPPLIES THIS INFORMATION DYNAMICALLY TO THE DRIVER SO THE DRIVER NOW KNOWS WHAT TO DO. SO THE FIRST OBJECTIVE OF THE DRIVER IN THIS WORK FLOW IS TO DECRYPT THE ENCRYPTION KEY STORED IN ENCRYPTED FORM ON SERVER SIDE AND SENDS BACK THIS RESPONSE TO THE CLIENT. SO THE CLIENT KNOWS WHERE THE MASTER KEY IS FROM THE FIELD THAT IS CALLED HERE, COLUMN MASTER KEY PART. SO REACHES OH OUT TO THE KEY STORE, AND CALLS THE DECRYPT OPERATION ON THE KEY STORE NOW IT HAS A COLUMN ENCRYPTION KEY DATA ENCRYPTION KEY IN PLAIN TEXT. WHAT IT CAN DO, IT CAN NOW ENCRYPT A QUERY PARAMETER THAT IS SSN VALUE, REWRITE THE QUERY STATEMENT, NOT QUERY STATEMENT BUT THE QUERY INVOCATION, AND REPLACE THE PLAIN TEXT WITH CIPHER TEXT. WHAT SERVER GETS IS CIPHER TEXT OF THE QUERY PARAMETER THAT CORRESPONDS WLT ENCRYPTED COLUMN. ASSUMING SSN COLUMN IS ENCRYPTED SQL SERVER CAN EVALUATE THIS EQUALITY COMPARISON IN THE WORK LOADS, RIGHT? SO THAT’S WHAT I MENTIONED EARLIER HOW WE SUPPORT EQUALITY COMPARISON FOR THE ENCRYPTION. SO NOW THE SQL SERVER FOUND THE MATCHING NAME, IT KNOWS THAT THIS VALUE COMES FROM ENCRYPTED COLUMN. THEREFORE IT ATTACHES AGAIN, ALL THE META DATA THAT INFORMS CLIENT HOW THIS COLUMN IS ENCRYPTED. WHICH WILL YOUS AT THIS TIME TO DECRYPT THE NAME VALUE FROM THE RESULT SET PRESENTING PLAIN TEXT TO THE APPLICATION. SO WHAT YOU GET HERE, TO KIND OF TAKE AWAY FROM THIS SLIDE, ALL OF THIS APPLICATION WORK FLOW THAT YOU SEE ON THE RIGHT-HAND SIDE OF THE THIS DIAGRAM, ALL OF THIS COMPLEXITIES HIDDEN FROM THE MIXING POINT OF VIEW, RIGHT? IT SENDS A QUERY, SUBMITTING PLAIN TEXT DATA AND RECEIVES A PLAIN TEXT RESPONSE, PLAIN TEXT RESULTS, THAT’S ONE KEY POINT. THE OTHER THING IS THAT BECAUSE OF THE TERM SEEKING ENCRYPTION WE CAN SUPPORT SOME TYPES OF QUERIES LIKE EQUALITY COMPARISON IN POINT LOOK UP SEARCHES. SO THAT’S, THAT’S HOW IT WORKS TODAY. YOU HAVE A QUESTION? [ INDISCERNIBLE ]>>SO A QUESTION IS HOW DOES SQL SERVER KNOW WHAT DATA SHOULD ENCRYPTED. I WILL SHOW AWE TO YOU IN DEMO IN SECOND. BASICALLY WHEN YOU DWOIN, THIS IS PART OF YOUR TABLE SCHEMA. SO, WHEN YOU DEFINE A SCHEMA YOU WILL DESIGNATE SOME COLUMN AS ENCRYPTED. OKAY. SO THAT’S WHAT WE HAVE TODAY. NOW YOU MAY IS AN OKAY, EQUALITY COMPARISON, THAT’S GREAT I CAN DO POINT LOOK UP SEARCHS EQUALITY JOINTS. WELL, FOR MANY APPLICATION THINGS, AND WE GOT THIS FEEDBACK FROM CUSTOMERS KIND OF KNEW THAT THAT FROM THE TIME WE EVEN SHIPPED THIS IN THIS VERSION OF ALWAYS ENCRYPTED EQUALITY COMPARISON IS NOT SUFFICIENT FOR MANY TYPES OF APPLICATIONS. RIGHT? IF YOU HAVE AN APPLICATION THAT PROCESS RICH PERSONALLY IDENTIFIABLE INFORMATION, LIKE NAMES OF ADDRESSES PHONE NUMBERS AND SO N, THERE’S A CHANCE YOU WANT TO DO MORE THAN EQUALITY COMPARISON. YOU MAY WANT TO DO POINT LOOK UP SEARCHS OR SORT THESE VALUES OR YOU CAN YOU MAY WANT TO PERFORM MATH COMPUTATIONS ON SENSITIVE NUMERICAL DATA. TO ACHIEVE THAT TODAY WITH ALWAYS ENCRYPTED THE CURRENT VERSION OF ANY OTHER ENCRYPTION TECHNOLOGY THAT PROTECTS DATA IN USE, IN FACT, YOU’D HAVE TO MODIFY EXTENSIVELY YOUR APPLICATIONS SO THAT THEY PULL OUT DATA FROM THE DATABASE AND REIMPLEMENT YOUR BUSINESS LOGIC ON THE CLIENT SIDE. AND IF YOU HAVE SUFFICIENTLY LARGE DATA SET THEY WILL JUST NOT SCALE, RIGHT? IT WILL BE EXTREMELY HARD FOR YOU TO ACHIEVE THAT. SO THAT’S WHAT I MEANT, AND EARLIER WHEN I SAID ACHIEVING THESE TWO GOALS PROTECTS SENSITIVE TODAY USE ON ONE SIDE AND PRESERVING AN ABILITY TO PERFORM RICH COMPUTATION THAT IS SOMETHING THAT IS VERY HARD. SO THAT’S ONE PROBLEM. SECOND PROBLEM MORE ON OPERATIONAL SIDE. FOR THOSE OF YOU WHO USE ALWAYS ENCRYPTED, SQL SERVER 2016-17 OR AZURE SQL DATABASE YOU KNOW IN ORDER TO PERFORM IN CRYPT GRAFK TO ENCRYPT DATA FOR FIRST TIME OR UPDATE, YOU HAVE TO MOVE ALL YOUR DATA OUTSIDE OF DATA PACE TO PERFORM THESE OPERATIONS ON A DIFFERENT MACHINE. AND THEN UP LOAD THE DATA BACK. SQL SERVER CANNOT PERFORM THESE OPERATIONS FOR YOU BY DESIGN BECAUSE IT DOESN’T HAVE ACCESS TO THE KEYS. SO THAT’S AGAIN, CHALLENGING BOTH FROM PERFORMANCE REASONS ALSO FROM COMPLIANCE, SECURITY REASONS NOW YOU NEED TO HAVE THIS, THIS OTHER MACHINE THAT IS PART OF YOUR COMPLIANCE SECURITY DOMAIN WHICH CAN SAFELY ACCESS ENCRYPTED PLAIN TEXT DATA AND FILE ENCRYPTED REENCRYPTED. RIGHT? THESE ARE MAIN TWO CHALLENGES WE’RE TRYING TO SOLVE. AND THE TECHNOLOGY THAT WE WILL USE TO TACKLE THESE HARD PROBLEMS IS CALLED SECURE ENCLAVES. SO LET ME SPEND A FEW MINUTES SLAINING WHAT ENCLAVES ARE. HOW MUCH OF YOU HAVE HEARD OF TECHNOLOGY INTEL S G X? A FEW. ALL RIGHT. SO, ENCLAVE IS A SPECIAL REGION OF MEMORY. IT’S ISOLATED PROTECTED REGION OF MEMORY WHICH IS OF COURSE, PART OF CONTAINED PROCESS. AND IT HAS SOME REALLY COOL SPECIAL PROPERTIES. RIGHT? NAMELY IT IS BASICALLY NOT ACCESSIBLE TO NOT JUST THE CONTAINING PROCESS BUT EVERYTHING ELSE ON THIS MACHINE. ALL OTHER PROCESSES, AND THE V O S ITSELF. SO IS BLACK BOX THAT CANNOT BE ACCESSED BY ADMINISTRATORS, OPERATING SYSTEM, OTHER PROCESSES AND ALL THE CONTAINING PROCESS ON THE MACHINE. OKAY. AND IT RUNS MACON CONTAIN COLUMN DATA AND THAT COLUMN NEEDS TO BE ASSIGNED IN SPECIAL WAY TO RUN INSIDE THE ENCLAVE. NOW THERE ARE SEVERAL WAYS TO ACHIEVE ENCLAVE ISOLATION TO ACHIEVE TO PROTECT THE ENCLAVE MEMORY. AND DIFFERENT TECHNOLOGIES ACHIEVE THAT IN A DIFFERENT WAY. WE CAN CATEGORIZE THEM IN GENERAL IN TWO PACKETS SOME HARD WORK AND SGX OR EXAMPLES OF THOSE. SO, IN THE CASE HARDWARE TECHNOLOGY I SAY ISOLATION OF HARDWARE OF ENCLAVE IS PROVIDED IN CASE OF INTEL SGX BY THE CPU ITSELF AND ENCLAVE MEMORY IS ENCRYPTED. AND IT’S THEREFORE, THE DATA INS CODE IN IT OR NOT VISIBLE FR ANYTHING ELSE ON THE MACHINE. THE OTHER TECHNOLOGY OTHER TYPES OF TECHNOLOGIES ARE LEVERAGE AN IN THIS CASE HI PROVIDER IS ENTITY THAT GUARANTEES THE SECURITY AND ISOLATION OF THE ENCLAVE. AND VIRTUALIZATION BASED SECURITY ENCLAVES IN WINDOWS ARE EXAMPLE OF THIS APPROACH. SO TO GIVE YOU AN IDEA HOW, WHAT THE EXPERIENCE WOULD BE, IF YOU TRY TO ACCESS THE MEMORY OF AN ENCLAVE, THIS A SCREEN SHOT I TOOK AFTER I OPENED THE WIN DB DEBUGGER AND CONNECTED TO PROCESS THAT I FOUND ENCLAVE MEMORY. SO, I WAS PRETENDING TO BE AN ATTACKER THAT WANTS TO EX FILTRATE THE DATA FROM THE ENCLAVE. RIGHT? THIS IS WHAT I COULD SEE. THE QUESTION MARKS. I WAS NOT ABLE TO SEE THE ACTUAL DATA. SO IF YOU PERFORM MEMORY SCANNING ATTACK YOU WON’T BE ABLE TO SEE ENCLAVE MEMORY. IF YOU TAKE MEMORY DUMP YOU WON’T FIND ENCLAVE MEMORY IN THE DUMP. SO THESE ARE KEY PROPERTIES OF ENCLAVES THAT LINK THEM VERY ATTRACTIVE TECHNOLOGY SO SERVE AS TRUSTED EXECUTION ENVIRONMENTS FOR PROSING SENSITIVE INFORMATION. SO THAT IS EXACTLY WHAT WE ARE USING IN UPCOMING VERSION OF ALWAYS ENCRYPTED. CALLED ALWAYS ENCRYPTED WITH SECURE ENCLAVES. WE’RE ACTUALLY VERY EXCITED ABOUT SQL SERVER 2019 WHICH WILL WAS ANNOUNCED EARLIER THIS WEEK. THERE IS A PUBLIC PREVIEW OF SQL SERVER 2019 ALREADY AVAILABLE TO YOU AND IT DOES INCLUDE ALWAYS ENCRYPTED WITH SECURE ENCLAVES. WE VBS ENCLAVES IN THE CURRENT VERSION. SO YOU CAN NOW ALL OF YOU CAN NOW SEE AND TRY AND TEST IT. SO FROM THE SECURITY STANDPOINT THE GOAL OF ALWAYS ENCRYPTED WITH SECURE ENCLAVES DOESN’T CHANGE. THE GOAL IS STILL TO PROTECT SENSITIVE DATA FROM HIGH PRIVILEGE BUT UNAUTHORIZED USERS. IT WILL DBA ADMINS TO SEE THE DATA. WHAT WE WANT TO IMPROVE ON IS FUNCTIONALITY. WE WANT TO PRESERVE STL ABILITY TO PROCESS RICH QUERY AND SUPPORT ENCRYPTION SO YOU DON’T HAVE TO MOVE YOUR DATA OUTSIDE THE. THIS HOW WE GOING TO DO THAT. SO WE HAVE MODIFIED SQL SERVER SO THAT WHEN IT STARTS IT LOADS VBS ENCLAVE. SO SQL SERVER NOW IS A HOSTING PROCESS THAT CONTAINS AN ENCLAVE. AND THIS THIS ENCLAVE RUNS THE CODE THAT RESPONSIBLE FOR EVALUATING CERTAIN EXPRESSIONS AND SQL QUERIES. SO IN THIS ENCLAVE ESSENTIALLY ACTS AS AN EXTENSION OF THE CLIENT ON THE SERVER SIDE. YOU CAN THINK OF IT AS TRUSTED REPRESENT OF THE KLEIN APPLICATION WITHIN THE SQL SERVER ENVIRONMENT. LIKE AN ALLY BEHIND ENEMY LINES. OR LIKE A FOREIGN OFFICE IN A GIVEN COUNTRY. RIGHT? IT’S AN EXTENSION OF THE CLIENT SIDE BOUNDARY. THE WAY WE USE ENCLAVE DURING QUERY PROCESSING SQL SERVER DELEGATES CERTAIN OPERATIONS THROUGH THE ENCLAVE. BUT NOW BEING TRUSTED EXECUTION ENVIRONMENT CAN SAFELY DECRYPT DATA AND PERFORM COMPUTATIONS ON PLAIN TEXT. SO THAT OPENS UP NEW POSSIBILITIES. WE CAN SUPPORT IN GENERAL, ALL KINDS OF QUERIES, WE STARTING WITH A FEW THAT SOME OF YOU AND OTHER CUSTOMERS HAVE ASKED FOR AND THAT’S OUR TOP PRIORITY. SO WE WE WANT TO SUPPORT IN CURRENT VERSION IN THE CURRENT PREVIEW VERSION OF SQL SERVER 2019 WE SUPPORT RICH QUERIES LIKE LIGHT PREYED INDICATES AND ARRANGE QUERIES WE’RE STILL WORKING ON INDEXING AND I CAN TELL MORE BUT OH ROAD MAP N( THE FUTURE IN THE NEXT SLIDE IN THE ONE OF THE NEXT SLIDES OUR ROAD MAP FOR THE NEXT RELEASES. AND ONE MORE THING THE GIVES YOU IN PLACE ENCRYPTION. SO WITH ENCLAVES WE CAN ALSO DELEGATE CRYPT GRAPHIC OPERATIONS AND YOU DON’T HAVE TO USE DATA AND THAT RUN ON CLIENT SIDE YOU CAN ENCLAVE CAN PERFORM THESE CRYPT GRAPHIC OPERATIONS FOR YOU LOCALLY SECURELY INSIDE SQL SERVER. THERE’S A QUESTION. WE WILL TALK IT MORE THE I WILL REPEAT THE QUESTION ARE THERE ANY SPECIFIC REQUIREMENTS REGARDING VERSION EVER WINDOWS OR HARDWARE. SO YES ARE THERE SPECIFIC REQUIREMENTS REGARDING IN GENERAL I THINK THE CORRECT ANSWER IS BOTH. AND BUT DEAN CAN ELABORATE ON THAT WHEN HE TALKS ABOUT THAT. THIS TECHNOLOGY IS AVAILABLE IN LATEST VERSION OF WINDOWS AND SQL SERVER 2019 AND CLIENT COUNTERPART WHICH IS WINDOWS 10 VERSION 1809 IF I’M NOT MISTAKEN. OKAY. AND REGARDING HARDWARE WE WILL TALK RECOMMEND YOUR MACHINE IS EQUIPPED WITH TP AND 2.0 FOR PRODUCTION PURPOSES. YOU DON’T HAVE TO HAVE IT PROTESTING. WE’LL GET THERE. OKAY. THEED QUESTION IS RELATIONSHIP BETWEEN ENCLAVE AND SQL SERVER. SO SQL SERVER CONTINUES JUST ONE ENCLAVE. ENCLAVE IS STATELESS. SO NOT QUITE STATELESS, BUT IT CONTAINS INFORMATION ABOUT SESSIONS. I WILL GET TO THAT IN A SECOND. ONE PER SQL SERVER PROCESS. OKAY. ALL RIGHT. SO I JUST TOLD YOU THAT THIS ENCLAVE IS RESPONSIBLE FOR PROCESSING SENSITIVE DATA AND IT’S CAPABLE OF DECRYPTING SENSITIVE DATA AND CAN OPERATE ON SENSITIVE DATA AT THAT ON PLAIN TEXT, RIGHT?>>SO AND BASICALLY, THE ASSUMPTION HERE IS ENCLAVE AN EXTENSION OF A CLIENT SIZE TRUST BOUNDARY THE CLIENT CAN TRUST THIS ENCLAVE, IT AS TRUSTED FRIEND OFF THE CLIENT APPLICATION. BUT HOW DO YOU KNOW AND HOW DOES THE APPLICATION KNOW THAT THAT’S TRUE? THAT THIS ENCLAVE IS TRUSTED FRIEND NOT AN ENEMY, RIGHT? THAT THIS ENCLAVE DOESN’T RUN PERHAPS MALICIOUS CODE THAT PUBLISHES YOUR SENSITIVE DATA ON TO THE INTERNET DIRECTLY OR INDIRECTLY, RIGHT? SO THAT CHALLENGE, THAT PROBLEM IS ADDRESSED BY WHAT WE CALL ENCLAVE WHICH TYPICALLY INVOLVES THE CLIENT APPLICATION OR AND SQL SERVER INTERACT WITH AN EXTERNAL SERVICE CALLED AN ARTEST STATION AS FAR AS. THE ROLE OF THAT IS TO CERTIFY TO PROVE TO THE CLIENT BEFORE IT ATTEMPTS TO USE THE ENCLAVE, BEFORE IT AUTHORIZES THE USE OF THE ENCLAVE. IT PROVES TO THE CLIENT THAT THE ENCLAVE IS TRUSTWORTHY. GX AND RUNS CODE YOU CAN TRUST. DEAN WILL SPEND ABOUT 15 MINUTES TO TALK ABOUT THAT AFTER I DO MY MY DEMO IN A MOMENT. SO THAT’S ONE COMMON QUESTION THAT POPS UP. THE OTHER QUESTION YOU MIGHT BE THINKING ABOUT IS OKAY, SO I JUST TOLD YOU THAT SQL SERVER NEVER HAS KEYS IN PLAIN TEXT, RIGHT? I ALSO TOLD YOU THAT THE ENCLAVE INSIDE SQL SERVER DECRYPTS THE DATA, RIGHT OR REINCRYPTS THE DATA. QUESTION IS HOW DOES THE ENCLAVE GET THE KEYS IF PART OF SQL SERVER PROCESS. BUT SQL SERVER DOESN’T HAVE KEYS IN PLAIN TEXT. THIS CHALLENGE IS ADDRESSED BY THE CLIENT DRIVER CREATING A SECURE CONNECTION, A SECURE SESSION TO THE ENCLAVE. SO THIS IS DONE TRANSPARENTLY DURING NORMAL CONNECTION SET UP PROCESS. USING TDS PROTOCOL WHICH WE HAVE ENHANCED. SO DURING THAT PART BASICALLY THE CLIENT AND THE ENCLAVE, USING PROTOCOL NOW THEY HAVE SHARED SECRET THAT THEY CAN USE TO THAT THE CLIENT CAN USE TO ENCRYPT COLUMN ENCRYPTION KEYS THAT CAN NOW BE SECURELY PASSED THROUGH ENCLAVE. IS ENCLAVE CAN PERFORM CRYPTOGRAPHIC OPERATIONS ON THE DATA. AND CLIENT ALSO ASSIGNS QUERIES THAT WE HAVE PROPERLY SIGNED QUERIES CAN EXECUTED INSIDE THE ENCLAVE. SORE THERE ARE SOME SECURITY IN DEPTH PROTECTION THAT WE HAVE ADDED AS WELL. OKAY. SO WITH THAT, LET ME SHOW YOU A DEMO OF WHAT IS AN AVAILABLE TODAY AND IN SQL SERVER 2019. OKAY. [ INDISCERNIBLE ] THE QUESTIONS HOW MUCH RAM IS ALLOCATED TO ENCLAVE. ONE WAY TO ANSWER THE QUESTION TODAY IN SQL WE DON’T ALLOCATE A SPECIFIC AMOUNT OF MEMORY. WE KIND OF LET THE ENCLAVE GROW. DYNAMICALLY. WITH VBS ENCLAVES THAT’S VERY EASY. THERE IS NO LIMIT FOR THE SIZE OF THE VBS ENCLAVE. WITH SGX THERE ARE MUCH STRICTER OR LIMITATION REGARDING MEMORY SIZE EXIST BUT EVEN WITH SGX WE CAN WORK WITH FAIRLY SMALL ENCLAVES. SO SIZE IS NOT AN ISSUE WITH VBS IS NOT AN ISSUE BECAUSE, THERE IS NO LIMITATION IN FACT. OKAY. ALL RIGHT. WHICH NUMBER AM I HERE? 4, I THINK. I GUESS I’M NOT CONNECTED. SORRY ABOUT THAT. ALL RIGHT FOR THIS DEMO I’M GOING TO USE VERY SIMPLE DATA SET. IT HAS JUST ONE DATABASE, WITH ONE TABLE. SO LET’S SEE WHAT THIS TABLE CONTAINS. IT CONTAINS SOME INFORMATION ABOUT EMPLOYEES, SOCIAL SECURITY NUMBERS, AND OTHER FIGURES SENSITIVE INFORMATION IN THAT TABLE. AND RIGHT NOW I’M RUNNING A DATABASE ADMINISTRATOR I CAN SEE ALL DATA IN PLAIN TEXT WITHOUT ANY ISSUES. I’M AN MACHINE ADMIN ON THIS MACHINE, OR IF I’M MALWARE I’VE EVEN MORE MEANS AND WAYS EX FILTRATE THE DATA I CAN SCAN MEMORY I CAN GENERATE DOWN FILE AND A KNOW THE DATA WILL BE THERE IN PLAIN TEXT. SO THAT’S STARTING POINT FOR THIS DEMO. NOW I ALSO HAVE A WEB APPLICATION WHICH IS VERY BASIC THAT DISPLAYS ALL THIS DATA. AND IN ADDITION TO THAT, IT ALLOWS ME TO DO SOME FILTERING. SO I CAN FARLT THESE EMPLOYEES BY OR FILLER THEM BY PORTION OF SOCIAL SECURITY NUMBER. NOW IF I, LET’S SEE, IF I, IF I USE THIS APPLICATION, AS A POINT OF TIME IT TRIGGER AS QUERY. LET’S SEE WHOU THIS A QUERY LOOKS LIKE FROM SQL SERVER POINT OF VIEW. THIS IS WHAT SQL SERVER GETS, RIGHT? AS YOU CAN SEE A FAIRLY RICH QUERY IT A CONTAINS LIGHT PREDICATE ON SALARY COLUMN. THIS IS THE GOAL FOR THIS DEMO IOWA NT TO PROTECT SENSE AT THIS DATA IN USE I WANT TO MAKE SURE THAT HIGH PRIVILEGE BUT UNAUTHORIZED USERS LIKE D B A CANNON ACCESS SENSITIVE DATA IN PLAIN TEXT I WANT TO DO IN SUCH A WAY IT KEEPS MY APPLICATION UNCHANGED. I WANT THIS PARTICULAR QUERY TO CONTINUE TO RUN IN THE UNCHANGED FORM. OKAY. SO THAT’S, THE GOAL. I WANT TO LOAD THE TODAY TASHGS REPLICATE IT’S COMPUTATION ON THE APPLICATION SIDE. OKAY. SO LET’S DO THAT. AND WE’LL DO THAT BY CONFIGURING ALWAYS ENCRYPT USING ENCLAVES FOR THIS PARTICULAR TABLE. SO THE FIRST STEP FOR YOU TO USE ALWAYS ENCRYPTED, I’M SKIPPING THE SET UP PART WHICH IS NOT THAT EXCITING HERE. SO THERE A BUNCH OF CONFIGURATION THAT YOU NEED TO DO, AND, WE WILL TALK ABOUT IT LATER ON. BUT AFTER YOU SET IT UP, THE FIRST STEP YOU WILL DO IN SQL SERVER IS YOU WOULD CREATE A MASTER KEY. THIS IS KEY PROTECTOR THAT WE USE IN ALWAYS ENCRYPTED. ACTUALLY, HAVE ALREADY CREATED A MASTER KEY CERTIFICATE I’M CREATE A META DATA OBJECT WHICH DESCRIBES REFERENCES THIS MASTER KEY WHICH IS A CERTIFICATE. SO LET ME DO THAT. AND THERE IS ONE LITTLE DETAIL I WANT TO HIGHLIGHT HERE. ALLOW ENCLAVE COMPUTATIONS CHECK BOX. I CHECK IT, I SELECT IT, TO EXPRESS MY INTENTION WHICH IS I WANT COLUMN ENCRYPTION KEYS THAT WILL BE PROTECTED WITH THIS KEY PROTECTOR WITH THIS MASTER KEY. TO PERMITTED TO BE USED INSIDE ENCLAVE COMPUTATIONS. OKAY. SO LET’S DO THAT. LET’S COMPLETE THIS DIALOGUE. SO I CAN BRIEFLY SHOW YOU WHAT THIS DID TO THE DATABASE. THIS IS SCRIPT FOR CREATING META DATA OBJECT. YOU CAN SEE ENCLAVE COMPUTATIONS PROPERTY AND ALSO SIGNATURE WAS DYNAMICALLY GENERATED BY THIS TOOL. IT PREVENTS META DATA INCLUDING THIS PROPERTY FROM TAMPERING. SO THAT YOU DON’T WANT AS A DATA OWNER FOR YOUR DATA TO BE USED ENCLAVE COMPUTATIONS YOU HAVE A MECHANISM TO ENFORCE IT. RIGHT? SO THAT’S, THAT’S SIGNATURE ACHIEVES THAT. OKAY. SO WE HAVE A MASTER KEY, WHAT ELSE DO WEENIE COLUMN ENCRYPTION KEY, RIGHT? TO ENCRYPT OUR DATA. LET’S NAME THE DESCRIBING IT. LET’S CLICK OKAY. MULTIPLE THINGS HAPPEN TO WHEN I CLICK OKAY. GENERATED IT WAS ENCRYPTED GOTTEN CRYPT WITH MASTER KEY AND UP LOADED A META DATA OBJECT TO THE DATABASE. OKAY. SO I HAVE A KEY. LE ME TRY TO ENCRYPT. SO FOR NOW THAT ARE FAMILIAR WITH CURRENT VERSION OF ALWAYS ENCRYPTED WHAT WOULD YOU DO TO ENCRYPT YOUR DATA? WHAT DO YOU USE IN WHAT IS YOUR FAVORITE TOOL YOU HAVE TWO TO PICK FROM. SSIS IS ONE OPTION. MAYBE MORE THAN TWO. ALWAYS ENCRYPTED WIZARD AND SQL SERVER MANAGEMENT STUDIO OR POWER. SO WITH ALWAYS ENCRYPT WIZARD, YOU BASICALLY GO HERE AND OPEN ENCRYPT COLUMN ASKS YOU WOULD COMPLETE THIS WIZARD, AT THE END THAT WOULD TRIGGER UNCONSUMING TODAY AT THAT MIGRATION OPERATION MOVE ALL THE DATA FROM THE DATABASE ENCRYPTED UP LOADED. WE DON’T WANT THAT, RIGHT? INSTEAD WE WANT TONE CRYPT THIS DATA IN PLACE. AND WHAT THE CHANGES WE HAVE DONE, IN SQL SERVER 2019 YOU CAN DO THESE OPERATIONS USING PLAIN BORING OTHER TABLE OTHER COLUMNS SYNTAX. YOU CAN DO ALL THAT IN SQL SERVER THERE ONE CONDITION HOW YOU’RE ACTING AS AN OWNER OF DATA, RIGHT? WHICH MEANS YOU WILL ENCRYPTING IT AND THAT MEANS THAT YOU NEED TO HAVE ACCESS TO THE KEYS. SO THERE ARE CERTAIN CONDITIONS THAT YOU NEED TO MEET. SO YOU NEED TO RUN THIS OPERATION FROM THE MACHINE THAT HAS ACCESS TO THE MASTER KEY. IN ADDITION YOU NEED TO ENSURE THAT YOU ALWAYS ENCRYPT ENABLING DATABASE CONNECTION. AND, THAT YOU SPECIFY THE END POINT OF THE OTHER STATION SERVICE THAT WILL BE USED TO VERIFY ENCLAVE BEFORE IN PLACE ENCRYPTION ACTUALLY HAPPENS. OKAY. AGAIN THAT’S SOMETHING THAT WE’LL ELABORATE AFTER THE DEMO. OKAY. SO LET’S RUN THIS SCRIPT. OKAY. SO IT’S COMPLETE INSTANTLY PARTIALLY BECAUSE I HAVE VERY SMALL DATA SET BUT MAINLY BECAUSE ALL OF THIS OPERATION CRYPTOGRAPHIC ENCRYPTION OPERATION HAPPENED LOCALLY INSIDE SQL SERVER, NO DATA MOVEMENT WAS INVOLVED. RIGHT? SO HOW DO WE KNOW DATA WAS ENCRYPTED? NOW BACK TO MY FIRST QUERY WINDOW. YOU CAN SEE PREVIOUS RESULTS OF IT RIGHT. NOW LET ME RERUN IT. SO NOW, AS A TPA I CAN ONLY SEE SSN AND SALARY VALUES ENCRYPTED. AND SURE IF I CHANGE MY CONNECTION PROPERTIES AND IF I SPECIFY, YOU KNOW, THIS FLAG FOR THIS QUERY WINDOW I WILL BE ABLE TO DECRYPT THE DATA. BUT, ONLY BECAUSE I HAVE THE MASTER KEY ON THIS MACHINE. IF I DO THE SAME THING ON THE MACHINE THAT HASN’T HAD MASTER KEY I WILL GET THE NOT BE ABLE TO GET ACCESS TO PLAIN TEXT. OKAY. SO NOW, WE HAVE DATA ENCRYPTED. LET’S SEE HOW OUR WEB APPLICATION GOT IMPACTED BY PUTTING ENCRYPTION IN PLACE INSIDE THE DATABASE. LET ME REFRESH THIS APP. SO YOU CANS SEE IT STILL SHOWS DATA. IT IN PLAIN TEXT BECAUSE THIS APPLICATION HAS BEEN PRECONFIGURED WITH THESE CONNECTION PROPERTIES THAT I SHOWED YOU IN SSMS ALWAYS ENCRYPTED ENABLED IN DATABASE CONNECTION. WHAT IT DOES IT TURNS TRANSPARENT DECRYPTION ON IN THIS CASE. THE RESULTS THAT ARE ENCRYPTED FORM DRIVER DECRYPTS THEM AND SHOWS PLAIN TEXT TO THE APPLICATION. RIGHT? SO THAT’S WHY THE APPLICATION CAN SEE THAT DATA IN PLAIN TEXT BECAUSE IT HAS ACCESS TO THE KEYS. BUT NOT ONLY THAT, THE MOST IMPORTANT DETAIL HERE IS THAT THESE FILTERING CAPABILITIES FILTERING BY SALARY AND SOCIAL SECURITY NUMBER, PORTION STILL WORK. SO LET’S SEE IF AND HOW THE QUERIES, THIS APPLICATION ISSUES HAVE CHANGED. I WILL GO BEING BACK TO MY EXTENDED EVENT SESSION AND I WILL SHOW YOU HOW THE QUERY THAT SQL SERVER GETS LOOKS LIKE NOW. OKAY. SO TWO THINGS TO NOTE HERE, NO CHANGE TO THE QUERY STATEMENT. THIS IS THE SAME RICH QUERY THAT YOU SAW BEFORE. DESPITE THE FACT THAT MY TWO COLUMNS ARE ENCRYPT NOW AND SQL SERVER DOESN’T HAVE ACCESS TO THE UNTRUSTED PORTION DOESN’T HAVE ACCESS TO PLAIN TEXT, IT CAN PROCESS IT. RIGHT? THE SECOND THING TO NOTE IS THAT THE SEARCH CRITERIA QUERY PARAMETERS SQL SERVER GETS THEM IN ENCRYPTED FORM NOW. BECAUSE AGAIN, THE USUAL ALWAYS ENCRYPT AND CAUSES THESE SALARY MINIMUMS S S AND PARAMETERS TO BE ENCRYPTED INSIDE THE CLIENT DRIVER. SO THE SQL SERVER GETS PARAMETERS IN ENCRYPTED FORM. HAS THE DATA STORED IN EMPLOYEE TABLE ENCRYPTED FORM. IT SENDS THIS DATA TO THE ENCLAVE, THE ENCLAVE SAFELY DECRYPTS THE DATA AND CAN PERFORM COMPARISONS MATCHING ON PLAIN TEXT. SO’S THAT THE HOW IT WORKS. SO WHAT I ACHIEVE AND MANAGE TO PROTECT SENSITIVE DATA IN USE FROM AND AT THE SAME TIME, I, I’VE DONE THAT WITHOUT CHANGING MY APPLICATION QUERIES. I DIDN’T HAVE TO REENGINEER MY APPLICATION TO LOAD THE DATA. PERFORM COMPUTATIONS LOCALLY. OKAY. SO NOW AS WE SAID EARLIER, ALL THAT WORKS WITH THE ASSUMPTION THIS ENCLAVE IS TRUSTED ENTITY. THAT IT’S A TRUSTED REPRESENTATIVE OF THE CLIENT APPLICATION ON THE SERVER SIDE. SO NOW HOW DO WE KNOW THAT THAT’S TRULY THE CASE? OKAY HOW DOES THE APPLICATION GETS THIS ASSURANCE? SO NOW DEAN WILL WALK YOU THROUGH THE WORK FLOW TESTING ENCLAVE MAYBE AFTER YOU EXPLAIN WHAT IT IS AND HOW IT WORKS.>>SOUNDS LIKE A GOOD PLAN. ALL RIGHT. SO, WHAT WE’RE TALKING ABOUT HERE IS THIS IS SERVICE WHO PURPOSE IN LIFE IS BECOME A ROLE IN WINDOWS HAS THERE SINCE SERVER 2016 AND MATURED IN 2019. PURPOSE IN LIFE IS TO SIT IN PHYSICALLY SECURE DATA CENTER SOMEWHERE AND ATTEST TO THE HEALTH OF OTHER WORK LOADS. THE PROCESS OF AT STATION IS I TAKE MEASUREMENTS FROM SOMETHING TIP KEEL CRYPTOGRAPHIC MEASUREMENTS AND COMPARE THEN AGAINST PRECONFIGURED WHITE LISTED POLICY AND THAT GIVES ME THE ABILITY TO SAY HEALTHY OR UNHEALTHY. THAT’S BASICALLY WHAT THE HOST GUARDIANS SERVICE DOES. NOW IT DOESN’T IT CURRENTLY FOR PRECISELY TWO WORK LOADS. THE FIRST IS FOR HYPER B WE USE TECHNOLOGY I ALSO OWN. AND WE USE FOR SQL SERVERALS ENCRYPTED WITH ENCLAVES. SO WE EXPECT THIS MODEL TO MA MA CHUR. RIGHT NOW IT’S A MICROSOFT ONLY THING WE EVENTUALLY WILL EXPOSE IT A USE THIS TRUST EXECUTION BUT FOR NOW MICROSOFT ONLY THING REASONABLE MICROSOFT ONLY BECAUSE WE HAVEN’T BUILT LIKE A CODE SIGNING PORTAL OR WAYS OF FIGURING OUT BINARY SHOULD EVEN BE SIGNED. BECAUSE EVERYBODY WANTS BE SOME WRITE BINARY THAT BUILT IN VIRUS AND SIGNING IN CODE SIGNING PORTAL AND SOMEWHAT GIVING IMPLICIT TRUST BECAUSE IT RUNS INSIDE AN ENCLAF. WE HAVE GOT SOME WORK TO DO NOW TECHNOLOGY WORKING FOR US TO ENSURE WE CAN OFFER THIS TO THIRD PARTIES. NOW KNOW WHAT PROCESS ATTESTATION WORKS WORK. WITH MY REGULAR ODD EVENS I TEND TO BE A ROOM FOR I T SECURITY GEEKS. MY SUSPICION HERE IS I DON’T HAVE ROOM FULL OF I T SECURITY GEEKS AND DBA GEEKS WOULD BE MY GUESS I WILL WOW YOU WITH SCIENCE YOU MAY NOT UNDERSTAND BUT HOPEFULLY, YOU’LL WALK OUT OF THIS ROOM SAYING THIS ISN’T SECURITY THEATER THIS IS JEN WINL STRONG SECURITY CONTROLS PUT IN PLACE BY WINDOWS, TO PREVENT MALICIOUS SOFTWARE OR EVEN ADMINS BRUN RUNNING ON A HOST WHERE DATA PHYSICAL RESIDES FROM EVEN GETTING INTO THAT TODAY. THAT’S THE GOAL. SO HOW DO WE IDENTIFY A SQL SERVER ALLOWED. HOW DO WE DO THAT? COULD WE IDENTIFY IT BY A NAME OR A SERIAL NUMBER ON THE MOTHER BOARD ON AN TIFR DIRECTOR DOMAIN ACCOUNT? WE COULD USE ALL THE ABOVE. BUT WE CHOSE TO USE WAS SOMETHING EXTREMELY STRONG STRONG. WE CHOSE TO TPM. WHO HEARD OF TERM TPM? OKAY THAT IS MOST OF YOU GREAT. TPM TRUSTED PLATFORM MODULE A TINY LITTLE MICRO CHIP THAT RUN ON MOTHER BOARD OF MOST P CS RUN IN LAPTOP AND SERVERS AND A USED AS WAY OF SECURELY CEILING KEYS. I USE VERY DELIBERATELY DECREE SECRETS BUT VERY PARTICULARLY SMALL PIECES OF DATA SECRET IS KEY OTHER PASSWORD. GOES. FEEL FREE TO ASK QUESTIONS. MASSIVELY IMPORTANT THAT YOU UNDERSTAND HOW IT WORKS END TO END BUT COOL TO UNDERSTAND THE SECURITY ASSURANCE STRENGTH THAT COMES FROM IT. WHAT P C BOOTS THESE DAYS YOU’RE TWO BIOSES OLD ONE P CAT OR PCAAT FILES WHAT WE USED TO USE YEARS AGO WAY MACHINE WOULD POWERED ON WITH BIG RED SWITCH, IT WOULD READ BIOS OFF A RAM AND ONE RUN THAT BIOS THAT WOULD EVENTUALLY SET UP HARDWARE AND GO LOOK FOR THE FIRST BOOT DEVICE. BASED UPON THE CONTROLLER AND DISKS IT’S USING THEN GO TO LOGICAL SECTOR OF ABOUT 512 BYTES IN LENGTH. READ IT, AND THEN WITHOUT ANY REGARD FOR WHAT IT SAID RUN IT. THAT SOUNDS INCREDIBLE SECURE AND DIFFICULT TO ATTACK. THAT IS WAY THINGS USED TO WORK THAT WAS VERY, VERY TO INSERT A ROOT KIT CHANGE FIRST SECTOR, MAKE IT GO IN RUN YOUR COMPONENT THAT GOT INTO COMPUTER FIRST, IT THEN WENT BACK TO THE ORIGINAL SECTOR THAT IT MOVED, AND THEN REST OF OPERATING SYSTEM LOADED WITH THIS IN A TEE ROOT KIT LOOKING I CAN SEE EVERYTHING YOU DO AND YOU DON’T KNOW I AM HERE. THAT’S THE PURPOSE OF A ROOT KIT. THAT’S HOW THEY WORK. THEY GET THERE FIRST AND EVERYTHING ELSE DOESN’T REALIZE IT THERE AND INSPECT THAT’S THE PAST IT DOESN’T WORK THAT WAY ANY MORE. REASON I’M POINTING THIS OUT THOUGH IS BECAUSE A LOT OF MACHINES STILL SHIFT FROM VENDORS TODAY WITH SUPPORT FOR BOTH TYPES OF FIRM WARE. P CAT ONE I JUST A UNIFIED FIRM A F E I IS NEW ONE. LOT MACHINES SWITCH WITH P CAT SWITCHED ON YOU HAVE TO TURN ON U F E I. FOR THIS PARTICULAR FEATURE TO YOU KNEE FIRM WARE THE GENTLEMAN HERE WHICH I BELIEVE ASKED A QUESTION ABOUT HARDWARE REQUIREMENT WHAT IS I DON’T REMEMBER WHICH. SOMEBODY YEAH, SO YOU NEED UFEI FIRM WARE FOR ONE. YOU NEED A TPM V 2. 1.2 IS SIMPLY SOMETHING THAT WE COULD HAVE SUPPORTED BUT WE CHOSE NOT TO. THE REASON WE CHOSE NOT TO WE WOULD HAVE REWRITE ATESS STATION MECHANISM FOR, EACH VERSION. WHEN WHEN IT CARRIES THAT MUCH WORK VERSION IS LATER AND GREATER ONE IT MAKES SENSE TO NOT LOOK TO PAST. THIS WAS QUITE LITERALLY RESOURCE THING WE COULD HAVE DONE WE MORE MODERN MORE SECURE. YOU ALSO NEED SOME VERY SPECIFIC TECHNOLOGIES IN THE PLATFORM. TYPICALLY REFERRED TO AS VTX OR VERT LIE SAYINGS EXTENSIONS. MOST OPINIONS THAT YOU BUY THAT YOU WOULD RUN SQL SERVER ON THESE DAYS WILL HAVE THAT SUPPORT FOR FREE. IN MANY CASES IT’S NOT SWITCHED ON. SO YOU WOULD ACTUALLY HAVE TO GO INTO THE FIRM WARE AND POTENTIALLY SWITCH ON INTEL VURLTLIZATION EXTENSIONS WHAT IT STRANDS FOR WHAT REASON WE’RE DOING THIS ENTIRE TECHNOLOGY THE DESCRIBED EARLIER ON TRUSTED EXECUTION ENVIRONMENT, ENCLAVE IT’S ACHIEVED BY USING THE SAME TECHNOLOGY THAT HYPER V AND VM WARE AND AMAZON AZURE USE TO KEEP AN ISOLATION BARRIER BETWEEN TWO VMS EXACTLY THE SAME TECHNOLOGY AS THOSE, NO DIFFERENT AT ALL. INSTEAD OF GUARANTEEING VM ONE CAN’T INSPECT VM2 AND VICE VERSA AND SO ON WE GUARANTEE KEY CAN COMPARTMENT LIES SUCH THAT TINY LITTLE KEY TRUSTED EXECUTION ENVIRONMENT CAN LIVE QUITE SAFELY AND EVEN KERNEL MODE COMPONENTS IN LEGITIMATELY BOOTED EVEN THE KERNAL CANNOT GET IN THERE KERNAL IS NO THE MASTER OF THIS SYSTEM ANY MORE. THE HYPER VISOR IS. SO THE QUESTION THEN BECOMES IF I’VE GOT UFEI I’VE GOT TPM AND VTX AND I’VE GOT WINDOWS I EVER JUST SAID THAT EVENING THE KERNAL CAN’T GET IN THIS I COULD ARGUE THAT, KERM CAN GET IN THERE WHAT IF MACHINE IS NOT BEING MEASURED AND NOT AUTHORITY. NOW IF SOMEBODY BREAKS OUR SOFTWARE MODEL, AND THEY MANAGE TO GET SOMETHING IN BEFORE HYPER VISOR EVERY I GO JUST SAID REND ARE MOOT. WHAT IMPORTANT BUILDING IT ALL POINT IS WE HAVE TO HAVE THAT ALL TO TODAY HARDWARE WE NEED TO MAKE SURE RUNNING AS IT WAS DESIGNED. THAT’S WHERE ATESS STATION COMES IN. SQL SERVER IS DOING ALL THIS MAGIC GOING ON VBS ENCLAVE WINDOWS USING ALL CLEVER VIRTUALIZATION TO MAKE THIS TRUSTWORTHY EXECUTION ENVIRONMENT EXIST AND SOMEBODY CIRCUMVENTED ALL IT BY INSTALLING A ROOT KIT. WE CAN’T DETECT UNLESS SOMEONE IS KNOW AND NO WHAT IS DEFINITION OF HEALTH LOOKS LIKE THAT WHERE ATTESTATION COMES IN. FIRST THING FIRST SQL SERVER TURNED ON FIRM WARE A TPMV2 ALL OF THOSE THINGS AND WINDOWS SERVER 2019 INSTALLED NOW I WANT TO MAKE THAT MACHINE WORK WITH HOST GUARDIAN TO SEEK ATTEST HEALTHY FIRST THING I DO EXTRACT A KEY FROM TMPM CALLED AN ENDORSEMENT KEY. EVERY HAS AN ENDORSEMENT KIA PUBLIC AND PRIVATE KEEPER. WE EXTRACT PUBLIC VERSION WHEN WE USING THAT THE IDENTIFIER WE SHIP PUBLIC KEY FROM TPM OVER TO THE HOST GUARDIAN SERVICE. THIS IS NOT MICROSOFT SHART SECRET ONE KEY CAN USED TO ENCRYPT AND OTHER KEY CAN USED TO DECRYPT. AND FOR MOWS OF YOU AREN’T FAMILIAR IT DOESN’T MATTER CAN WAY ROUND YOU DO ENCRYPT WITH PRIVATE KEY THEN PUBLIC KEY CANDY CRYPT WE USE THAT ARE FOR PURPOSES. BUT PARTICULARLY ENCRYPTS THE PRIVATE KEY DECRYPTS. WHAT DO YOU THINK PRIVATE KEY RESIDES FOREVER ARE AND HE TENL INSIDE TPM IT WILL RELEASE DATA IFS BUT NEVER RELEASE THE KEY. SO, WHEN THE MACHINE NEEDS TO BECOME REGISTER WITH HOST GUARDIAN SERVICE ONE TIME AND ONE TIME ONLY YOU EX ENDORSEMENT KEY PUBLIC FROM TPM AND GIVE TO HOST GUARDIAN SERVICE WHAT YOU ACHIEVED IDENTIFIED A LEGITIMATE HOST. IS NO THE YET BLESS WHAT YOU DO BUILD OPERATING SYSTEM ON HOST TO POINT YOU CONSIDER IT TO BE PERFECT. YOUR GOLDEN IMAGE WITH SQL AND ADMIN TOOLS INSTALLED ANYTHING YOU WANT YOU MAKE IT BOX THAT BUILT PERFECTLY TO YOUR GOLDEN IMAGE. PLEASE DON’T DEBUGGER AND MALWARE AND VIRUS ON THERE OTHERS WE WOULD CONSIDER THING TO BE BLESSED WE’RE ABOUT TO SAY THAT’S TRUSTWORTHY. YOU BUILT IT WITH VIRUS THEN TELL THE TOOL DEEM THIS TRUSTWORTHY LITERALLY RECORD VIRUS A BEING TRUSTWORTHY. BUILD IT WITH PERFECT SET OF TOOLS. YOU THEN RUN A PROCESS TO GO AND SCAVENGE ALL OF THAT INFORMATION CAN & WE RECORD THAT HAVE A MAJORITY IS ISN’T EVERY SINGLE BINARY ON DISKS THOSE THAT CONSTITUTE THE BOOT PART PATH. THIS IS WHAT I WANT YOU TO UNDERSTAND HOW THOROUGH THIS IS. SO WHEN MACHINE BOOTS UP UFEI FIRM WARE LOOTDZ FINALS ISSUES A LOOKS IN INFO DATABASE ONE CLEVERLY CALLED DB FAR MORE JOBS DEFINE WHAT AN ABBREVIATION MEANS. IT LITERALLY DABLT THEY COULD IS A CALLED IT DATABASE GOODNESS. WHAT IT IS A SECURE VARIABLE INSIDE THE FIRM WARE THAT DEFINES THE LEGITIMATE CODE SIGNING CERTIFICATE. ANOTHER ONE DATABASE EXCLUDED BLACK LIST IF YOU LIKE OF THINGS YOU SHOULD NEVER LOAD CAN EITHER A HASH OF OS LOAD OTHER CODE SIGNING SIGNIFICANT OF SOMETHING THAT I SAY LEWD TO BOOT SYSTEM AS THE SYSTEM RUNS IT THEN GOES TO THE DISK THAT CONTAINS THEIT READS OS LOADER AND COMPARES CODE SIGNING AND HASH TO DB VARIABLE. AS LONG AS IT FINDS A MATCH, THEN SO FAR IT’S LOOKING GOOD. IT THEN GOES AND DOES THE SAME THING IN DBX TO MAKE SURE IT DIDN’T FIND IT THERE IFFOUND IN BOTH IT WILL REFUSE TO BOOT. IF FOUND IN NEITHER IT WILL REFUSE TO BOOT IF IT DOWNED IT DB THE SYSTEM WILL BOOT. MAKE SENSE? THIS MAKES VERY TO ROOT KIDS A PEOPLE IN PRODUCT GROUP CANNOT GET HOLD CODE SIGN ANY I CAN GET FOR WINDOWS SERVER PRAYS WE OPERATION AND A THAT PLENTY IT FROM DOING ALL THROUGH AUTOMATION. THERE ARE FAR TOO MANY CUE AND MONITOR PHYSICAL PROCESSES IN PLACE TO STOP THAT FROM HAPPENING. GIVEN THAT, IF UFEI IS TRUSTWORTHY THERE NOT MUCH WE CAN DO TO SAY IT IS OR ISN’T WORK WORKING ON TECHNOLOGIES WE TO TRUST HARDWARE TPM. SO IT LOADS, VERIFIES OUT S LOADER AND PROSDZ OF BOOTING P C STARTED. GUESS WHAT FIRST BINARY KNOWS? KNOWS CODE SIGN THING SIGNIFICANT OF SECOND. SO, WHEN FIRST BINARY IS LOADED WE START MEASURING THINGS. WE MEASURE THE FIRST, AND THEN THE SECOND. FIRST KNEW SIGNATURE OF SECOND WOULD REFUSE TO HAND OFF TO THE SECOND BINARY IF BINARY’S SIGNATURE HAD TAMPERED WITH. MAKE SENSE? LITERALLY A CHAIN HERE. SO BINARY 1, WHICH STARRED FROM KNOW WHAT IS BINARY 2 SHOULD LOOK LIKE AND BINARY 2 WHAT BINARY 3 SHOULD LOOK LIKE THERE’S OUR CHAIN IN THE OS. IN ADDITION WE ALSO MEASURE THE BINARIES BY TAKING A HASH. SO HERE WE GO WITH SOME TPM TERMINOLOGY. WE TAKE BINARY WE HASH IT STORE IT INTO REGISTER IN THE TPM. BINARY ONES LOOKS A BINARY 2, BINARY LOOKS GOOD HAND CONTROL TO BINARY 2 NOW WE HASH BINARY 2 AND GET FIXED SIZE RESULT WE LOOK HASH WE JUST PUT PCR NOW WE’VE GO DOUBLE LENGTH HASH WE HASH IT AGAIN, AND PUT IT IN THE PCR NOW BINARY 3 WHAT DO YOU THINK HAPPENS NOW WE REPEAT AD NAUSEAM UNTIL ENTIRE OS IS BOOTED. ITS NOT BLOCK CHANGE NOT PREDICTABLE YOU COULD OBVIOUSLY IMPLEMENT SOMETHING IN THERE, BUT YOU WOULDN’T GET DETECTED RETROACTIVELY IT WOULD MERELY FAIL. SOMEBODY LIKE A BLOCK CHAIN. THESE ARE CALLED TPM MEASUREMENTS THEY WORK BY CEILING CREDITS TO SET OF MEASUREMENTS ONCE OS IS UP AND RUN IMAGINE IT WAS BIT LOCKER FILE TM ENCRYPTION IN WINDOWS ITTY BITTY LOCKER WOULD BE SEALED TO A SET OF PCRS THAT TOOK CERTAIN MEASUREMENTS IN A CERTAIN WAY. AND THE ONLY TIME TPM WOULD EVER RELEASE THIS KEY IF MEASUREMENTS ARE EXACTLY THE SAME. THIS IS HOW TPMS WORK. WE DO ALL OF THIS IN HOST GUARDIAN SERVICE WHEN THAT SQL SERVER COMES UP.BOOT PATH AND ENCLAIFR EVERYTHING ELSE YOU BLESSED ENGINE RATING A FILE IT. CG LOG. AT WHICH POINT THAT IS WHAT WE NEED TO SEE HOW THE MACHINE BOOTED AND WHETHER IT’S HEALTHY. SO SQL SERVER MACHINE BOOTS LOADS FIRM WARE AND LODZ CONTROL DOES POOT GENERATE TKG LOG SENDS IT HOST GURND UNSERVICE COMPARES TO WHITE LIST DOES THIS MATCH. IF IT DOES, YES, THEN IT’S ALL GOODNESS WE THINK. BUT SOMEBODY COULD HAVE LIED. WHAT THEY RECORD T C G AND THREW IT AT SO WHAT HOST GUARDIAN AS FAR AS RUNS THROUGH OPERATIONS AGAIN CALCULATES WHAT VALUES SHOULD BE REACH BACK INTO SQL HOST COMPARES VALUE AND COMPARES TO WHAT IT JUST COMPUTES IF THEY MATCH I KNOW KNOW WHO YOU ARE, I KNOW YOU TOLD ME WHAT YOU DID. AI CAN NOW WITH CRYPTOGRAPHIC CERTAINTY STATE YOU ACTUALLY DID WHAT YOU DID. LAST BUT NOT LEAST IT LOOKS FOR CODE INTEGRITY POLICIES. THAT’S WHAT WE’RE DOING. ALL OF THAT STUFF HAPPENS EVERY SINGLE TIME A SQL SERVER HOST NEEDS TO GET SUFFICIENT HEALTH INFORMATION BACK FROM A TRUSTWORTHY HOST GUARDIAN SERVICE SO IT CAN SIGN ENCLAVE REPORT AND HAVE A CLIENT BE HAPPY TO TALK TO IT AND SEND KEYS OVER TO IT. THAT PROCESS HAPPENS IN LESS THAN A MILLISECOND. SOUNDS COMPLEX BUT IT’S P C THEY ARE PRETTY POWERFUL THESE DAYS WE HAVE VARIETY OF DIFFERENT ATTESTATION MODES ONE MODE I JUST DESCRIBED IS ONE AT THE BOTTOM. THE ONE THAT CHECKMARK NEXT TO IT. THAT’S ONE WE REMEMBERING MEND FOR PRODUCTION ENVIRONMENTS. TOP ONE IS BEING DUPLICATED. AS WE DON’T WANT TO KEEP THAT AROUND TOO COMPLICATED. WE REPLACED WITH SOMETHING SIMPLER HOST KEY ONLY TWO CHOICES SHOULD REALLY BE SHOULD I USE HOST KEY OR TPM YOU’RE BUILDING A LAB YOU JUST WANT TO SEE WHAT SQL SERVER IS ENCRYPTED PERFORMANCE IS LIKE USE HOST KEY MODE. TO ATTEST THE HOST YOU LITERALLY GO ONES ONE COMMAND SHIFT KEY RUN ONE OTHER COMMANDMENTS TOTAL IN NOW MACHINE IS BLESSED. TO DO IT TPM YOU HAVE TO GET EK AND T C G LOG AND CONFIGURE POLICIES ALL OF THESE DIFFERENT THINGS THAT WORK YOU PUT INTO PRODUCTION ENVIRONMENTS LONG-TERM. BUT YOU JUST WANT TO SEE WHAT SQL LOOKS LIKE WHEN RUNNING ENENCLAIFRS IT DOESN’T MAKE THE ONLY YOU GO LOSE BY USING HOST KEY MODE IS ANY GUARANTEE OF TRUSTWORTHINESS IN THE HOST. GO AHEAD. SGX AND T P RELATED. A SGX LIES VBS ENCLAVE DONE IN HARDWARE INSTEAD OF DONE IN SOFTWARE. DO I HAVE TO ARREST SGX AND TPM YOU DO NOT IF YOU WANT TO GOING FORWARD I’M NOT SURE WHEN SQL WILL RELEASE THAT SQL ENCLAIFR VERSION THAT WILL FUNCTION WITH THAT GOING FORWARD RIGHT NOW VBS IS AVAILABLE ON ANY HOST THAT PRETTY MUCH ANY NEW HOST YOU BUY FROM ANYWHERE. EVEN YOUR LAPTOPS WOULD MEET THIS. OKAY. SO USE HOST KEY MODE YOU WANT TO TRY SQL ALWAYS ENCRYPTED IT DOESN’T AFFECT ANYTHING PERFORMANCE ALL IT IS TRUSTWORTHINESS OF THE DEVICE. I GIVE YOU A LITTLE BREAKDOWN HERE IN TERMS OF HOW EACH OF THEM VERIFIES WHETHER OR NOT THE MACHINE IS HEALTHY. YOU’LL NOTICE ONLY BOTTOM ONE REALLY MAKES AN ASSERTION OF HEALTH. REST MAKE ASSERTION OF IDENTITY. I KNOW WHO THE SQL HOST IS BECAUSE HAS PRIVATE KEY BECAUSE AMAIN JOINED AND GOT THIS GROUP. THAT’S ALL WE’RE DOING WITH THE TOP TWO. SO THEY ARE MORE ABOUT RECOGNIZING SOMEBODY WITH SOME KIND OF CRYPTOGRAPHIC IDENTITY. BUT THISSER NOT STRONG ENOUGH THEY DON’T MEASURE THE HEALTH OF A HOST YOU’RE GOING TO FEEDING KEYS INTO AN ENCLAIFR TO DECRYPT VERY SENSITIVE DATA YOU NEED TO RECOGNIZE THE HEALTH OF THE HOST. SO, I WOULD URGE THAT EACH OF YOU TAKE LOOK THROUGH THESE WHEN YOU’RE BUILDING YOUR PROOF OF CONCEPT TO MAKE YOUR CHOICE. B. BUT I WILL STRONGLY RECOMMEND YOUR BEST PRACTICE FOR ANY PRODUCTION SHOULD BE TO IGNORE HOST KEY IGNORE AD THAT ULD WOULD BE A BAD IDEA AND USE TPM TRUSTED ONLY YOU CAN SEE WE MEASURED BOOT WAS REQUIRED THAT WAS PROCESS I JUST SCRIBED CODE INTEGRITY KIND OF OPTIONAL YOU DON’T NEED TO DO WITH SQL HOST FAR MORE POINTER ORN HYPER V PLATFORM IDENTIFICATION IS PART WE EXTRACT AN ENDORSEMENT AND USE IT AS AN IDENTITY. LAST PART FOR ME LET’S WALK TAKE ON ROLL SQL CLIENT AND DRIVER AND I’LL TAKE ON BEING HOST GUARDIAN SERVICE AND MANUALLY ACT THAT OUT ON PAIR I HAD OUTS EXACTLY HOW THIS FLOW RUNS.>>ALL RIGHT. SO ACTUALLY I WILL PLAYING COLLECTIVELY ROLE OF CLIENT IN SQL SERVER. ON SIDE FIRST THING THAT HAPPENS APPLICATION SENDS QUERY, AND THE CLIENT DRIVER INTERSOEPTS IT. AS YOU SAW IN THE PREVIOUS ANIMATION, SO THE FIRST THAT GO CLIENT DRIVER WILL DO AFTER THAT AFTER GETTING THE APPLICATION QUERY AND REMEMBER, THIS IS THE ALWAYS ENCRYPTED SCENARIO, RIGHT? FIRST THING THAT WILL HAPPEN IS THE SAME CALL TO DISCOVERED THE META DATA ABOUT WHICH PARAMETERS NEEDS TO BE ENCRYPTED SO ON. BUT NOW IN SQL SERVER 2019 WE KIND OF OVERLOAD THIS INTERACTION. WE ARE THE NEW PURPOSE TO IT. SO THIS CALL AS HE DESCRIBED TO PROCEDURE INVOCATION. IT ALSO MEANS THAT THE ASK TO SQL GIVE ME THE PROVE ENCLAVE YOU CONTAIN IS TRUSTWORTHY THAT I CAN SAFELY SHARE THE KEYS AND, USE THIS ENCLAVE TO PERFORM COMPUTATIONS ON MY SENSITIVE DATA. RIGHT? SO AFTER THAT WHAT I WOULD DO A SQL SERVER INSTANCE, I WOULD CALL DEAN AND THE GUARDIAN SERVICE TO REQUEST A HOST HEALTH CERTIFICATE. RIGHT? SO DEAN, WHAT IS HAPPENING EXACTLY IN THIS STAGE?>>SO THAT IS AGAIN, THE BACK DOWN TO ATTESTATION MODE. MODE IS WHAT CONTROLS WHAT HAPPENS NEXT. IF YOU DO HOST KIA TESS STATION YOU WANT TO TRY. AND WHAT PERFORMANCE CHARACTERISTIC NUMA ENCRYPTED I SUGGEST YOU USE HOST KEY IT WILL TAKE TWO MINUTES TO SET IT UP. IF IT’S THAT SIMPLE IF HOWEVER YOU WANT TO CHARACTERISTIC ARE LIKE WHEN YOU GOING THROUGH REAL PRODUCTION ENVIRONMENT WHICH OBVIOUSLY YOU WOULD TEND TO DO IN LAB BEFORE YOU TRULY ROLLED IT OUT, THAT’S WHERE THIS DANCE YOU SEE HERE WOULD GIVER ME A HEALTH SIGNIFICANT I NOW I WON’T GIVE ATELL ME WHO YOU ARE I AM OOECHLT K LOOK IT UP YES, I RECOGNIZE IT. GENERATE A SYMMETRIC KEY ENCRYPT IT SEND IT BACK TO SQL HOST PASSES BACK DONE TO HAVE BEENS AND USE TPM IT NOW SYMMETRIC KIA SHARED KEY WHICH WHICH POINT GOOD AFTERNOON ME TCG LOG AND ENCRYPT AN ALL THAT GOOD STUFF SEND IT BACK OVER DECRYPT IT COMPARE IT TO WHITE LIST, YEAH YOU LOOK GOOD. NOW I RUN THROUGH THAT TCG LOG RECOMPUTE WHAT THE VALUES SHOULD LOOK I CAN IN TPM REACH BACK OVER THAT CONNECTION REMOTELY INTO TPM USING PROTOCOL WE INVENTED REMOTE TPM WE REACH BACK IN VALIDATE THE PCR MEASUREMENTS LOOK SAME AS WHAT WE’VE COMPUTED IT IF THEY DO JOB DONE. HEALTH CERTIFICATE. WE THROW BACK A HEALTH SIGNIFICANT EXTRA CONTAINS A PUBLIC SIGNING KEY. THAT WAS BORN ON THE MACHINE INSIDE OUR VBS ENCLAVE. WAS BORN THERE WE SEND THAT BACK INSIDE THE HEALTH CERTIFICATE AND YOU HAVE EXACTLY WHAT HE NEEDS TO PROCEED. RIGHT. SO THE SQL HOST CERTIFICATE AT THIS POINT WHICH WAS SIGNED BY HOST GUARDIAN SERVICE. NEXT THING IT DOES, IT CALLS A LOCAL WINDOWS API TO GET WHAT IS CALLED AN ENCLAVE REPORT. AND ENCLAVE REPORT CONTAINS A BUNCH OF INFORMATION ABOUT THE ENCLAVE ITSELF AND WHAT’S IN IT. WHAT IS THE DLL OR CODE THAT RUNNING INSIDE THE ENCLAVE. AND NOW THIS THIS INFORMATION IS PROVIDED BACK TO SQL CLIENT AS PROOF. SO WHAT FOLLOWS IS CLIENTS VERIFICATION OF THE PROOF. SO THE FIRST THAT GO CLIENTED WOULD DO IT WOULD REACH OUT TO HOST GUARDIAN SERVICE AND THIS IS WHY WE SPECIFY URL NOW IN THE CONNECTION STRENGTHS WHEN WE INTERACT WITH THE DATABASE IN SSMS. THIS IS END POINT OF ATTESTATION SERVICE THAT A CLIENT DRIVER USES TO GET THE PUBLIC KEY AGS AND IT USES THEN THIS PUBLIC KEY TO VERIFY THE HOST HEALTH CERTIFICATE. IF I COULD INTERJECT THERE. WHAT IS THAT DOING TALKING END POIN THAT EXIST WAY BEFORE SQL ASK THIS META DATA END POINT HOW HYPER V DETERMINES TRUST. YOU HAVE TO SAY AT SOME POINT A HUMAN BEING TRUST THAT IS MACHINE. YOU THEN GO TO END POINT WHICH DOESN’T REQUIRE ANY AUTHENTICATION AGENCY LONG YOU CAN REACH IT WILL SEND YOU BACK X ML DOCUMENT WHICH META DOCUMENT. ALL MAP HAPPENING REUSE SAME CODE PATHS WE USED IN HYPER V THAT DESCRIBES A TRUSTWORTHY. AT THIS POINT ASSUMING WE HAVE USED TMM MODE, THE CLIENT KNOWS WHEN THE MACHINE IS HEALTHY AND HAS BOOTED PROPERLY AND MOST IMPORTANTLY THE HYPER VISOR ENTITY THAT PROVIDES ISOLATION AND GUARANTEES, THE SECURITY OF THE ENCLAVE IS HEALTHY AND SECURE. AND HASN’T TAMPERED WITH. THE NEXT THE NEXT STEP IS CLIENT DRIVER VERIFIES THE ENCLAVE REPORT WAS ACTUALLY SIGNED BY THIS HOST. AND THEN, IT ADDITION INTO ENCLAVE REPORT AND VERIFIES THE SIGNATURE. A SPECIFIC SIGNATURE DLL LIBRARY THAT IMPLEMENTS CRYPTOGRAPHIC ON SENSITIVE DATA LIKE RANGE AND SO ON. IT LIBRARY HAS SPECIFIC SIGNATURE. WHICH THE CLIENT DRIVER KNOWS AND COMPARES, VERY IF IS THAT RUNNING ENCLAVE ALSO VERIFIES BY ANY CHANCE IS NO THE RUNNING WITH THE WHAT CALLED DEBUG MODE SO YOU CAN RUN A VBS ENCLAVE IN DEBUG MODE WHEN WE HAVE DEVELOPED WHEN WE’RE DEVELOPING THIS FEATURE OUR DEVELOPERS USE THAT ALLOT. AND THAT’S NOT WHAT YOU WANT IN PRODUCTION. BECAUSE IN DEBUG MODE, ANYBODY CAN ACTUALLY SEE THE ENCLAVE MEMORY. THAT’S ONLY USED FOR DEVELOPMENT PURPOSES. WE WANT TO MAKE SURE ENCLAVE IS NO THE RUNNING DEBUG MODE. THIS ALL KINDS OF CHECKS AND VERIFICATIONS WE DO TO ESTABLISH THE TRUST. BETWEEN CLIENT SERVER, BETWEEN CLIENT APPLICATIONS THE CLIENT DRIVER, AND THE SERVE SIGHT ENCLAVE THAT SUPPOSED TO TRUSTED EXTENSION OF CLIENT ON THE SERVER SIDE. THE MAIN KEY TAKE AWAYS FROM WHAT WE EXPLAINED REGARDING ATESS STATION, TWO ATTESTATIONS HOST KEY TP USE FIRST ONE TO GET STARTED WITH THE FEATURE. THERE’S STEFRPS DOCUMENTATION I WILL POINT YOU IN MOMENT AS DEAN SAID FAIRLY EASY YOU CAN SET IT UP IN A FEW MINUTES. TPM RATTLE BIT MORE TIME CONSUME>>MAYBE NOT SO EASY BUT ONCE YOU DONE POINT BEING COMPLEX CRYPT GRAEF DOES DETECTIVE COMPLEX. ONCE HOST AT ARGUABLY WORSE FOR HYPER V THEY PROBABLY STAND UP TAKE DOWN VIRTUALIZATION FAR MORE THAN YOU STAND UP REPLACE SQL HOSTS THEY ARE WANT FASTER YOUR MOLDS VERY MUCH MAKE IT WORK, MAKER IT WORK ONCE AND I’M KIND OF DONE. GO AHEAD, SIR. DISCERN I INSTALLED SOMETHING ON HOST DO I HAVE TO RECREATE THE SIGNATURE. WAY WE MEASURE DONE WITH CODE SIGNING CERTIFICATES RATHER THAN HASH IF WE HASH BINARY A SINGLE PATCH EVEN FROM MICROSOFT WILL CAUSE A HASH TO CHANGE WE LOOK CODE THAT A YOU’RE ENFOR CODE INTEGRITY POLICIES. CODE INTEGRITY PRERMENT CERTAIN THINGS TO RUN IN HYPER VISOR WILL BLOCK ANYTHING ELSE. WE ED THIS CONVERSATION AD NAUSEAM NOW FOR SQL DBA HYPER HE AND I EVENTUALLY AGREED IS, NOTHING. SO YOU DON’T ENFORCE ANYTHING WHATSOEVER. BECAUSE THE DBA TOOLS TEND TO BE FAIRLY FREQUENTLY CHANGING. AND THERE ISN’T ANYTHING THAT WE CAN SEE IN TERMS OF AN ATTACK VECTOR THAT COULD BE USERED ANYWAY. SO FOR YOUR BINARY THAT YOU’RE WRITING TO BOX YOU PATCHED SOMETHING OR THIRD PARTY ANTI MALWARE OR SOMETHING LIKE THAT YOU MIGHT CAUSE TCG LOG TO CHANGE. UNLIKELY IF WE RECORD IT HAD WITH CODE SIGNING IT WILL WASH EVERYTHING’S HAPPY WITH HYPER VISOR. YOU COULD BREAK IT BUT GWEN THE RECOMMENDATION FOR KWL ALWAYS ENCRYPTED ENCLAVES TO HAVE NO HYPER VISOR ENFORCE OR 0 ONE THAT SHOULDN’T BREAK IT EITHER. IT SHOULD BE EASY.>>ALL RIGHT. IN CLOSING LET ME SHOW WHERE WE ARE IN TERMS OF CURRENT OF THIS TECHNOLOGY AND, THE ROAD MAP FOR NEXT FEW MONTHS OR SO. SO, AS I SAID EARLIER, WE ARE VERY EXCITED ABOUT THE 2019 SQL ANNOUNCEMENT FIRST ARE PUBLIC PREVIEW IN FACT THERE PUBLIC PREVIEW OF SQL SERVER 2019 WHICH MEANS MEANS A, ALL ENCRYPTED WITH ENCLAIFRS ALL OF YOU CAN NOW TRY TO THIS FEATURE AGAIN MODE WATT TOY DO THAT. AND IT COMES WITH ALL THE FUNCTIONALITY THAT I DEMONSTRATE IN ENCRYPTION RICH QUERIES ONE THING THAT YOU WILL NOT YOU CANNOT TRY AND TEST IN THE CURRENT VERSION IS INDEXING. THAT’S VERY CHALLENGING PROBLEM. SUPPORT FOR INDENTIONING ENCRYPT COLUMNS WE’RE WORKING ON IT AND OUR DESIRE OR OR GOAL IS TO SUPPORT IT BY RTM. SO CURRENTLY IF YOU TRY THIS FEATURE, AND TRY, BENCH COMPARISON OR PATCH MATCHING IT WILL BE FAIRLY SLOW. THAT’S WHAT ONE ONE OF THE REASONS WHY WE CURRENTLY RICH QUERIES NOT IN PLACE ENCRYPTION RICH QUERIES ARE DISABLED YOU HAVE TO ENABLE THEM BY SETTING A TRACE FLAG. BECAUSE WE ARE WORKING ON A BUNCH OF OPTIMIZATIONS INCLUDING SUPPORT FOR INDEXING. QUESTION THERE. [ INDISCERNIBLE ]>>HOW MANY COLUMN STORE INDEX. THAT IS FURTHER OUT. THAT’S ON OUR ROAD MAP. BUT YOU MAY NOT SEE IT IN 2019RTM. THAT’S A MAJOR EFFORT. WE’LL TACKLE IT AT SOME POINT, BUT, PROBABLY IT WILL TAKE US A LITTLE BIT MORE TIME. EVERY TIME YOU HEAR HIM SAY ROAD MAP ALL I HEAR HIM SAYING I CONTACTING YOU SOON DEAN SET UP A MEETING BECAUSE I WANT SOMETHING ELSE. THAT’S ALL I HAVE. ALL RIGHT. SO, RIGHT NOW WE USE VBS ENCLAVES AND WES DISCUSSED THIS IS THE TECHNOLOGY THAT IS PORTED WINDOWS SQL SERVER 2019 AND ANY WINDOWS CLIENTS YOUR MACHINE NEEDS TO BE EQUIPPED WITH ONE OF THE SUPPORT. IN ADDITION YOU NEED TO HAVE SEPARATE MACHINE TO RUN THE ATTESTATION SERVICE. WE HAVEN’T TALKED ABOUT POCS YOU NEED JUST ONE EXTERNAL MACHINE TO HOST AGS SINGLE NODE. FOR PRODUCTION YOU WILL HAVE TO HAVE A CLUSTER WE RECOMMEND THREE INSTANCES AGS. YOU CAN HE DID USE VIRTUAL MACHINE. YOU’RE JUST TRYING TO GET ATTESTATION OUT WAY SO YOU CAN SEE SQL DOES. HOW MUCH ARE USING OCCASIONAL SQL DATABASE. AND YOU MAY WONDERING WHEN THIS COMING TO AZURE. WE’RE WORKING ON IT. AZURE IS USING INTEL GS ENCLAVE. THE WORK INVOLVES AMONG OTHER THINGS, PORTING THIS POSITIVE INTEL GX WE’RE WORKING ON. SPEAKING OF AZURE, THIS EFFORT TO ENABLE ALWAYS ENCRYPTED IN SQL SERVER IN I’M SORRY IN AZURE SKL DATABASE IS PART OF BROADER EFFORT. THEY WERE AT IGNITE THEY THEY WERE A COUPLE A NUMBER OF TALKS I THINK THERE IS PRESENTATION. UNFORTUNATELY HAPPENING AT THIS TIME AS WELL. AND BUT YOU CAN GET THE RECORDING OF THE EARLIER SESSION FROM ACC TEAM. WHAT IS THIS ABOUT? AZURE CONFIDENTIAL COMPUTING WILL BRING TO AZURE CUSTOMERS A FEW COMPONENTS FIRST OF ALL, WE ARE BRINGING SGX EQUIPPED MACHINES TO OUR DATA CENTERS. WE WILL GIVE YOU AN ABILITY TO PROVISION VIRTUAL MACHINE THAT IS RUN ON THIS HARDWARE. AND WE WORKING ON ATTESTATION SERVICE FOR SGX ENCLAVES IN AZURE. IN ADDITION, ON THE IN THE TOP TIER ON THE SCREEN YOU WILL GET AN SDK FROM MICROSOFT CALLED OPEN ENCLAVE SDK SO THAUK ADEVELOP YOUR OWN APPLICATIONS TAKING TAKING ADVANTAGE OF ENCLAVE TECHNOLOGY. IN ADDITION TO THAT, YOU WILL SEE MORE AND MORE MICROSOFT SURFACES AND PRODUCTS INCLUDING SERVICES THAT USE ENCLAVE TECHNOLOGIES TO PROTECT DATA IN USE OR MAYBE TO PROTECT INTELLECTUAL PROPERTY OF CODE. THAT YOU DEPLOY TO AZURE. AZURE SQL DATABASE. WE HAVE SOME SIMILAR EFFORTS IN THE BLOCK CHAIN SPACE AND MULTI PARTY XU TRAGSS AND MACHINE LEARNING. IN ADDITION TO THAT, WE INVEST A LOT OF EFFORT IN IDENTIFYING AND POTENTIAL VULNERABILITIES IN ENCLAVE PLATFORM. AND ADDRESSING THESE ISSUES PROACTIVELY AS SOON AS WE CAN. OKAY. IN CLOSING, I’D LIKE TO ENCOURAGE YOU TO TRY IT. TO REALLY TRY TO DEPLOY, TRY ALWAYS ENCRYPT WITH SECURE ENCLAVES PUBLISHED EARLY THIS WEEK I HAVE BLOG AND I’M GOING TO PUBLISH REGULARLY ARTICLES ON THE INTERESTING ASPECTS OF ALWAYS ENCRYPTED WITH ENCLAVES. MAIN ASK IF SOMETHING THAT APPLICABLE TO YOUR SCENARIOS SOMETHING YOUR ORGANIZATIONS CAN BENEFIT FROM WE WOULD LOVE TO HEAR FROM YOU DIRECTLY. WE WOULD LOVE TO ENGAGE WITH YOU PLCS EVALUATION PROJECTS, HELP YOU GET GOING WITH THIS FEATURE AND LEARN FROM YOU. RIGHT. SO I THINK THE ONE MAIN TAKE AWAYS MAIN TAKE AWAY FROM THIS PRESENTATION FROM THIS SESSION IS THAT THIS IS VERY CHALLENGING AREA. RIGHT? A VERY CHALLENGING PROBLEM TO SOLVE. BUT WE ARE, WE BELIEVE WE WE ARE ON RIGHT PATH TO SOLVE IT WE NEED YOUR HELP. WE NEED TO LEARN ABOUT YOUR SCENARIOS GET YOUR FEEDBACK TO MAKE SURE WE SHIP IN NEXT MILESTONE WHICH SQL SERVER 2019 AND SUBSEQUENT MONTHS MEETING REQUIREMENTS THAT IS SOMETHING THAT WILL BENEFIT YOU AND YOUR SCENARIOS. ANY QUESTIONS? OKAY. WE’LL STAY AFTER THE SESSION. WE’LL BE ALSO ON THE SQL BOARD IF YOU HAVE ANY FOLLOW-UP QUESTIONS. THANKS FOR LISTENING EVERYONE.

No Comments

Leave a Comment

Your email address will not be published. Required fields are marked *