I have doubt whether you can run a query to see the recipients, as currently get errors.
look at this part and it seems that there is no such thing, https://github.com/OpenSMTPD/OpenSMTPD-extras/blob/18a1dca6cb8bbaf0790a263c153ff2d1222df4d8/extras/wip/tables/table-mysql/table_mysql.c In line 315 What I can do in my case ?. debug error: # smtpd -d -T lookup info: OpenSMTPD 5.4.4 starting info: startup debug: table-mysql: (re)connecting debug: table-mysql: connected debug: table-mysql: (re)connecting warn: table-mysql: wrong number of columns in resultset warn: table-mysql: could not connect debug: table-mysql: (re)connecting debug: table-mysql: connected debug: table-mysql: (re)connecting debug: table-mysql: connected lookup: check "myuser@mydomain" as MAILADDR in table proc:vrecipients -> -1 #cat vrecipients.conf host 127.0.0.1 username user password mipass database mail query_recipient select email from users where email = ? #cat /etc/mail/smtpd.conf # $OpenBSD: smtpd.conf,v 1.7 2014/03/12 18:21:34 tedu Exp $ # This is the smtpd server system-wide configuration file. # See smtpd.conf(5) for more information. # To accept external mail, replace with: listen on all # pki mail.darkmail.mx certificate "/etc/ssl/mail.darkmail.mx.crt" pki mail.darkmail.mx key "/etc/ssl/private/mail.darkmail.mx.key" table vrecipients mysql:/etc/mail/vrecipients.conf #table vdomains file:/etc/mail/vdomains table vdomains mysql:/etc/mail/vdomains.conf table valiases mysql:/etc/mail/valiases.conf table credentials mysql:/etc/mail/credenciales.conf listen on lo0 listen on egress port 25 listen on lo0 port 10026 tag CLAM_IN # incoming mail listen on lo0 port 10028 tag CLAM_OUT # outgoing mail listen on lo0 port 10029 tag DKIM_OUT # outgoing mail listen on re0 port 587 tls-require pki mail.darkmail.mx auth <credentials> # tagged mail returned from clamsmtpd either deliver or relay accept tagged CLAM_IN for domain <vdomains> recipient <vrecipients> relay via lmtp://127.0.0.1:2525 accept tagged CLAM_IN for domain <vdomains> virtual <valiases> accept tagged CLAM_OUT for any relay via smtp://127.0.0.1:10030 # send to dkimproxy # tagged mail returned from dkimproxy relay out accept tagged DKIM_OUT for domain <vdomains> recipient <vrecipients> relay via lmtp://127.0.0.1:2525 accept tagged DKIM_OUT for domain <vdomains> virtual <valiases> accept tagged DKIM_OUT for any relay # start here - untagged mail is sent to clamsmtpd accept from local for any relay via smtp://127.0.0.1:10027 # outgoing mail accept from any for domain <vdomains> relay via smtp://127.0.0.1:10025 # incoming mail -- editor de sueƱos -- You received this mail because you are subscribed to misc@opensmtpd.org To unsubscribe, send a mail to: misc+unsubscr...@opensmtpd.org