Metadata-Version: 2.4
Name: chibi_sshd
Version: 1.1.0
Summary: package for handling config files of ssh like sshd_config and authorized_keys
Home-page: https://github.com/dem4ply/chibi_sshd
Author: dem4ply
Author-email: dem4ply@gmail.com
License: WTFPL
Keywords: chibi_sshd
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: Public Domain
Classifier: Natural Language :: English
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
License-File: LICENSE
License-File: AUTHORS.rst
Requires-Dist: chibi>=0.17.0
Requires-Dist: chibi_atlas>=1.1.0
Requires-Dist: chibi_hybrid>=1.2.1
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: home-page
Dynamic: keywords
Dynamic: license
Dynamic: license-file
Dynamic: requires-dist
Dynamic: summary

==========
chibi_sshd
==========


.. image:: https://img.shields.io/pypi/v/chibi_sshd.svg
        :target: https://pypi.python.org/pypi/chibi_sshd

.. image:: https://readthedocs.org/projects/chibi-sshd/badge/?version=latest
        :target: https://chibi-sshd.readthedocs.io/en/latest/?badge=latest
        :alt: Documentation Status




package for handling config files of ssh like sshd_config and authorized_keys


* Free software: WTFPL
* Documentation: https://chibi-sshd.readthedocs.io.


=======
Install
=======


.. code-block:: bash

	pip install chibi-fstab


=====
Usage
=====


.. code-block:: bash

	cat > /etc/ssh/ssh_config << 'endmsg'
	AuthorizedKeysFile .ssh/authorized_keys
	PasswordAuthentication yes
	ChallengeResponseAuthentication no
	UsePAM yes
	PrintMotd no
	UseDNS no
	Subsystem sftp	/usr/lib/ssh/sftp-server
	AllowUsers Misuzu
	endmsg

.. code-block:: python

	from chibi_sshd import Chibi_sshd_conf, Chibi_authorized_keys
	from chibi.file import Chibi_path

	default_file = = Chibi_sshd_conf.default
	assert default_file.path == '/etc/ssh/sshd_config'
	config = default_file.read()
	assert isinstance( config.PasswordAuthentication, bool )
	assert config.PasswordAuthentication
	config.PasswordAuthentication = False
	default_file.write( config )
	assert "PasswordAuthentication no" in default_file

	authorized_keys = Chibi_authorized_keys(
		'/home/Misuzu/.ssh/authorized_keys' )
	id_rss_pub = Chibi_path(
		'/home/Misuzu/.ssh/id_rss.pub' ).open().read()
	if id_rss_pub not in authorized_keys:
		authorized_keys.append( id_rss_pub )
	assert id_rss_pub in authorized_keys:


=======
History
=======

********************
1.1.0 ( 2026-03-23 )
********************

* se cambio el comportamiento para que AllowUsers se parse como lista y si se 
  serializa una cadena la maneja como lista de un elemento

********************
1.0.0 ( 2026-03-22 )
********************

* se agrega clase de file para las configuracion de sshd
* se agrega clase de file para las llaves authorizadas de los usuarios

********************
0.0.1 ( 2026-03-22 )
********************

* First release on PyPI.
