Skip to content
  • Damien Ramelet's avatar
    [bforbank] Change regex in order to correctly recover url value · fba22b3e
    Damien Ramelet authored and hydrargyrum's avatar hydrargyrum committed
    On BforBank website, when an user has several accounts, there is a
    dropdown with all accounts available. The module iterate over this
    dropdown and recover the value attribute of each <option> in order to build the
    url that lead to saids accounts.
    
    The previous regex that extract the value attribute was like this:
    
    r'[^\d]' which allow to extract this value 123456789 and lead to build
    this kind of url :
    
    BASE_URL/espace-client/rib/123456789
    
    This now lead to a 500 error and a lookalike unavailable/maintenance page.
    
    The value attribute has obviously changed, and now look like this :
    
    COMPTE_TITRE/yLsl6hUcNO_FbC7i9i0fUkFdESgVzGF2nwVuHfQhs08=
    
    PEA/Alql9hUcDO_FbL4i9i4fUoPdJSgQzHF2nwVuHfQhs08=
    
    etc...
    
    r'/(.+)' allow to extract the value following the slash and build
    this kind of url:
    
    BASE_URL/espace-client/rib/wk4C9nIlhkw8-DGPATODM4QuZgPTf5-RQb1ftWHpoqA=
    fba22b3e