code: public static byte[] getLMv2Response(String domain, String user,
              String password, byte[] challenge, byte[] clientChallenge) {
          try {
              byte[] hash = new byte[16];
              byte[] response = new byte[24];
  // The next 2-1/2 lines of this should be placed with nTOWFv1 in place of password
              MD4 md4 = new MD4();
              md4.update(password.getBytes(SmbConstants.UNI_ENCODING));
              HMACT64 hmac = new HMACT64(md4.digest());
              hmac.update(user.toUpperCase().getBytes(SmbConstants.UNI_ENCODING));
              hmac.update(domain.toUpperCase().getBytes(SmbConstants.UNI_ENCODING));
              hmac = new HMACT64(hmac.digest());
              hmac.update(challenge);
              hmac.update(clientChallenge);
              hmac.digest(response, 0, 16);
              System.arraycopy(clientChallenge, 0, response, 16, 8);
              return response;
          } catch (Exception ex) {
              if( log.level > 0 )
                  ex.printStackTrace( log );
              return null;
          }
      }
docs: Creates the LMv2 response for the supplied information.
  
  @param domain The domain in which the username exists.
  @param user The username.
  @param password The user's password.
  @param challenge The server challenge.
  @param clientChallenge The client challenge (nonce).