aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* add new method handlers/properties for new location & deployment elementsHEADdevelkremlin2016-07-151-3/+152
|
* remove references to deprecated tzfile.h, use previously defined constskremlin2016-07-151-5/+4
|
* property cleanupskremlin2014-12-201-14/+23
|
* change 'rcctl' invocations to /etc/rc.d/fookremlin2014-12-201-8/+9
| | | | we will switch it back when 5.7 rolls around
* add NTP property code. and timedated is done! (except for undocumented ↵kremlin2014-10-151-5/+12
| | | | properties)
* complete setNTP method, calls rcctl(8) through system(3)kremlin2014-10-151-1/+73
| | | | | setNTP takes a boolean and starts/enables ntpd through rcctl if true and stops/disables ntpd if false
* clarify RTC/UTC messages/commentskremlin2014-10-151-2/+2
|
* prevent directory traversal in setTimezonekremlin2014-10-141-2/+9
|
* complete SetTimezone functionkremlin2014-10-141-1/+99
|
* disable TZ checksumming, fix setTimekremlin2014-10-142-13/+42
| | | | | | | | the checksumming function was very ineffecient and was causing the executable to stall on launch, making dbus launch it on new PIDs. this caused a very hard to diagnose bug that would mangle the system time after several calls to setTime in short succession
* fixed logic/math bugs in set-time, still broken with GNOME toolskremlin2014-09-261-15/+10
|
* completed timedated's SetTime methodkremlin1973-03-031-4/+36
|
* began general logic for timedated's SetTime methodkremlin2014-09-141-5/+73
|
* add localtime determination system for timezone propertykremlin2014-08-263-19/+123
| | | | | | | this determines the proper timezone string (e.g. America/New_York) by first checking if /etc/localtime is symlinked to a named timezone in /usr/share/zoneinfo. if not, a warning is thrown and /etc/localtime's checksum is compared against a previously generated table.
* begin get_timezone(), begin get_timezone_path() util funckremlin2014-08-262-1/+57
|
* switch params.h with types.h and include time.h in timedated.ckremlin2014-08-261-1/+2
|
* add get_file_sha256(path) to util.ckremlin2014-08-261-0/+20
|
* if /etc/myname lacks a trailing domain, do not force the defaultkremlin2014-08-251-1/+1
| | | | discussed with ajacoutot
* add config_[set,get]() in util.c, replace ini-style configkremlin2014-08-253-50/+98
| | | | | configs are now key->value pairs delimited by newlines, seperated by '=' signs. replace all instances of g_key_file ini-like configs
* fill in timedated skeleton funcskremlin2014-08-251-25/+92
|
* fill in localed skeleton funcskremlin2014-08-251-22/+72
|
* change polkit-auth.{c,h} to util.{c,h}kremlin2014-08-256-5/+5
| | | | | we are going to include the /etc/os-release changing functions in here.
* set /etc/myname when setStaticHostname is calledkremlin2014-08-251-1/+13
| | | | always sets a FQDN (see recent previous commits)
* add get_bsd_hostname() and has_domain()kremlin2014-08-252-1/+105
| | | | | | | | | get_bsd_hostname takes a string and returns a proper FQDN to be written to /etc/myname or NULL if the passed string is unsalvagable. if passed string does not contain a domain, the current domain from /etc/myname is used. if /etc/myname does not contain a trailing domain, an error message is printed and the default (".home.network") is used.
* pretty hostname and static hostname no longer sync across each otherkremlin2014-08-211-12/+10
|
* make SetStaticHostname() call sethostname()kremlin2014-08-211-2/+2
|
* change polkit action names to match systemd's exactlykremlin2014-08-181-5/+5
| | | | | gnome-control-center has polkit rules which refer explicitly to action names we need to match for it to work with our code properly
* Add XXX and mention /etc/os-release for our_get_os_cpename().Antoine Jacoutot2014-08-171-1/+2
|
* Get/set info into /etc/machine-info.Antoine Jacoutot2014-08-171-9/+9
| | | | discussed with Ian
* finish remaining hostnamed method handlerskremlin2014-08-162-4/+331
| | | | hostnamed is complete!
* remove unnessecary free in polkit-auth.ckremlin2014-08-161-2/+0
|
* tighten up polkit-auth, implement in hostnamed.ckremlin2014-08-163-25/+73
|
* minor, remove test func from hostnamed.ckremlin2014-08-161-2/+0
|
* complete polkit-auth functionalitykremlin2014-08-162-3/+70
| | | | | | polkit-auth exposes one function taking an alleged unique bus name and alleged action name (id) and returns an enum describing if and how action is authorized.
* add polkit auth object, compile it in makefile, add header to interfaceskremlin2014-08-166-0/+57
| | | | | src/polkit-auth.c and its header are seperately built objects, linked to interfaces, which expose a single, safe auth checking function
* minor, fix tab/spacing issue in hostnamed.ckremlin2014-08-161-2/+2
|
* get rid of main.c and references to it, it has been unused for a while nowkremlin2014-08-161-31/+0
|
* polish hostname setter func, fix logic issues with propkremlin2014-08-161-12/+31
| | | | | | handle_set_hostname works almost perfectly (still needs polkit auth checking). returns logical D-Bus errors and sets hostname property correctly now.
* include polkit.h in all interfaces, edit makefile accordinglykremlin2014-08-164-2/+6
|
* consolidate name setting functionality into set_name()kremlin2014-08-101-44/+32
| | | | | | this follows the precedent of setting globals during init like chassis/icon/uname properties and makes better sense overall. birthday commit! happy birthday ian
* add set_names(), complement to icon/chassis setterskremlin2014-08-092-50/+63
| | | | | it runs during init and acts just like like icon/chassis/uname(3) functions work
* make *name prop. getters operate similarly to otherskremlin2014-08-091-9/+26
|
* add SetHostname functionalitykremlin2014-08-081-1/+30
| | | | | sethostname now works, cleans up after itself properly and cleans/checks incoming data before trying to sethostname(3).
* minor, make xen an uncertainty and move a comment that was misplacedkremlin2014-08-081-2/+3
|
* "SmartDC HVM" comes from illumos-joyent, not Oracle SolarisAntoine Jacoutot2014-08-071-1/+1
|
* recatagorize QEMU/KVM/etc. to correct baremetal classificationkremlin2014-08-071-6/+7
|
* add support for vars from uname(3)kremlin2014-08-072-8/+52
| | | | | fill out remaining properties for hostnamed, which can be easily found through uname(3) calls.
* minor, initialize counter to zero. i might be a bit tired.kremlin2014-08-071-0/+1
|
* minor, add generous fixed buffer for sysctl stringskremlin2014-08-071-2/+8
|
* minor, init some vars to 0 for safteykremlin2014-08-071-0/+2
|
* minor, remove extra commakremlin2014-08-071-1/+1
|
* minor, remove old comments + add KVM to chassis indicator tablekremlin2014-08-071-48/+4
|
* embellish chassis/icon detection for laptops/servers/VMs/desktopskremlin2014-08-072-25/+141
| | | | | | import landry's upower function to detect laptop-ness check arch if sparc*/hppa to detect server-ness connect functionality to DBus side of things
* revamp icon/chassis determination methodkremlin2014-08-072-36/+100
| | | | | | icon/chassis is now set once during init and then referred to afterwords. replaced string array with nice struct, added clear instructions. added virtualization give-aways from my research + icon names (xdg)
* add WIP bit of chassis detection for hostnamedkremlin2014-08-062-2/+54
| | | | hostnamed checks sysctl output for known vm indicators
* minor, clean up last commit to compile with strict flagskremlin2014-08-062-5/+7
|
* add get_[static/dynamic/pretty]hostname functionalitykremlin2014-08-061-5/+33
| | | | | | | | | | | | dynamic hostname (sometimes just hostname) is always whatever the gethostname(3) returns. static hostname is derived from prettyhostname, which attempts to convert it to a 7 bit ascii hostname (no bookend -'s, etc.) if this fails or prettyhostname has not yet been set, defaults to gethostname(3). prettyhostname is whatever is in /etc/systemd_compat.conf, if reading that fails it is just an empty string. prettyhostname is blank until manually set.
* minor, retab \t's to four spaceskremlin2014-08-065-127/+127
|
* minor, s/g_print/g_printfkremlin2014-08-053-3/+3
|
* minor, add ISC license blurbs to interfaces/foo/foo.hkremlin2014-08-054-3/+67
|
* minor, add a TODO to hostnamed.c i caughtkremlin2014-08-051-0/+4
|
* (8) [final] modify main() to call correct clean sequencekremlin2014-08-053-3/+19
| | | | | | | main() now sets the signal handlers (via function from previous commit) before establishing the GMainLoop as well as invoke the proper clean()'s after unref'ing the loop. at this point all four interfaces are at the same place structurally. builds all cases.
* (7) add set_signal_handlers() to bind functions during initkremlin2014-08-053-0/+24
| | | | | | | this function calls attached the ones from the previous commit to the GLib runtime properly. since we are working solely in the default context (in terms on the GMainLoop) we are guaranteed the attached functions will only run once.
* (6) add handler for unix termination signalskremlin2014-08-053-0/+27
| | | | | | | | it prints a message and calls foo_mem_clean(), swiftly and safely bringing the runtime down before letting the calling thread it was ready to exit. note, this is handled through GLib which guarantees it is only fired once, rather than unwrapped signals that can occur wildly.
* (5) fix foo_mem_clean() functions to avoid race cond.kremlin2014-08-053-6/+24
| | | | | | | | | | mem_clean functions previously free()'d our pointer array without first checking that the name/interface had properly been unexported from dbus. checking first better guarantees all operations implicating that date have ceased, and that it is safe to go ahead and stop the GMainLoop before immediately returning. this causes the code just after the main_loop_begin() call to start functioning, in our case the actual free() calls (which are now *absolutley* safe to call)
* (4) move on_name_acquired functionality to on_bus_acquiredkremlin2014-08-054-50/+74
| | | | | | | | | work that was previously done in foo_on_name_acquired(), such as attaching the interface to the name, is now done in foo_on_bus_acquired(), as GIO docs suggest. this fixed a bug with logind failing to export, the name_acquired function executed executed too late to export a big interface like logind. fix some minor error msg/consistency stuff in hostnamed, merge across pals. builds
* (3) add needed GLib headers, move loop and bus descr out of main into globalkremlin2014-07-293-9/+18
| | | | | | minor variable placement changes. added gboolean dbus_interface_exported, which due to the guarantees of the name_lost, bus_acquired, and name_acquired is a reliable source of whether not it is reasonable to try and unexport it
* (2) move on_name_lost() callback to appropriate commend-bounded regionkremlin2014-07-293-27/+27
| | | | minor, builds
* (1) add <interface>.h and #include it in corresponding .ckremlin2014-07-296-0/+6
| | | | nessecary for compiler unambiguity. minor, builds
* see full message -- safe signal/lifetime/glib codekremlin2014-07-292-33/+78
| | | | | | | | | | | | | | | | | | | this unusually dense commit is the product of me using hostnamed as a prototyping bed, you should instead follow the next numbered series of commits to proceed this one, as they are the same changes but made incrementally and gradually across the other three interfaces. added: * proper lifetime handling, everything coordinated in a gmainloop such that daemons don't clean their memory twice or trip over the last instance's unclosed file descriptors, etc. * threadsafe unix termination signal handling * more intuitive runtime, daemons immidietly either start up perfectly and print a verification or crash and print a reason/probable solution * some bugfixes detailed in further individual commits
* minor, clarify what "misc functions" are in commentskremlin2014-07-294-4/+4
|
* minor, clarify "dbus signal" vs. "unix signal" in commentskremlin2014-07-294-8/+8
|
* include glib-unix.h in interface fileskremlin2014-07-294-0/+4
| | | | | it's a good idea to use glib signal handling, most use cases will be running gnome
* remove genfiles from repo, instead generate in makefilekremlin2014-07-238-21486/+0
| | | | | | genfiles (-gen.{c,h}) should be generated at build time instead of being included in the repo. remove them & add relevant recipes/pre-reqs include genfiles in 'clean' recipe
* copy and regex localed, timedated, and logind from hostnamedkremlin2014-07-223-0/+347
| | | | | they now start up and display the proper methods/functions on the system bus, albeit with no functionality
* hostname1 now returns hostname minus domain infokremlin2014-07-221-4/+10
| | | | also initializes pointer array properly, no more GLib warnings
* clean up hostnamed.c, clear out localed.c for copyingkremlin2014-07-222-154/+11
| | | | | | | fix minor memory management issues in hostnamed.c. localed.c was previously based on a version of hostnamed.c i copied, however it has strayed too far away from the working version and must be recopied/refactored.
* empty main.ckremlin2014-07-221-27/+1
|
* cut out config.c & config.h, they are unnessecarykremlin2014-07-222-101/+0
|
* tighten up memory management in hostnamed.ckremlin2014-07-221-8/+12
|
* refactor hostnamed.c to work with namespace genfile changekremlin2014-07-221-27/+25
|
* cut comments in main.c, prepare it to be removedkremlin2014-07-221-13/+3
|
* change gen script to use ksh, remove namespace option, regen genfileskremlin2014-07-228-4270/+4270
| | | | | | | | | rewrite scripts/gen-gdbus-interfaces.sh to use ksh (#!/bin/sh) to cut down on inbox spam, also fixed prior bug where generated files had bad paths in their #includes. removed namespacing option from gdbus-codegen as linked objects do not run into naming conflicts as the previous commits did. regenerate all genfiles (src/interfaces/foo/foo-gen.{c.h}) accordingly.
* include gprintf.h in hostnamed.c/localed.c to allow strict compilationkremlin2014-07-152-0/+4
|
* cut out unnessecary #include's in main.c, prepare to deprecatekremlin2014-07-151-5/+0
| | | | | | we're going to move towards having all four daemons exist as seperate executables managed exclusively by DBus (startup, lifetime, etc.) so i'm moving towards getting rid of the one "main" executable.
* remove includes in non-gen'd interf files, they're linked properly nowkremlin2014-07-154-61/+48
| | | | | | | no need to include foo-gen.c as its functionality exists inside linked object built by makefile in future commit. additionally, make all non-generated interface files executable with a dummy main() that runs foo_init() after setting everything up properly with a g_main_loop
* untouched genfiles now work with linking system, revert localed-gen.ckremlin2014-07-151-0/+133
| | | | | | previously you needed to edit genfiles as to not re-implement boilerplate methods. linking (instead of #include'ing) avoids this and allows genfiles to work without edit, as intended.
* get rid of non-generated interface headers, we don't need themkremlin2014-07-154-66/+0
|
* get rid of ifdef maze in main.c, the binaries will be compiled sep.kremlin2014-07-151-32/+17
|
* set hostnamed's 'hostname' property before exportkremlin2014-07-111-1/+9
|
* more work on managing four interfaces as separate PIDs, new makefile rules ↵kremlin2014-07-083-30/+44
| | | | for building and installing standalone interface binaries, a little documentation and preproccessor logic
* (1) regenerate leaner genfiles, we're not using the object manager ↵kremlin2014-07-0812-2964/+195
| | | | functionality (2) modify gen-gdbus-interfaces to exclude object manager functionality (3) make localed skeleton (4) namespace hostnamed's and localed's bus/name functions properly (5) edit main.c to init localed
* regenerate proper namespaced code for other 3 interfaces, fix their includes ↵kremlin2014-07-086-3769/+6303
| | | | accordingly
* fix previous commit (forgot to escape newline), regenerate hostnamed with ↵kremlin2014-07-083-909/+909
| | | | proper namespace changes, fix hostnamed.c accordingly
* cut out old XML install cruftkremlin2014-07-033-110/+0
|
* (1) modify gen-gdbus-interfaces.sh to generate nessecary subclasseskremlin2014-07-023-3961/+788
| | | | | | (2) regenerate hostnamed genfiles accordingly (3) add in skeleton functions for handling hostnamed properties. (4) celebrate, as hostnamed.c now serves as a copyable skeleton for the other three
* (1) updated ispect xml to reflect recent undocumented changes in hostnamedkremlin2014-07-023-114/+5104
| | | | | (2) implemented skeleton functions for hostnamed, attached to interface which is now (3) exported on DBus properly as a generated GDBusInterfaceSkeleton
* retabkremlin2014-06-272-17/+17
|
* replace C++ style commentskremlin2014-06-273-8/+6
|
* cut out install code that should be handled in makefilekremlin2014-06-274-91/+33
|
* clean up config.ckremlin2014-06-261-63/+67
|
* drop persistent file handlers, use rc.d 'reload' insteadkremlin2014-06-261-30/+13
|
* more work on xml configuration setting..kremlin2014-06-262-69/+88
|
* minor, fix system call logickremlin2014-06-261-1/+1
|
* see previous commit, forgot 'git add'..kremlin2014-06-262-5/+8
|
* fix up merge conflicts to compile on strict settingskremlin2014-06-261-4/+4
|
* fixing merge conflictskremlin2014-06-262-15/+87
|
* merge license, hostname buffer changes from master branchkremlin2014-06-2611-195/+301
|\
| * change buffer size for gethostname() to HOST_NAME_MAX to avoid accidently ↵kremlin2014-06-224-122/+122
| | | | | | | | truncating the terminating byte on systems that handle gethostname() poorly
| * add license ISC license blurbskremlin2014-06-2211-0/+176
| |
* | goodnightkremlin2014-06-202-8/+101
| |
* | exit func for config, close()s and free()skremlin2014-06-201-2/+14
|/
* finish migrating old code to work with gdbus-codegen types, cleaned up ↵kremlin2014-06-204-78/+76
| | | | config IO/install, cleaned up code all-around to work with strict compiler flags
* blow away unnessecary errata whose functionality is covered by code from ↵kremlin2014-06-203-174/+25
| | | | generated interfaces, clean up code, conform better to GLib, bring in gio-unix-2.0
* prepare old hostnamed.c code for use through proper generated gdbus ↵kremlin2014-06-201-8/+16
| | | | interface code
* regenerate interface types, clean up gen scriptkremlin2014-06-208-0/+20100
|
* blow away improperly generated interface types (bad prefix)kremlin2014-06-208-20100/+0
|
* add gdbus-codegen fileskremlin2014-06-1711-3/+20100
|
* fleshed out config and hostnamed more, structure for other 3 daemons..kremlin2014-06-133-13/+124
|
* furthering hostnamed, begining configuration..kremlin2014-06-133-6/+142
|
* property handling...kremlin2014-06-101-5/+13
|
* export proper xml FINALLY..kremlin2014-06-103-21/+25
|
* cut out literalskremlin2014-06-101-55/+1
|
* blow away xmldefs, will read from file and checksum isntead...kremlin2014-06-101-446/+0
|
* started work on xml file installation/configurationkremlin2014-06-084-59/+532
|
* syncing...kremlin2014-06-082-1/+52
|
* syncing between computers..kremlin2014-06-052-11/+17
|
* minor info erratakremlin2014-06-051-0/+1
|
* divorce introspect xml to conf/ file, rm hostnamed.h, update system bus ↵kremlin2014-06-052-79/+0
| | | | config file to be more secure..
* syncing working files between computers...kremlin2014-06-051-6/+7
|
* added scripts to place config files, added a note in source about thatkremlin2014-06-031-1/+1
|
* minor, reference issuekremlin2014-06-031-2/+5
|
* syntax cleanup, add whatever .bin.core files are to gitignore..kremlin2014-06-031-50/+53
|
* divorce XML literal to hostnamed.h, update types to be glib-appropriate, ↵kremlin2014-06-032-110/+105
| | | | comments
* moved things around to make source readable, added comments, changed init ↵kremlin2014-06-031-9/+16
| | | | method return type from void -> GError
* update makefile and main.c to reflect changes of previous commit, also place ↵kremlin2014-06-031-1/+1
| | | | tempfile in bin/ as abscence causes git to ignore directory's existence
* remove crapfile, rename 'modules' -> 'interfaces'kremlin2014-06-034-0/+0
|
* hostnamed implementation coming along, implements introspectable now. had to ↵kremlin2014-05-302-15/+64
| | | | switch back to session bus temporarily...
* session bus -> system bus (hostnamed)kremlin2014-05-301-1/+1
|
* get OUTkremlin2014-05-302-0/+0
|
* get hostnamed to show up on session bus, incompletekremlin2014-05-304-7/+121
|
* begin hostnamed, clean upkremlin2014-05-284-10/+37
|
* set aside -ports makefile for now, we'll deal with it later. begin hostnamedkremlin2014-05-282-0/+7
|
* delete gnu makefile, revamp bsd makefilekremlin2014-05-221-0/+7
|
* moved src/*d -> src/modules/kremlin2014-05-224-0/+0
|
* move 4 utils into more-specific src/modules/, update README, docskremlin2014-05-204-0/+4