diff --git a/dist/doip.core.js b/dist/doip.core.js index e019a48b8136941fd8e21091a7d323d5cfbf83e7..368e9b0b7ea0b5dde987ea3805a69d82c724536d 100644 --- a/dist/doip.core.js +++ b/dist/doip.core.js @@ -5263,6 +5263,7 @@ var doip = (function (exports, fetcher, openpgp$1) { * @property {string|null} claims.activitypub.privateKey - The private key to sign the request * @property {object} claims.irc - Options related to the verification of IRC claims * @property {string|null} claims.irc.nick - The nick that the library uses to connect to the IRC server + * @property {string|null} claims.irc.password - The password that the library uses to connect to the IRC server * @property {object} claims.matrix - Options related to the verification of Matrix claims * @property {string|null} claims.matrix.instance - The server hostname on which the library can log in * @property {string|null} claims.matrix.accessToken - The access token required to identify the library ({@link https://www.matrix.org/docs/guides/client-server-api|Matrix docs}) @@ -5284,7 +5285,8 @@ var doip = (function (exports, fetcher, openpgp$1) { privateKey: null }, irc: { - nick: null + nick: null, + password: null }, matrix: { instance: null, diff --git a/dist/doip.fetchers.js b/dist/doip.fetchers.js index acef0d990b81eba01e78404e726766e81bf46ddd..e056d695a3aabe16ce5312e42b733fb930110b59 100644 --- a/dist/doip.fetchers.js +++ b/dist/doip.fetchers.js @@ -23603,6 +23603,7 @@ var doipFetchers = (function (exports) { * @param {object} opts.claims * @param {object} opts.claims.irc * @param {string} opts.claims.irc.nick - The nick to be used by the library to log in + * @param {string} opts.claims.irc.password - The password to be used by the library to log in * @returns {Promise} */ async function fn$3 (data, opts) { @@ -23627,7 +23628,10 @@ var doipFetchers = (function (exports) { secure: true, channels: [], showErrors: false, - debug: false + debug: false, + sasl: opts.claims.irc.password !== null ? true : false, + userName: opts.claims.irc.nick, + password: opts.claims.irc.password }); const reKey = /[a-zA-Z0-9\-_]+\s+:\s(openpgp4fpr:.*)/; const reEnd = /End\sof\s.*\staxonomy./; diff --git a/src/defaults.js b/src/defaults.js index 024cc19612bba1e55f5233e61f78e0f00bc9aa92..2ab81779576f4eb2a7ebc46544a7992d0b1fb7e9 100644 --- a/src/defaults.js +++ b/src/defaults.js @@ -32,6 +32,7 @@ import { ProxyPolicy } from './enums.js' * @property {string|null} claims.activitypub.privateKey - The private key to sign the request * @property {object} claims.irc - Options related to the verification of IRC claims * @property {string|null} claims.irc.nick - The nick that the library uses to connect to the IRC server + * @property {string|null} claims.irc.password - The password that the library uses to connect to the IRC server * @property {object} claims.matrix - Options related to the verification of Matrix claims * @property {string|null} claims.matrix.instance - The server hostname on which the library can log in * @property {string|null} claims.matrix.accessToken - The access token required to identify the library ({@link https://www.matrix.org/docs/guides/client-server-api|Matrix docs}) @@ -53,7 +54,8 @@ export const opts = { privateKey: null }, irc: { - nick: null + nick: null, + password: null }, matrix: { instance: null, diff --git a/src/fetcher/irc.js b/src/fetcher/irc.js index f07a32a7c54a9489dbab27b32b1b1d8246485ec1..c3c953257431a50f826c24d2a9ba7f638860fda5 100644 --- a/src/fetcher/irc.js +++ b/src/fetcher/irc.js @@ -30,6 +30,7 @@ export const timeout = 20000 * @param {object} opts.claims * @param {object} opts.claims.irc * @param {string} opts.claims.irc.nick - The nick to be used by the library to log in + * @param {string} opts.claims.irc.password - The password to be used by the library to log in * @returns {Promise} */ export async function fn (data, opts) { @@ -54,7 +55,10 @@ export async function fn (data, opts) { secure: true, channels: [], showErrors: false, - debug: false + debug: false, + sasl: opts.claims.irc.password !== null ? true : false, + userName: opts.claims.irc.nick, + password: opts.claims.irc.password }) const reKey = /[a-zA-Z0-9\-_]+\s+:\s(openpgp4fpr:.*)/ const reEnd = /End\sof\s.*\staxonomy./