Commit graph

27 commits

Author SHA1 Message Date
Mael GRAMAIN 8744a7e5df AllowedOrigins []strings option in the configuration file for the API
The App{} struct have been updated to parse a new argument for the API configuration file.

AllowedOrigins permit the user to set what URLs are allowed to send request to the API via CORS headers.
2021-01-17 18:12:29 -04:00
Mael GRAMAIN d071c8e6e2 Fix SCC-SA4006 (Deepsource) with Debugging for GetSoa() in the AXFR func 2021-01-16 15:16:53 -04:00
Mael GRAMAIN 1ec2b3c5a2 XFR is now limited to certains IP configured in the config file
https://github.com/outout14/sacrebleu-dns/issues/11
https://github.com/outout14/sacrebleu-dns/issues/11#issuecomment-753423572
2021-01-03 15:57:06 -04:00
Mael GRAMAIN 384ca40434 New parameters in the config file 2021-01-03 15:17:01 -04:00
Mael GRAMAIN 78744ea1ac AXFR support
#11
2021-01-01 22:34:54 -04:00
Mael G. d1b9dba472 Using sqlMigrate from sacrebleu-api 2020-12-27 22:58:20 -04:00
Mael G. 1cf5c4f3d5 Using api structs for the Records 2020-12-27 20:34:26 -04:00
Mael G. e05cab9d5e Multiple records support 2020-12-27 19:05:16 -04:00
Luclu7 44f07ca2a2
add support for sockets (mostly clarification) 2020-12-25 03:06:20 +01:00
Luclu7 8220eacb10
config: fixed app_mode
also changed like Ip to IP and Db to DB
2020-12-25 02:31:28 +01:00
Mael G. deb28bbff9 GORM logging level is now based on the AppMode configuration 2020-12-22 21:36:41 -04:00
Mael G. 0b6b6d977c Simplify returning boolean expression 2020-12-22 21:30:32 -04:00
Mael G. eeea8c17b7 SQL database migration command 2020-12-22 21:01:18 -04:00
Mael G. 3737e17ecf Switched sql funcs returns from int to bool 2020-12-22 20:20:06 -04:00
Mael G. 4a14ad594b Switching from database/sql to GORM 2020-12-22 20:09:10 -04:00
Mael G. 43e8ab8210 PostgreSQL Support
Implementation of PostgreSQL database engine in the DNS server using jackc/pgx (as database/sql driver). 
The user can select what database type he want in the config.ini file under the database section.
2020-12-22 14:56:54 -04:00
Mael G. efffac8b0a Refactoring of some vars and funcs name
Theses change breaks old configuration files but make the code readability better thanks to VSCode plugins.
2020-12-21 23:12:02 -04:00
Mael G. 98537616c8 Commenting 2020-12-14 18:20:24 -04:00
Mael G. e70571c450 Better SqlTest() function 2020-12-13 21:15:43 -04:00
Mael G. 61d6d47637 Unused code removed 2020-12-13 21:06:29 -04:00
Mael G. c858b1b5e1 test sql connexion before launch 2020-12-13 20:58:01 -04:00
Mael G. c17d650520 Removed unused values 2020-12-13 14:43:31 -04:00
Mael G. 9394aeeb9d Fixes 2020-12-13 14:40:14 -04:00
Mael G. e28b61e2f0 strings.Replace replaced by strings.ReplaceAll helper function 2020-12-13 14:37:09 -04:00
Mael G. 0c50b409f0 Warning removed 2020-12-13 14:30:58 -04:00
Mael G. e5bf49a363 Database name is now dynamic 2020-12-13 14:30:29 -04:00
Mael G. 36ce33e8f1 Init 2020-12-12 23:01:04 -04:00