Skip to content

Commit

Permalink
fix: old_version in mobile connection (#722)
Browse files Browse the repository at this point in the history
* mobile version

* mobile version

* mobile version
  • Loading branch information
DavidsonGomes authored Apr 28, 2024
1 parent 111601b commit 495bb67
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Defaults/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const PHONE_CONNECTION_CB = 'CB:Pong'

export const WA_DEFAULT_EPHEMERAL = 7 * 24 * 60 * 60

const WA_VERSION = '2.23.14.82'
const WA_VERSION = '2.24.6.77'

const WA_VERSION_HASH = createHash('md5').update(WA_VERSION).digest('hex')
export const MOBILE_TOKEN = Buffer.from('0a1mLfGUIBVrMKF1RdvLI5lkRBvof6vn0fD2QRSM' + WA_VERSION_HASH)
Expand Down
2 changes: 1 addition & 1 deletion src/Utils/validate-connection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { createSignalIdentity } from './signal'

const getUserAgent = (config: SocketConfig): proto.ClientPayload.IUserAgent => {
const osVersion = config.mobile ? '15.3.1' : '0.1'
const version = config.mobile ? [2, 22, 24] : config.version
const version = config.mobile ? [2, 24, 6] : config.version
const device = config.mobile ? 'iPhone_7' : 'Desktop'
const manufacturer = config.mobile ? 'Apple' : ''
const platform = config.mobile ? proto.ClientPayload.UserAgent.Platform.IOS : proto.ClientPayload.UserAgent.Platform.WEB
Expand Down

0 comments on commit 495bb67

Please sign in to comment.