@dotrino/vaultd 0.195.0 → 0.195.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -449,6 +449,10 @@ dispositivos/variables que estás viendo:
449
449
  valores), **agregar** una variable (con su scope) y **quitar** una variable o un
450
450
  scope entero. Son las **compartidas**: las de UN aparato se ponen en la otra
451
451
  pestaña, y esta lo dice en vez de repetirlas.
452
+ - **Contraseñas:** buscar (`Enter` o `f`, y parte del sitio, del título o del usuario:
453
+ `npm` encuentra `www.npmjs.com`) si hay una contraseña o passkey guardada, con su usuario, y qué aparatos la abren o todavía
454
+ no. Solo mira: no enseña la contraseña ni cambia nada. Pide la bóveda abierta. Lo
455
+ mismo en la CLI: `dotrino-vault passwords find <texto>`.
452
456
 
453
457
  Y dentro de **Dispositivos**, con `e` sobre un servicio, sus **variables propias**:
454
458
  las que lee solo él y le ganan a las del scope que se llamen igual. Cada cajón se
@@ -5,4 +5,4 @@
5
5
  * si no coincide con la del paquete: una versión anunciada que no es la que corre es peor
6
6
  * que no anunciar ninguna.
7
7
  */
8
- export const LIB_VERSION = '0.122.0'
8
+ export const LIB_VERSION = '0.122.1'
@@ -204,18 +204,27 @@ export async function importPasswordEntries ({ sealed, openRecovery, recipients,
204
204
  }
205
205
 
206
206
  /**
207
- * ¿QUÉ HAY GUARDADO PARA ESTE SITIO, Y QUIÉN LO ABRE? (`dotrino-vault passwords find`).
207
+ * ¿QUÉ HAY GUARDADO PARA ESTO, Y QUIÉN LO ABRE? (`dotrino-vault passwords find`).
208
208
  *
209
- * **Solo lee**: ni reenvuelve ni escribe. La huella del sitio sale de la llave del perfil, que
210
- * se abre con la copia de recuperación (`openRecovery`, bóveda abierta), y con ella se pide al
211
- * almacén `inspect`. De cada entrada se abre su VISTA —título, usuario, sitios—, nunca un valor.
209
+ * **Solo lee**: ni reenvuelve ni escribe. La llave del perfil se abre con la copia de
210
+ * recuperación (`openRecovery`, bóveda abierta). De cada entrada se abre su VISTA —título,
211
+ * usuario, sitios—, nunca un valor.
212
+ *
213
+ * La búsqueda es PARCIAL: `npm` encuentra `www.npmjs.com`, y también por título o usuario.
214
+ * Con huellas sola no se puede (una huella solo casa con el texto exacto), así que se abren
215
+ * las vistas y se compara el texto. Y se suman las huellas del sitio, para que una URL
216
+ * (`login.empresa.com/x`) siga encontrando lo guardado para su dominio (`empresa.com`).
212
217
  *
213
218
  * Devuelve las públicas tal cual (`by`, `holders`, `missing`): ponerles nombre es de quien
214
219
  * tiene el acta.
215
220
  */
216
221
  export async function findPasswordEntries ({ sealed, openRecovery, query }) {
217
222
  const { hostOf } = await import('@dotrino/passmanager/match')
218
- if (!hostOf(String(query || ''))) throw Object.assign(new Error('that is not a site: give a domain or a URL'), { code: 'BAD_SITE' })
223
+ const q = String(query || '').trim()
224
+ if (!q) throw Object.assign(new Error('nothing to search: give part of a site, a title or a user'), { code: 'EMPTY_QUERY' })
225
+ // Una URL se compara por su host: nadie guarda `https://` ni la ruta.
226
+ const host = hostOf(q)
227
+ const needle = (q.includes('://') && host ? host : q).toLowerCase()
219
228
  const stats = await sealed.stats()
220
229
  if (!stats.sealed) return { sealed: false, entries: stats.entries, found: [] }
221
230
  const { RECOVERY, profileKeys, siteHashes, passkeyRpHashes, openSealedView } = await import('@dotrino/passmanager/sealed')
@@ -227,16 +236,22 @@ export async function findPasswordEntries ({ sealed, openRecovery, query }) {
227
236
  }
228
237
  const openSealed = async ({ wrap, envelope }) => decryptWithCek({ cek: await openRecovery(wrap), envelope })
229
238
  const keys = await profileKeys(await openSealed({ wrap: prof.wrap, envelope: prof.envelope }))
230
- const hits = await sealed.inspect({ idx: await siteHashes(keys.kidx, query), rp: await passkeyRpHashes(keys.kidx, query) })
239
+ const hits = await sealed.inspect({
240
+ all: true,
241
+ idx: host ? await siteHashes(keys.kidx, q) : [],
242
+ rp: host ? await passkeyRpHashes(keys.kidx, q) : []
243
+ })
231
244
  const found = []
232
245
  for (const h of hits) {
233
246
  let view = null
234
247
  if (h.recoveryWrap) {
235
248
  const v = await openSealedView({ view: h.view, wrap: h.recoveryWrap, id: h.id, openSealed })
236
- view = { title: v.title || '', user: v.hint || '', sites: v.sites || [], rpId: v.webauthn?.rpId || null, hasSecret: !!v.has?.secret, hasTotp: !!v.has?.totp }
249
+ view = { title: v.title || '', user: v.hint || '', sites: v.sites || [], rpId: v.webauthn?.rpId || null, hasSecret: !!v.hasSecret, hasTotp: !!v.hasTotp }
237
250
  }
251
+ const text = view ? [view.title, view.user, view.rpId || '', ...view.sites].join('\n').toLowerCase() : ''
252
+ if (!h.match && !text.includes(needle)) continue
238
253
  const { view: _sealedView, recoveryWrap: _w, ...meta } = h
239
- found.push({ ...meta, view })
254
+ found.push({ ...meta, match: h.match || 'text', view })
240
255
  }
241
256
  return { sealed: true, entries: stats.entries, found }
242
257
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dotrino/vaultd",
3
- "version": "0.195.0",
3
+ "version": "0.195.2",
4
4
  "type": "module",
5
5
  "description": "Certificador personal de Dotrino: daemon headless que custodia la clave maestra y delega capacidades a tus dispositivos por el proxy. Tu CA propia.",
6
6
  "bin": {
@@ -24,7 +24,7 @@
24
24
  "@dotrino/compat": "0.5.0",
25
25
  "@dotrino/identity": "0.139.0",
26
26
  "@dotrino/opaque": "0.1.0",
27
- "@dotrino/passmanager": "0.19.0",
27
+ "@dotrino/passmanager": "0.19.1",
28
28
  "@dotrino/proxy-client": "^0.47.0",
29
29
  "@dotrino/roadmap": "0.4.89",
30
30
  "@dotrino/store": "0.13.0",
package/src/ctl.js CHANGED
@@ -2611,9 +2611,9 @@ function help () {
2611
2611
  privada, y una privada NO se vuelve pública.
2612
2612
  secret visibility <ns> <CLAVE> private tapa una pública sin tocar el valor
2613
2613
  secret device visibility <ID> <CLAVE> private
2614
- passwords find <dominio>
2615
- si hay contraseña o passkey para ese sitio (y sus subdominios),
2616
- con su usuario, y qué aparatos la abren o todavía no. No enseña
2614
+ passwords find <texto>
2615
+ busca por parte del sitio, del título o del usuario (npm
2616
+ encuentra www.npmjs.com) y dice qué hay, con su usuario, y qué aparatos la abren o todavía no. No enseña
2617
2617
  la contraseña ni cambia nada. Bóveda abierta
2618
2618
  backup list qué cajones hay para respaldar (nombres y cuántos valores)
2619
2619
  backup export [cajón…] [-o archivo]
@@ -2790,18 +2790,20 @@ async function cmdReplica (args) {
2790
2790
  }
2791
2791
 
2792
2792
  /**
2793
- * `dotrino-vault passwords find <dominio>`: ¿hay contraseña o passkey para ese sitio, y la
2794
- * pueden abrir todos los aparatos con `passwords`? Solo lee: no cambia nada del almacén.
2793
+ * `dotrino-vault passwords find <texto>`: ¿hay contraseña o passkey que coincida (parte del
2794
+ * sitio, del título o del usuario), y la pueden abrir todos los aparatos con `passwords`? Solo lee: no cambia nada del almacén.
2795
2795
  * Enseña título, usuario y sitios; nunca un valor.
2796
2796
  */
2797
2797
  async function cmdPasswords (rest) {
2798
- const [sub, query] = rest
2798
+ const [sub, ...words] = rest
2799
+ const query = words.join(' ').trim()
2799
2800
  if (sub !== 'find' || !query) {
2800
- console.error('uso: dotrino-vault passwords find <dominio o URL>')
2801
+ console.error('uso: dotrino-vault passwords find <parte del sitio, del título o del usuario>')
2801
2802
  process.exit(2)
2802
2803
  }
2803
- const r = await backupRequest({ op: 'passwords-find', query }).catch((e) => {
2804
- if (e.code === 'BAD_SITE') { console.error('«%s» no es un sitio: escribe un dominio (ejemplo.com) o una URL.', query); process.exit(2) }
2804
+ requireDaemon()
2805
+ const r = await vc.passwordsFind(query, PROFILE || undefined).catch((e) => {
2806
+ if (e.code === 'EMPTY_QUERY') { console.error('Escribe algo que buscar: parte del sitio, del título o del usuario.'); process.exit(2) }
2805
2807
  if (e.code === 'NO_RECOVERY') { console.error('La llave de las contraseñas todavía no tiene la copia de la frase. Abre la bóveda (dotrino-vault unlock) para que la reciba.'); process.exit(1) }
2806
2808
  return backupFail(e)
2807
2809
  })
@@ -2810,8 +2812,8 @@ async function cmdPasswords (rest) {
2810
2812
  return
2811
2813
  }
2812
2814
  if (!r.found.length) {
2813
- console.log('\nNo hay nada guardado para %s%s%s (%d entrada(s) en total).\n', B, query, Z, r.entries)
2814
- console.log('Se busca por el dominio y sus padres: login.ejemplo.com encuentra lo guardado para ejemplo.com.\n')
2815
+ console.log('\nNada coincide con %s%s%s (%d entrada(s) en total).\n', B, query, Z, r.entries)
2816
+ console.log('Se busca un trozo del sitio, el título o el usuario: npm encuentra www.npmjs.com.\n')
2815
2817
  return
2816
2818
  }
2817
2819
  const name = (d) => d ? `${d.id}${d.label ? ' ' + d.label : ''}` : '?'
package/src/tui/app.js CHANGED
@@ -1406,15 +1406,6 @@ async function onKeyProfiles (term, st, key) {
1406
1406
  }
1407
1407
  await openBackup(term, st)
1408
1408
  })
1409
- } else if (ch === 'f' && cur) { // buscar una contraseña por sitio, con la bóveda abierta
1410
- await ensureUnlocked(term, st, cur, async (p = cur) => {
1411
- if (!p.current) {
1412
- const r = await guard(term, st, i.switchingVault, () => vc.useProfile(p.id))
1413
- if (!r.ok) return
1414
- await refreshAll(term, st)
1415
- }
1416
- askPwFind(term, st)
1417
- })
1418
1409
  } else if (ch === 'y' && cur) { // las llaves: con qué se abre la bóveda
1419
1410
  await ensureUnlocked(term, st, cur, async (p = cur) => {
1420
1411
  st.doorsFor = p.id
@@ -2603,7 +2594,10 @@ function backupPlanRows (st, t) {
2603
2594
  */
2604
2595
  function askPwFind (term, st) {
2605
2596
  const i = L(st)
2606
- setInput(st, {
2597
+ const p = activeProfile(st)
2598
+ if (!p) return
2599
+ // La huella del sitio sale de la llave del perfil, que solo abre la frase: bóveda abierta.
2600
+ return ensureUnlocked(term, st, p, () => setInput(st, {
2607
2601
  label: i.pwFindLabel,
2608
2602
  hint: i.pwFindHint,
2609
2603
  onSubmit: async (q) => {
@@ -2616,23 +2610,29 @@ function askPwFind (term, st) {
2616
2610
  const result = await vc.passwordsFind(query, activeId(st))
2617
2611
  st.busy = null
2618
2612
  st.pwFind = { query, result }
2619
- st.sel.pwfind = 0
2620
- st.scroll.pwfind = { value: 0 }
2621
- st.screen = 'pwfind'
2613
+ st.sel.passwords = 0
2614
+ st.scroll.passwords = { value: 0 }
2622
2615
  } catch (e) {
2623
2616
  st.busy = null
2624
- const msg = e?.code === 'BAD_SITE' ? i.pwFindBadSite : e?.code === 'NO_RECOVERY' ? i.pwFindNoRecovery : backupErr(e, st)
2617
+ const msg = e?.code === 'EMPTY_QUERY' ? i.pwFindEmptyQuery : e?.code === 'NO_RECOVERY' ? i.pwFindNoRecovery : backupErr(e, st)
2625
2618
  flash(st, msg, 'danger')
2626
2619
  }
2627
2620
  },
2628
2621
  onCancel: () => { st.input = null }
2629
- })
2622
+ }))
2630
2623
  }
2631
2624
 
2632
2625
  function pwFindRows (st, t) {
2633
2626
  const i = L(st)
2634
2627
  const f = st.pwFind
2635
- if (!f) return []
2628
+ if (!f) {
2629
+ return [
2630
+ { text: ' ' + t.bold(i.pwFindIntro), sel: false },
2631
+ { text: '', sel: false },
2632
+ { text: ' ' + t.muted(i.pwFindIntroHow), sel: false },
2633
+ { text: ' ' + t.muted(i.pwFindIntroSafe), sel: false }
2634
+ ]
2635
+ }
2636
2636
  const r = f.result
2637
2637
  const rows = [{ text: ' ' + t.bold(i.pwFindFor(f.query)), sel: false }, { text: '', sel: false }]
2638
2638
  if (!r.sealed) { rows.push({ text: ' ' + t.muted(r.entries ? i.pwFindOld : i.pwFindEmpty), sel: false }); return rows }
@@ -2663,12 +2663,11 @@ function pwFindRows (st, t) {
2663
2663
 
2664
2664
  async function onKeyPwFind (term, st, key) {
2665
2665
  const ch = key.name === 'char' ? key.ch.toLowerCase() : null
2666
- if (key.name === 'escape' || ch === 'b' || !st.pwFind) { st.screen = 'profiles'; st.pwFind = null; return true }
2667
2666
  if (['up', 'down', 'pageup', 'pagedown', 'home', 'end'].includes(key.name)) {
2668
- moveSel(st, key, 'pwfind', pwFindRows(st, makeTheme()).filter((r) => r.sel).length)
2667
+ moveSel(st, key, 'passwords', pwFindRows(st, makeTheme()).filter((r) => r.sel).length)
2669
2668
  return true
2670
2669
  }
2671
- if (ch === 'f') { askPwFind(term, st); return true }
2670
+ if (ch === 'f' || key.name === 'enter') { await askPwFind(term, st); return true }
2672
2671
  return true
2673
2672
  }
2674
2673
 
@@ -2874,8 +2873,8 @@ async function onKeyBackupPlan (term, st, key) {
2874
2873
 
2875
2874
  // Pestañas INTERNAS de una bóveda ya elegida: se cambian con ←→. La lista de
2876
2875
  // bóvedas (profiles) es el nivel de arriba (se entra con Enter, no es una pestaña).
2877
- const INNER_TABS = ['devices', 'secrets', 'logins', 'me']
2878
- const tabLabel = (i, k) => ({ devices: i.tabDevices, secrets: i.tabSecrets, logins: i.tabLogins, me: i.tabMe })[k]
2876
+ const INNER_TABS = ['devices', 'secrets', 'passwords', 'logins', 'me']
2877
+ const tabLabel = (i, k) => ({ devices: i.tabDevices, secrets: i.tabSecrets, passwords: i.tabPasswords, logins: i.tabLogins, me: i.tabMe })[k]
2879
2878
 
2880
2879
  /**
2881
2880
  * Las teclas que se pueden usar AHORA, no el catálogo entero. Aprobar/rechazar sin nadie
@@ -2899,7 +2898,7 @@ const helpSegs = (i, screen, st = {}) => {
2899
2898
  devvars: i.helpDevVars,
2900
2899
  backup: i.helpBackup,
2901
2900
  backupplan: i.helpBackupPlan,
2902
- pwfind: i.helpPwFind
2901
+ passwords: i.helpPwFind
2903
2902
  }[screen] || []
2904
2903
  if (typeof segs !== 'function') return segs
2905
2904
  // El aparato señalado ahora mismo: `e variables` solo tiene sentido en un servicio (es
@@ -2937,18 +2936,25 @@ const title = (i, screen) => ({
2937
2936
  devvars: i.titleDevVars,
2938
2937
  backup: i.titleBackup,
2939
2938
  backupplan: i.titleBackupPlan,
2940
- pwfind: i.titlePwFind
2939
+ passwords: i.titlePwFind
2941
2940
  })[screen] || ''
2942
2941
 
2943
2942
  /** Barra de pestañas horizontal (Dispositivos | Scopes y variables) de la bóveda entrada. */
2944
- function renderTabs (st, t) {
2943
+ function renderTabs (st, t, cols = Infinity) {
2945
2944
  const i = L(st)
2946
- return INNER_TABS.map((k) => {
2945
+ // UN espacio entre pestañas, no tres. Y si aun así no cabe (con cinco pestañas, en 80
2946
+ // columnas), se aprieta: primero el relleno de las inactivas y al final un `│` entre ellas
2947
+ // en vez de espacios. Lo que no se puede perder es la pista de que se puede cambiar.
2948
+ const bar = (pad, sep, hint) => INNER_TABS.map((k) => {
2947
2949
  const active = st.screen === k
2948
- return active ? t.bold(t.accent('▐ ' + tabLabel(i, k) + ' ▌')) : t.muted(' ' + tabLabel(i, k) + ' ')
2949
- // UN espacio entre pestañas, no tres: con cuatro ya no cabía el «(←→ cambiar)» en 80
2950
- // columnas, y lo que se perdía era justamente la pista de que se puede cambiar.
2951
- }).join(' ') + t.muted(i.tabsHint)
2950
+ return active ? t.bold(t.accent('▐ ' + tabLabel(i, k) + ' ▌')) : t.muted(pad + tabLabel(i, k) + pad)
2951
+ }).join(sep) + t.muted(hint)
2952
+ const tries = [[' ', ' ', i.tabsHint], [' ', ' ', i.tabsHint], ['', t.muted('│'), i.tabsHint]]
2953
+ for (const [pad, sep, hint] of tries) {
2954
+ const out = bar(pad, sep, hint)
2955
+ if (widthOf(out) + 2 <= cols) return out
2956
+ }
2957
+ return bar('', t.muted('│'), i.tabsHint)
2952
2958
  }
2953
2959
 
2954
2960
  function pairingBody (st, t, cols, height, { qr: withQr = true } = {}) {
@@ -3057,7 +3063,7 @@ function render (term, st) {
3057
3063
  if (!lines[2] && st.update?.release) lines[2] = ' ' + t.warn(i.updateAvailable(st.update.release.version))
3058
3064
  // Dispositivos/Scopes son pestañas de la bóveda activa (se entra desde Bóvedas);
3059
3065
  // el resto muestra su título simple.
3060
- lines[3] = INNER_TABS.includes(st.screen) ? ' ' + renderTabs(st, t) : ' ' + t.title('» ' + title(i, st.screen))
3066
+ lines[3] = INNER_TABS.includes(st.screen) ? ' ' + renderTabs(st, t, cols) : ' ' + t.title('» ' + title(i, st.screen))
3061
3067
  lines[4] = ''
3062
3068
 
3063
3069
  const help = helpLines(st, i, cols, rows)
@@ -3079,7 +3085,7 @@ function render (term, st) {
3079
3085
  else if (st.screen === 'paircaps') body = renderList(pairCapsRows(st, t), st.sel.paircaps || 0, contentH, cols, t, scrollRef)
3080
3086
  else if (st.screen === 'backup') body = renderList(backupRows(st, t), st.sel.backup || 0, contentH, cols, t, scrollRef)
3081
3087
  else if (st.screen === 'backupplan') body = renderList(backupPlanRows(st, t), st.sel.backupplan || 0, contentH, cols, t, scrollRef)
3082
- else if (st.screen === 'pwfind') body = renderList(pwFindRows(st, t), st.sel.pwfind || 0, contentH, cols, t, scrollRef)
3088
+ else if (st.screen === 'passwords') body = renderList(pwFindRows(st, t), st.sel.passwords || 0, contentH, cols, t, scrollRef)
3083
3089
  else if (st.screen === 'pairing') {
3084
3090
  const pb = pairingBody(st, t, cols, contentH)
3085
3091
  body = scrollBody(pb, contentH, scrollRef)
@@ -3125,7 +3131,7 @@ const LIST_SCREENS = {
3125
3131
  paircaps: [pairCapsRows, 'paircaps'],
3126
3132
  backup: [backupRows, 'backup'],
3127
3133
  backupplan: [backupPlanRows, 'backupplan'],
3128
- pwfind: [pwFindRows, 'pwfind']
3134
+ passwords: [pwFindRows, 'passwords']
3129
3135
  }
3130
3136
 
3131
3137
  /**
@@ -3398,7 +3404,7 @@ export async function handleKey (term, st, key) {
3398
3404
  // entrada). La pantalla de emparejamiento maneja su propio Esc (va a Dispositivos).
3399
3405
  if ((key.name === 'escape' || ch === 'b') && INNER_TABS.includes(st.screen)) {
3400
3406
  // El borrador es de ESTA bóveda: al salir de ella se guarda o se tira.
3401
- unlessDrafts(st, () => { st.capsDrafts = {}; st.cnDrafts = {}; st.screen = 'profiles' })
3407
+ unlessDrafts(st, () => { st.capsDrafts = {}; st.cnDrafts = {}; st.pwFind = null; st.screen = 'profiles' })
3402
3408
  return true
3403
3409
  }
3404
3410
 
@@ -3415,7 +3421,7 @@ export async function handleKey (term, st, key) {
3415
3421
  if (st.screen === 'paircaps') return onKeyPairCaps(term, st, key)
3416
3422
  if (st.screen === 'backup') return onKeyBackup(term, st, key)
3417
3423
  if (st.screen === 'backupplan') return onKeyBackupPlan(term, st, key)
3418
- if (st.screen === 'pwfind') return onKeyPwFind(term, st, key)
3424
+ if (st.screen === 'passwords') return onKeyPwFind(term, st, key)
3419
3425
  if (st.screen === 'pairing') return onKeyPairing(term, st, key)
3420
3426
  if (st.screen === 'join') return onKeyJoin(term, st, key)
3421
3427
  return true
package/src/tui/i18n.js CHANGED
@@ -402,18 +402,22 @@ const es = {
402
402
  // variables de UN aparato (Dispositivos → tecla e). Las del scope las comparten todos
403
403
  // los aparatos que sirven ese namespace; estas las lee solo él, y le ganan.
404
404
  titleDevVars: 'Variables del dispositivo',
405
- // BUSCAR UNA CONTRASEÑA POR SITIO (Bóvedas → tecla f). Solo lee.
405
+ // BUSCAR UNA CONTRASEÑA POR SITIO (pestaña Contraseñas de la bóveda). Solo lee.
406
406
  titlePwFind: 'Buscar contraseña',
407
- helpPwFind: ['↑↓', 'f otra búsqueda', 'Esc atrás', 'l English', 'q salir'],
408
- pwFindLabel: 'Sitio a buscar',
409
- pwFindHint: 'un dominio (ejemplo.com) o una URL',
407
+ tabPasswords: 'Contraseñas',
408
+ helpPwFind: ['←→ pestaña', 'f buscar', '↑↓', 'Esc bóvedas', 'l English', 'q salir'],
409
+ pwFindIntro: 'Buscar una contraseña o passkey',
410
+ pwFindIntroHow: 'Pulsa Enter o f y escribe parte del sitio, del título o del usuario (npm encuentra www.npmjs.com): verás qué hay guardado y qué aparatos lo tienen.',
411
+ pwFindIntroSafe: 'Solo mira: no enseña la contraseña ni cambia nada.',
412
+ pwFindLabel: 'Buscar',
413
+ pwFindHint: 'parte del sitio, del título o del usuario',
410
414
  pwFinding: 'buscando…',
411
- pwFindFor: (q) => `Lo guardado para ${q}`,
412
- pwFindNone: (q, n) => `No hay nada guardado para ${q} (${n} entrada(s) en total).`,
413
- pwFindParents: 'Se busca por el dominio y sus padres: login.ejemplo.com encuentra lo de ejemplo.com.',
415
+ pwFindFor: (q) => `Lo que coincide con «${q}»`,
416
+ pwFindNone: (q, n) => `Nada coincide con «${q}» (${n} entrada(s) en total).`,
417
+ pwFindParents: 'Se busca un trozo del sitio, el título o el usuario: npm encuentra www.npmjs.com.',
414
418
  pwFindEmpty: 'Esta bóveda todavía no tiene contraseñas guardadas.',
415
419
  pwFindOld: 'Las contraseñas están en el formato viejo: abre la bóveda para convertirlas.',
416
- pwFindBadSite: 'Eso no es un sitio: escribe un dominio (ejemplo.com) o una URL.',
420
+ pwFindEmptyQuery: 'Escribe algo que buscar: parte del sitio, del título o del usuario.',
417
421
  pwFindNoRecovery: 'La llave de las contraseñas aún no tiene la copia de la frase: abre la bóveda para que la reciba.',
418
422
  pwKindPassword: 'contraseña',
419
423
  pwKindPasskey: 'passkey',
@@ -549,7 +553,7 @@ const es = {
549
553
  // INGLÉS: new/rename/delete/password/unlock/locK/pair/approve/revoke/refresh/
550
554
  // language/quit); lo único que se traduce es la palabra que las explica.
551
555
  // Segmentos, no una línea: si no caben en una, el render los reparte en varias.
552
- helpProfiles: ['↑↓', 'Enter entrar', 'p emparejar', 'j unirse', 'n nueva', 'r renombrar', 'd borrar', 'c clave', 'x quitar-clave', 'y llaves', 'o respaldo', 'f buscar clave', 'u desbloq', 'k bloquear', 's ajustes', 'l English', 'q salir'],
556
+ helpProfiles: ['↑↓', 'Enter entrar', 'p emparejar', 'j unirse', 'n nueva', 'r renombrar', 'd borrar', 'c clave', 'x quitar-clave', 'y llaves', 'o respaldo', 'u desbloq', 'k bloquear', 's ajustes', 'l English', 'q salir'],
553
557
  // La barra dice lo que se PUEDE hacer AHORA, no todo lo que existe: aprobar/rechazar solo
554
558
  // valen si hay alguien esperando, y renombrar/revocar solo si hay un aparato seleccionado.
555
559
  // Anunciar teclas muertas confunde y además las quema para otros usos.
@@ -972,18 +976,22 @@ const en = {
972
976
 
973
977
  // variables de UN aparato (Dispositivos → tecla e)
974
978
  titleDevVars: 'Device variables',
975
- // FIND A PASSWORD BY SITE (Vaults → key f). Read-only.
979
+ // FIND A PASSWORD BY SITE (Passwords tab of the vault). Read-only.
976
980
  titlePwFind: 'Find a password',
977
- helpPwFind: ['↑↓', 'f search again', 'Esc back', 'l Español', 'q quit'],
978
- pwFindLabel: 'Site to look for',
979
- pwFindHint: 'a domain (example.com) or a URL',
981
+ tabPasswords: 'Passwords',
982
+ helpPwFind: ['←→ tab', 'f search', '↑↓', 'Esc vaults', 'l Español', 'q quit'],
983
+ pwFindIntro: 'Find a password or passkey',
984
+ pwFindIntroHow: 'Press Enter or f and type part of the site, the title or the user (npm finds www.npmjs.com): you will see what is saved and which devices have it.',
985
+ pwFindIntroSafe: 'It only looks: it does not show the password or change anything.',
986
+ pwFindLabel: 'Search',
987
+ pwFindHint: 'part of the site, the title or the user',
980
988
  pwFinding: 'searching…',
981
- pwFindFor: (q) => `Saved for ${q}`,
982
- pwFindNone: (q, n) => `Nothing saved for ${q} (${n} entr${n === 1 ? 'y' : 'ies'} in total).`,
983
- pwFindParents: 'The domain and its parents are searched: login.example.com finds what is saved for example.com.',
989
+ pwFindFor: (q) => `Matching “${q}”`,
990
+ pwFindNone: (q, n) => `Nothing matches “${q}” (${n} entr${n === 1 ? 'y' : 'ies'} in total).`,
991
+ pwFindParents: 'It searches part of the site, the title or the user: npm finds www.npmjs.com.',
984
992
  pwFindEmpty: 'This vault has no saved passwords yet.',
985
993
  pwFindOld: 'The passwords are in the old format: open the vault to convert them.',
986
- pwFindBadSite: 'That is not a site: type a domain (example.com) or a URL.',
994
+ pwFindEmptyQuery: 'Type something to search: part of the site, the title or the user.',
987
995
  pwFindNoRecovery: 'The password key has no copy for the phrase yet: open the vault so it gets one.',
988
996
  pwKindPassword: 'password',
989
997
  pwKindPasskey: 'passkey',
@@ -1109,7 +1117,7 @@ const en = {
1109
1117
  helpInput: 'Enter confirm · Esc cancel · Ctrl-U clear',
1110
1118
  helpConfirm: 'y confirm · n/Esc cancel',
1111
1119
 
1112
- helpProfiles: ['↑↓', 'Enter open', 'p pair', 'j join', 'n new', 'r rename', 'd delete', 'c password', 'x drop-password', 'y keys', 'o backup', 'f find password', 'u unlock', 'k lock', 's settings', 'l Español', 'q quit'],
1120
+ helpProfiles: ['↑↓', 'Enter open', 'p pair', 'j join', 'n new', 'r rename', 'd delete', 'c password', 'x drop-password', 'y keys', 'o backup', 'u unlock', 'k lock', 's settings', 'l Español', 'q quit'],
1113
1121
  helpDevices: ({ pending, hasDevices, isService, drafts, curBlocked } = {}) => [
1114
1122
  '←→ tab', '↑↓', 'p pair',
1115
1123
  ...(drafts ? ['g save permissions'] : []),