Do you know one of the addresses in the keychain? Ledger uses BIP44 derivation so you could write a loop to check different seed phrases and check the resulting addresses against an address you know that should be in the keychain. This way you can type in your recovery words without having to be online.
For example if it were me I'd probably write something using the bitcoinjs-lib. Here's a start written with bitcoinjs (NOTE I'm using version 3.3.2). This will take a recovery seed and an address and it will search the keychain and tell you whether or not the address exists within it.
//var words = "segment increase inch ensure corn cigar suggest fetch output proof peasant enact";
//var addr = "1c4XzQx7Uh8CnxzAN5CRrUjkbxGB1GUWp";
var searchbtn = document.getElementById("searchbtn");
searchbtn.onclick = function(){
var words = document.getElementById("words").value;
var addr = document.getElementById("addr").value;
var depth = document.getElementById("depth").value;
inkeychain(addr, words, depth);
}
function inkeychain(addr, keychain, depth){
var isfound = false;
for(var i=0;i<depth;i++){
var seed = hd.bip39.mnemonicToSeed(keychain);
var root = b.bitcoin.HDNode.fromSeedBuffer(seed)
//const root = bitcoin.HDNode.fromSeedHex(seed.toString('hex'))
var wallet = root.derivePath("m/44'/0'/0'/0/"+i);
//legacy
var address = wallet.getAddress();
var wif = wallet.keyPair.toWIF();
//segwit p2sh
var pubKey = wallet.keyPair.getPublicKeyBuffer();
var pubKeyHash = b.bitcoin.crypto.hash160(pubKey);
var redeemScript = b.bitcoin.script.witnessPubKeyHash.output.encode(pubKeyHash);
var redeemScriptHash = b.bitcoin.crypto.hash160(redeemScript);
var scriptPubKey2 = b.bitcoin.script.scriptHash.output.encode(redeemScriptHash);
var p2shsegwit = b.bitcoin.address.fromOutputScript(scriptPubKey2);
if(address===addr){
isfound = true;
console.log(address, wif);
$('#result').html('Found '+addr+' in this keychain at '+i+' position in the keychain');
alert('Found!');
} else if (p2shsegwit===addr){
//check for segwit p2sh
isfound = true;
console.log(p2shsegwit, wif);
$('#result').html('Found '+addr+' in this keychain at '+i+' position in the keychain');
alert('Found!');
}
}
if(isfound===false){
$('#result').html('No matches');
}
}
https://bitcoinfunction.com/?id=5d9ea508d9bed
From here you could take it a step further and make the words variable an array with all your different combos and then loop them all through.
Do you have to need a program for generating all possible combinations? an example a program that save inside the file that all possible combination. Or you are finding an program for testing all possible combinations directly on dispositive? – vincenzopalazzo – 2019-10-09T19:49:52.160
I have now listed all the possibilities through the code on the link the the original post. I just want to have an automated way to test the list of about 200 entries (I believe the list is so small due to checksum rule). I downloaded electrum wallet and have been testing a few manually but the process is quite tedious – Nate Gray – 2019-10-09T20:11:52.787