Slide 1

Slide 1 text

Through  Personaliza0on  and  Data  Mining   Exploring  Human  Iden0ty   Jonathan  LeBlanc   Developer  Evangelist:  X.commerce   Twi;er:  @jcleblanc   E-­‐Mail:  [email protected]   Github:  github.com/jcleblanc  

Slide 2

Slide 2 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   The  FoundaGons  of  Human  IdenGty   Tribalism  and  Social  Grouping   Experimental  IdenGty  Methods   The  Big  Bag  of  Social  IdenGty  Fail   What  We’re  Going  to  Cover  

Slide 3

Slide 3 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   The  Founda0ons  of  Human  Iden0ty   Tribalism  and  Social  Grouping   Experimental  IdenGty  Methods   The  Big  Bag  of  Social  IdenGty  Fail   What  We’re  Going  to  Cover  

Slide 4

Slide 4 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Human  Iden0ty:  User  Types   Anonymous  Users   Real  IdenGty  Login  

Slide 5

Slide 5 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   OAuth  (1.0a  +  2.0)   PayPal  Access,  Facebook,  Twi;er     OpenID  (…and  the  upcoming  OpenID  Connect)   PayPal  Access,  Google,  Yahoo!     BrowserID   Mozilla   Human  Iden0ty:  Open  Iden0ty  Programming  

Slide 6

Slide 6 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Human  Iden0ty:  Anonymous  Users  

Slide 7

Slide 7 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   There  are  a  few  common  op0ons   Human  Iden0ty:  Tracking  Anonymous  Users   Tracking  Cookie   Local  Storage  

Slide 8

Slide 8 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   •  On  each  page  visited,  track  the  URL   •  HTML5  Local  Storage  as  primary  storage   •  Cookies  as  secondary  storage   Human  Iden0ty:  Tracking  Anonymous  Users   Program  Overview  

Slide 9

Slide 9 text

