Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set cap ssl not working #1

Closed
lostfile1 opened this issue Jan 31, 2023 · 19 comments
Closed

Set cap ssl not working #1

lostfile1 opened this issue Jan 31, 2023 · 19 comments
Assignees

Comments

@lostfile1
Copy link

I'll show you some screenshots of the log later, but I'm having problems with pointing it at an SSL certificate and a few other module errors.

@InterLinked1
Copy link
Owner

Thanks for reporting an issue. Which module is this with, door_irc, I'm assuming? There's an IRC server module in development for the BBS, but it hasn't been released yet.

door_irc uses the lirc library under the hood (https://github.com/InterLinked1/lirc). It seems to always complain about the SSL certificate if you set verify on (something with OpenSSL), but it should successfully connect.

Please provide log messages with debug to proceed further.

@lostfile1
Copy link
Author

Oh no! It has to do with the http server also, the ssh server seems to fail to load it can't find any keys

@InterLinked1
Copy link
Owner

InterLinked1 commented Jan 31, 2023

The SSH server and HTTP server are two separate modules; the latter uses SSL configuration configured in tls.conf.

You will need to explicitly specify your keys there or it won't work. There are no default keys that are used. Same for SSH but in net_ssh.conf.

SSH has some settings you can adjust in net_ssh.conf if it doesn't like certain keys (I had to disable DSA on mine).

If you're getting errors or having other issues, we really need logs to proceed further. Set the debug level to 10 and please send the relevant output from /var/log/lbbs/bbs.log

@lostfile1
Copy link
Author

I know I copied the SSL keys from my truecrypt folder and gave them user privileges put them in a folder and pointed the tls.conf at it

@InterLinked1
Copy link
Owner

Sorry, we'll really need to see your configuration and the actual log messages to assist further.

@lostfile1
Copy link
Author

lostfile1 commented Jan 31, 2023

heres the log file
bbs.log

@lostfile1
Copy link
Author

heres my hole /etc/lbbs folder with out the cert files
and a few things where changed so i dont leak my database password
lbbs.zip

@InterLinked1
Copy link
Owner

What is the output of:

ls -la /etc/ssh/ssh_host_rsa_key
ls -la /etc/ssh/ssh_host_ecdsa_key

The BBS isn't able to read the keys, which is why the SSH daemon fails to start.

@lostfile1
Copy link
Author

lostfile1 commented Jan 31, 2023

-rw------- 1 root root 2602 Jan 30 21:04 /etc/ssh/ssh_host_rsa_key

oh i think i see the problem im gonna change the perms and see if that will fix it

@lostfile1
Copy link
Author

nope same problem

@InterLinked1
Copy link
Owner

The permissions in the above output don't allow the BBS user to read the key file.
Have you tried something like chmod +r /etc/ssh/ssh_host_rsa_key?
You could also try making the keys owned by the BBS user: chown bbs /etc/ssh/ssh_host_rsa_key (assuming the BBS run user is bbs.

If that's still not working, I need fresh logs and the output of the above commands again.

@lostfile1
Copy link
Author

it worked after runing it a few times

@lostfile1
Copy link
Author

lostfile1 commented Jan 31, 2023

ERROR[2190]: mod_mysql.c:273 sql_stmt_fetch: SQL STMT fetch failed: Commands out of sync; you can't run this command now

it works but i noiced that error
WARNING[2246]: net_http.c:369 parse_header: Unknown HTTP request method: ��e�>^��-0���.�`V��x"ݐku��ˁ��,�P�m�-M��)�#eM����s�2�광˂� +�z=������FS.��I
and this one wile trying to connect to the https server

@lostfile1
Copy link
Author

here try loging into ssh brokenserver.ddns.net port 224 i need to add more menus and stuff but im going to leave it up for now for testing

@InterLinked1
Copy link
Owner

I've been noticing that mod_mysql error too recently. I will look into it at some point, but as far as I can tell, functionality wise, everything is fine. You can ignore that for now.

Was the second request actually from you making an HTTPS request yourself? There could be an issue with HTTPS, if HTTP works fine for you.

Your server doesn't seem to respond for me but glad it's coming along for you!

@lostfile1
Copy link
Author

i think it might have crashed but yes i made the https request myself

@InterLinked1
Copy link
Owner

If it crashed, then a backtrace is also needed. You can use the bbs_dumper script to do that, assuming you started the BBS with the -g option before it crashed.

@lostfile1
Copy link
Author

thanks for the tip

@lostfile1
Copy link
Author

ERROR[10517]: tls.c:111 ssl_new_accept: SSL error -1: 1 (SSL_ERROR_SSL = error:14094418:SSL routines:ssl3_read_bytes:tlsv1 alert unknown ca)

@InterLinked1 InterLinked1 self-assigned this Feb 2, 2023
InterLinked1 added a commit that referenced this issue Feb 2, 2023
If SSL initialization failed, we would goto cleanup,
where clientfp could be used uninitialized, causing
a segfault. Actually, there is no need to goto cleanup,
since there is nothing to clean up, so we can just return.

Partially addresses #1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants