Thomas Waldmann
fbbe0ad723
translate model fields' help_text
2014-09-03 14:29:54 +02:00
Thomas Waldmann
cf2c46e612
use FQDN typed params in api, remove unused parse_name (which was problematic anyway)
2014-08-30 18:27:21 +02:00
Thomas Waldmann
f26ae31882
s/ssl_update_v4/tls_update_v4/g (and same for v6)
...
SSL is the old/outdated name. Since 1999, it's called TLS.
Changed model field names. Added a schema migration to rename the DB columns.
Note: the schema migration also adds/removes the index introduced in cs 32289ebb183907e8618ff251dd5846fd00fe9423
2014-05-30 02:03:48 +02:00
Thomas Waldmann
070a1445be
s/ssl/secure/g
...
SSL is the old/outdated name. Since 1999, it's called TLS.
Changed some API params.
2014-05-30 01:28:34 +02:00
Thomas Waldmann
46008bf2cd
s/SSL/TLS/g (almost)
...
SSL is the old/outdated name. Since 1999, it's called TLS.
In this changeset, I did the mostly harmless changes (UI, logs, docs).
2014-05-30 01:10:33 +02:00
Thomas Waldmann
32289ebb18
index subdomain and domain together (as they are only unique together also)
2014-05-29 17:19:08 +02:00
Thomas Waldmann
9341df05bb
optimize filter_by_fqdn(), rename to get_by_fqdn()
...
as we precisely expect 1 result (0 or more than 1 are error cases), use .get() instead of .filter().
avoid usage of len().
maybe this is a little more efficient than before.
2014-05-29 15:25:38 +02:00
Thomas Waldmann
400259c758
get_ip: if there is no A/AAAA record, anwer "none" (anwer "error" only in real error cases)
2014-01-22 14:03:36 +01:00
Thomas Waldmann
ba977193ce
Merge branch 'master' into py3-port
...
Conflicts:
nsupdate/main/_tests/test_main.py
2013-12-24 21:31:40 +01:00
Thomas Waldmann
0df4efce1c
add/fix some module-level docstrings
2013-12-15 17:09:22 +01:00
Thomas Waldmann
711aba237f
python 3.3 port
...
not much tested yet, be careful
2013-12-14 00:35:29 +01:00
Thomas Waldmann
088c53e78b
fix: add default=False to BooleanFields (otherwise it might complain about "not NULL")
2013-12-07 21:59:00 +01:00
Thomas Waldmann
866ddf3bea
add available, abuse and abuse_blocked flags to Host, show on UI, script to reset flags
...
there is an issue with south and sqlite - it doesn't handle migrations that add BooleanField columns with defaults.
just use the faults script to set the flags to their correct default after migrating with south.
2013-11-30 12:32:03 +01:00
Thomas Waldmann
7500ba363e
Host.get_ip* - reduce code duplication
2013-11-30 10:07:46 +01:00
Thomas Waldmann
996a398b46
models: use shorter unicode representations
2013-11-29 11:13:59 +01:00
Thomas Waldmann
2aeb2a61f8
service updater (host configs): add (give|accept)_(ipv4|ipv6) fields
2013-11-29 02:11:55 +01:00
Thomas Waldmann
aa610e9c3a
implement "update other services", with tests, no ui yet
...
(can be used when adding the records via django admin)
2013-11-26 08:10:05 +01:00
Thomas Waldmann
e9605535b8
add counters for client and server faults (per host)
2013-11-24 11:42:59 +01:00
Thomas Waldmann
087c1d2c93
deduplicated fqdn lookup uniqueness check, fixed _update return values (must be Response objects, not bool)
2013-11-24 10:43:15 +01:00
Thomas Waldmann
9cd1b7d9f9
blacklist validator: fix validation error msg
...
do not talk about "domain" if we check a hostname.
also tell it is because of the blacklist.
2013-11-24 09:50:57 +01:00
Thomas Waldmann
d83df3ead1
use get_user_model and AUTH_USER_MODEL
2013-11-24 09:37:47 +01:00
Thomas Waldmann
a1210b21eb
cleanup created_by in models
...
looks like there was some reference to settings.AUTH_USER_MODEL (which is undefined)
brought Host and Domain model in sync for some fields
2013-11-24 08:34:01 +01:00
Thomas Waldmann
9c82ec021f
remove comment from Host __unicode__() for consistency (we do not have the comment in Domain __unicode__() either)
2013-11-24 05:23:20 +01:00
Thomas Waldmann
dd09b6b5af
nameserver update key / secret terminology cleanup
...
key = secret + algorithm
2013-11-24 05:04:07 +01:00
Thomas Waldmann
972a411ef4
make adding a domain workflow more similar to adding a host
...
don't ask for the secret in the first form, just autocreate one and show the configuration example with it.
2013-11-24 04:14:31 +01:00
Thomas Waldmann
ed074dd33b
catch exception when trying to delete a host we are not allowed to modify anyway
2013-11-23 02:57:15 +01:00
Thomas Waldmann
ab421fb686
models: use sane field lengths
...
for unique fields there seems to be a limit of 255 chars (not: 256)
some fields are much less than we initially had
2013-11-23 02:51:18 +01:00
Thomas Waldmann
d6b5041573
a real nic update api test, using basic auth
...
generate_secret was modified to support giving a secret (not generating a random one), so it matches the test database
add a User and a Host to the test db
2013-11-16 01:25:05 +01:00
Thomas Waldmann
cc7b22d63f
more help texts
2013-11-08 08:03:12 +01:00
Thomas Waldmann
c3ec4c5a50
Fix/generalize ns update secret generation. Reduce code duplication. Fixes #74 .
2013-11-06 02:21:12 +01:00
Thomas Waldmann
e2f51d5eb1
more pep8 fixes
2013-11-05 00:32:07 +01:00
Thomas Waldmann
e194ac0e46
show whether we received last v4/v6 update via SSL
2013-11-03 08:32:43 +01:00
Thomas Waldmann
4f50664977
add comment field for Domains
2013-11-02 12:37:27 +01:00
Thomas Waldmann
35c953347c
domain editing, shared secret generation, show bind9 configuration
2013-11-02 11:29:06 +01:00
Thomas Waldmann
87b3711fd5
handle deletion of a Domain
...
as we reference the Domain as ForeignKey in the Host, it'll kill all Hosts that reference the deleted Domain also.
needs to be the PRE_delete signal as some of the data we need is already gone when using POST.
2013-11-02 00:12:36 +01:00
Thomas Waldmann
979f2f8b3e
separate ipv4 and v6 update timestamps
2013-10-27 13:09:46 +01:00
Thomas Waldmann
1cc4236d58
add help texts to Domain model fields, improve view
2013-10-27 11:59:16 +01:00
Thomas Waldmann
a210936dcf
use now() from django.utils.timezone - it is utc and not naive
2013-10-27 07:29:58 +01:00
Thomas Waldmann
4cf62af8ab
rename Domain field available_for_everyone to public (so it is not confused with "available" field)
...
"public" field means that this zone can be used by every user (not just the owner) to create hosts there
"available" field means that the nameserver is operating and reachable
2013-10-27 05:28:30 +01:00
Thomas Waldmann
6bf1f57fc1
deal with not responding nameservers (offline or unreachable)
...
if a nameserver does not respond, we flag it in the database
(available = False) and stop talking to it for 5 minutes.
after 5 minutes, we flag it available = True again and retry talking to it
(and if not successful, flag it as unavailable again).
this avoids a unresponsive UI as we do a lot of ns queries from the templates
to get v4 and v6 addresses of our hosts from master nameservers.
we log a warning when setting unavailable and a info when setting available.
2013-10-27 05:14:47 +01:00
Thomas Waldmann
49693121ea
use zones/nameserver IPs/update keys from DB, logging (thanks to asmaps)
...
remove unneeded stuff from settings
(we still need some in conftest.py for the tests, though)
init DB for tests via conftest.py
more update algorithm choices
give origin zone (if we already know it) to dnstools functions
new views: DomainOverview, DeleteDomain
unify deletion templates using delete_object.html
add django-extensions
2013-10-18 15:30:17 -07:00
Bastian Blank
b161265cad
Use GenericIPAddressField to allow IPv6
2013-10-17 23:59:07 +02:00
Bastian Blank
d2eab62ac4
Move all stuff into own top-level package
2013-10-17 23:59:07 +02:00
Thomas Waldmann
1924888b37
reorder imports: stdlib, other libs, django, nsupdate stuff (views, etc.)
2013-10-03 19:26:39 +02:00
Thomas Waldmann
c9e21202cc
remove outdated TODO about hashing the update_secret
2013-10-03 17:42:58 +02:00
Thomas Waldmann
51caaea41f
use newstyle classes
2013-10-03 17:21:18 +02:00
Thomas Waldmann
42a89b4b42
fix pep8, fix indentation
2013-10-03 03:22:09 +02:00
Fabian Faessler
ec4e6c5df7
added Exceptions
2013-09-30 01:40:31 +02:00
Fabian Faessler
c00345df20
some overview ui changes
2013-09-29 23:49:18 +02:00
Arne Schauf
df971fe8e9
more fields
2013-09-29 22:48:09 +02:00