Tracking  Anonymous  Users  with  Local  Storage   var  storeName  =  "visited";   if  (typeof(localStorage)  ==  'undefined'  )  {          //Local  Storage  Not  Available   }  else  {          try  {                  var  sites  =  localStorage.getItem(storeName);                  sites  =  (sites  ===  null)  ?  window.loca0on  :  sites  +  window.loca0on;                    localStorage.setItem(storeName,  sites  +  "|");            }  catch  (e)  {                  if  (e  ==  QUOTA_EXCEEDED_ERR)  {                          //quota  exceeded                  }          }   }  

Slide 10

Slide 10 text

Tracking  Anonymous  Users  with  Cookies   func0on  readCookie(name)  {          var  nameEQ  =  name  +  "=";          var  ca  =  document.cookie.split(';');          for  (var  i  =  0;  i  <  ca.length;  i++)  {                  var  c  =  ca[i];                  while  (c.charAt(0)  ==  '  '){  c  =  c.substring(1,  c.length)  };                  if  (c.indexOf(nameEQ)  ==  0){                            return  c.substring(nameEQ.length,  c.length);                    }          }          return  null;   }  

Slide 11

Slide 11 text

var  storeName  =  "visited";   if  (typeof(localStorage)  ==  "undefined"  )  {          var  cookieVal  =  readCookie(storeName);          var  value  =  ((cookieVal  ===  null)  ?  window.locaGon  :  cookieVal                                                  +  window.locaGon);                      var  days  =  1;          var  date  =  new  Date();          date.setTime(date.getTime()  +  (days*24*60*60*1000));          var  expires  =  ";  expires="  +  date.toGMTString();          document.cookie  =  storeName  +  "="  +  value  +  "|"                                                                            +  expires  +  ";  path=/";   }  else  {          //Use  Local  Storage   }   Tracking  Anonymous  Users  with  Cookies  

Slide 12

Slide 12 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   •  Remove  oldest  results  when  storage  fills   •  Build  categorizaGon  mapping  prior  to   storage  to  save  space  (more  on  this  later)   Human  Iden0ty:  Tracking  Anonymous  Users   Next  Steps  /  Improvements  

Slide 13

Slide 13 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Human  Iden0ty:  Real  Iden0ty  Users  

Slide 14

Slide 14 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Human  Iden0ty:  Real  Iden0ty  Sources   Social  (perceived)   Concrete  (true)       Sources  of  Real  Iden0ty  

Slide 15

Slide 15 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Human  Iden0ty:  Concrete  Iden0ty  

Slide 16

Slide 16 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   PayPal  Access:  OAuth  2  +  Commerce     Seamless  Checkout   Prospect  Scores   RecommendaGons  

Slide 17

Slide 17 text

PayPal  Access:  The  Common  Code      

Slide 18

Slide 18 text

PayPal  Access:  Forwarding  for  Login      

Slide 19

Slide 19 text

PayPal  Access:  Obtaining  the  Access  Token  

Slide 20

Slide 20 text

PayPal  Access:  Using  the  Access  Token   //construct  URI  to  fetch  profile  informaGon  for  current  user   $profile_url  =  sprinb("%s?oauth_token=%s",   PROFILE_ENDPOINT,  $token-­‐>access_token);     //fetch  profile  of  current  user   $profile  =  run_curl($profile_url);     var_dump($profile);   ?>    

Slide 21

Slide 21 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   PayPal  Access:  Using  the  Raw  Data  

Slide 22

Slide 22 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   PayPal  Access:  Using  the  Raw  Data  

Slide 23

Slide 23 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   The  FoundaGons  of  Human  IdenGty   Tribalism  and  Social  Grouping   Experimental  IdenGty  Methods   The  Big  Bag  of  Social  IdenGty  Fail   What  We’re  Going  to  Cover  

Slide 24

Slide 24 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  It’s  Not  A  New  Thing…  

Slide 25

Slide 25 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Tribalism  started  as  a  way  to  keep  us  safe     …it  has  lead  to  some  horrible  parts  of  history     but  it  is  also  a  foundaGon  of  many  of  our  social   relaGonships       Social  Grouping:  Founda0on  in  Tribalism  

Slide 26

Slide 26 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  The  Real  Life  Social  Graph  

Slide 27

Slide 27 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  The  Online  Social  Graph  

Slide 28

Slide 28 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  Group  Types   Follower  Type   ConnecGon  Type   Group  Type  

Slide 29

Slide 29 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  Data  Miners  are  Rock  Stars  

Slide 30

Slide 30 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   •  Use  all  URLs  from  the  previous  program.   •  Obtain  content  category  for  page.   •  Categorize  user  interest.     Social  Grouping:  Group  Programming  Primer   Program  Overview  

Slide 31

Slide 31 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  Group  Programming  Primer   Step  1:  Obtain   Website  Content  

Slide 32

Slide 32 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  Group  Programming  Primer   Step  2:  Perform   Keyword  Density   Search  

Slide 33

Slide 33 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Social  Grouping:  Group  Programming  Primer   Step  3:  Weight   Keywords  

Slide 34

Slide 34 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   The  FoundaGons  of  Human  IdenGty   Tribalism  and  Social  Grouping   Experimental  Iden0ty  Methods   The  Big  Bag  of  Social  IdenGty  Fail   What  We’re  Going  to  Cover  

Slide 35

Slide 35 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Experimental  Iden0ty:  WebFinger  

Slide 36

Slide 36 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Step  1:  Perform  Discovery     curl  h;ps://gmail.com/.well-­‐known/host-­‐meta       Experimental  Iden0ty:  WebFinger  

Slide 37

Slide 37 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Experimental  Iden0ty:  WebFinger            gmail.com                                      Resource  Descriptor              

Slide 38

Slide 38 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Step  2:  Collect  User  Data     curl  h;p://www.google.com/s2/webfinger/? [email protected]       Experimental  Iden0ty:  WebFinger  

Slide 39

Slide 39 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   User  Profile   h;p://www.google.com/profiles/nakedtechnologist   Portable  Contacts   h;p://www-­‐opensocial.googleusercontent.com/api/ people/118167121283215553793/   Experimental  Iden0ty:  WebFinger  

Slide 40

Slide 40 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   profileUrl   id   thumbnail  url   urls   photos   Experimental  Iden0ty:  WebFinger   name        forma;ed        family  name        given  name        display  name    

Slide 41

Slide 41 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Experimental  Iden0ty:  BrowserID    

Slide 42

Slide 42 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   BrowserID  Source       JQuery  Source     Experimental  Iden0ty:  BrowserID    

Slide 43

Slide 43 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   Experimental  Iden0ty:  BrowserID     navigator.id.get(func0on(asserGon)  {          if  (asserGon)  {                  $.ajax({                          url:  'h;ps://browserid.org/verify',                          type:  'POST',                          data:  'asserGon='+asserGon+'&audience=jcleblanc.com',                          success:  func0on(res)  {                                  console.log(res);                          }                  });   });  

Slide 44

Slide 44 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   {          audience:  "jcleblanc.com",          email:  "[email protected]",          expires:  1320081400987,          issuer:  "browserid.org",          status:  "okay"   }   Experimental  Iden0ty:  BrowserID  Results  

Slide 45

Slide 45 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   The  FoundaGons  of  Human  IdenGty   Tribalism  and  Social  Grouping   Experimental  IdenGty  Methods   The  Big  Bag  of  Social  Iden0ty  Fail   What  We’re  Going  to  Cover  

Slide 46

Slide 46 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc       “My  privacy  concerns  are  not  trite.   They  are  linked  to  my  actual   physical  safety”       -­‐-­‐Harriet  Jacobs  (Gizmodo)   Social  Iden0ty  Fail:  Personal  Safety   When  Social  Discovery  Impacts  Personal  Safety  

Slide 47

Slide 47 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc       “Path  Uploads  Your  EnGre  iPhone   Contact  List  By  Default”       -­‐-­‐Mark  Hachman  (PCMag)   Social  Iden0ty  Fail:  Privacy  Concerns   When  Making  Things  Easy  Impairs  Privacy  

Slide 48

Slide 48 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc       “How  Target  Figured  Out  A  Teen  Girl   Was  Pregnant  Before  Her  Father  Did”       -­‐-­‐Kashmir  Hill  (Forbes)   Social  Iden0ty  Fail:  The  Fine  Line   The  Fine  Line  Between  Insighbul  and  Creepy  

Slide 49

Slide 49 text

h;p://www.x.com   h;p://slideshare.net/jcleblanc   IdenGty  is  more  than  just  a  login     AuthenGcaGon  is  just  the  first  step     Find  the  tool  that:   – Has  the  raw  data  that  you  need   – Works  with  your  business   Iden0ty  Programming  Core  Concepts  

Slide 50

Slide 50 text

hgp://slidesha.re/convergese_id   Thanks!  Any  Ques0ons?   Jonathan  LeBlanc   Developer  Evangelist:  X.commerce   Twi;er:  @jcleblanc   E-­‐Mail:  [email protected]   Github:  github.com/jcleblanc