Changes between Version 6 and Version 7 of Docs/825gen2/Dev/Networking/NetworkPrintingCUPS


Ignore:
Timestamp:
01/15/24 11:10:44 (11 months ago)
Author:
Don Wilson
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Docs/825gen2/Dev/Networking/NetworkPrintingCUPS

    v6 v7  
    2424
    2525{{{
    26 card825gen2:/mnt/nfs/arm825_nand/bin$ /usr/sbin/lpinfo --include-schemes dnssd -v
    27 }}}
    28 
    29 
     26card825gen2:~$ /usr/sbin/lpinfo --include-schemes dnssd -v
     27network dnssd://Canon%20TX-3000._ipp._tcp.local/?uuid=00000000-0000-1000-8000-001832104e5a
     28network dnssd://Canon%20iPR%20Svr%20G250%20V2.1%20US(64%3A59%3AA5)._printer._tcp.local/
     29network dnssd://HP%20Designjet%20T520%2024in%20%5BD50233%5D._ipp._tcp.local/?uuid=abcd9e8e-4886-85c2-2167-b143d1c2344a
     30network dnssd://HP%20LaserJet%20P2055dn%20%5B82FCF4%5D._pdl-datastream._tcp.local/
     31network dnssd://Lexmark%20C2240._ipp._tcp.local/?uuid=584bdd81-d230-49f3-a210-d39ac56492d0
     32network dnssd://Lexmark%20C2240%20(3)._ipp._tcp.local/?uuid=925cc9ab-7f13-479a-9a82-d9d01aea2472
     33network dnssd://Lexmark%20C2240%20(4)._ipp._tcp.local/?uuid=1fb63094-a36c-42e5-885e-ce8ebf5c7e0d
     34network dnssd://Lexmark%20C2240%20(5)._ipp._tcp.local/?uuid=1cf2ae75-abe6-4bf3-b009-375e604a00a2
     35network dnssd://Lexmark%20C2240%20(6)._ipp._tcp.local/?uuid=04698d71-023d-4da8-a3f5-97d428aea12b
     36network dnssd://Lexmark%20C2240%20(7)._ipp._tcp.local/?uuid=1b72d98c-8ea0-4b33-a08d-78a89dc256e3
     37network dnssd://Lexmark%20M3150%20(2)._ipp._tcp.local/?uuid=4b9218da-71a9-42cb-858c-e478817ceb19
     38network dnssd://Lexmark%20M3250._ipp._tcp.local/?uuid=d672042b-7909-47a2-9077-968f58ad923b
     39network dnssd://Lexmark%20M3250%20(10)._ipp._tcp.local/?uuid=29fa91fd-eada-4cbe-bd5d-87fdb24dd92d
     40network dnssd://Lexmark%20M3250%20(14)._ipp._tcp.local/?uuid=67390cc9-aad3-4041-b32d-d5a235d89a39
     41network dnssd://Lexmark%20M3250%20(2)._ipp._tcp.local/?uuid=876e7e06-54ab-4ca6-a4a6-a80e70f602b5
     42network dnssd://Lexmark%20M3250%20(3)._ipp._tcp.local/?uuid=50249be5-e50d-4f1a-8739-38ee1f618bd8
     43network dnssd://Lexmark%20M3250%20(34)._ipp._tcp.local/?uuid=fd53b6a6-3442-4613-921c-2e439ce37d33
     44network dnssd://Lexmark%20M3250%20(4)._ipp._tcp.local/?uuid=86020859-dbe1-45ad-bdf7-e82dc489e1d5
     45network dnssd://Lexmark%20M3250%20(5)._ipp._tcp.local/?uuid=e9bc03ef-9a4c-4d84-ad46-8c627e414175
     46network dnssd://Lexmark%20M3250%20(6)._ipp._tcp.local/?uuid=802f250b-fa5b-43a3-a843-1e8ba23189fa
     47network dnssd://Lexmark%20M3250%20(8)._ipp._tcp.local/?uuid=b56cbbbe-2d78-4ef3-9b7a-297a6237f84d
     48network dnssd://Lexmark%20MS510dn._ipp._tcp.local/?uuid=badd5f81-578d-4e6e-8aa0-715bf8e224b3
     49network dnssd://Lexmark%20MS510dn%20(10)._ipp._tcp.local/?uuid=588460cb-d756-4d87-9239-9d8e910784e2
     50network dnssd://Lexmark%20MS510dn%20(12)._ipp._tcp.local/?uuid=22ef395a-2897-4d8d-87de-061f52436e50
     51network dnssd://Lexmark%20MS510dn%20(13)._ipp._tcp.local/?uuid=127f7806-f38e-497d-b053-f4e3137d11e0
     52network dnssd://Lexmark%20MS510dn%20(5)._ipp._tcp.local/?uuid=7736e5dc-2015-417e-a637-7bc3c023ebb5
     53network dnssd://Lexmark%20MS510dn%20(8)._ipp._tcp.local/?uuid=279c0534-9d92-4a33-afb5-8df038e3aa63
     54network dnssd://Lexmark%20MX811._ipp._tcp.local/?uuid=13ffc623-6864-4b67-8ab0-c8e8d827ebd8
     55network dnssd://Lexmark%20MX811%20(2)._ipp._tcp.local/?uuid=c9b81317-aa68-45b6-a702-09fab9d329d0
     56network dnssd://Lexmark%20XM3250%20(2)._ipp._tcp.local/?uuid=641a82cd-4fcf-4b91-9a7a-de09460059f7
     57network dnssd://Lexmark%20XM3250%20(3)._ipp._tcp.local/?uuid=c0bf69ec-fc3e-43e8-9b9c-61711fecbd34
     58network dnssd://Lexmark%20XM5365._ipp._tcp.local/?uuid=d0c8af1e-9fd8-4c37-8ba1-b9419d1087d0
     59network dnssd://SERVER-59A5._ipp._tcp.local/
     60network dnssd://SHARP%20MX-C304W%20(9300735300)._printer._tcp.local/
     61network dnssd://VS-300i%40RDG7F157A%20(92)._printer._tcp.local/
     62}}}
     63
     64CUPS management web pages.
     65
     66To allow access to the management pages on local network the cupsd.conf file must be edited.
     67
     68{{{
     69nano /etc/cups/cupsd.conf
     70}}}
     71
     72{{{
     73#
     74# Configuration file for the CUPS scheduler.  See "man cupsd.conf" for a
     75# complete description of this file.
     76#
     77
     78# Log general information in error_log - change "warn" to "debug"
     79# for troubleshooting...
     80LogLevel warn
     81PageLogFormat
     82
     83# Specifies the maximum size of the log files before they are rotated.  The value "0" disables log rotation.
     84MaxLogSize 1m
     85
     86# Default error policy for printers
     87ErrorPolicy stop-printer
     88
     89# Only listen for connections from the local machine.
     90#Listen localhost:631
     91Port 631
     92Listen /run/cups/cups.sock
     93
     94# Show shared printers on the local network.
     95Browsing Yes
     96BrowseLocalProtocols dnssd
     97
     98# Default authentication type, when authentication is required...
     99DefaultAuthType Basic
     100
     101# Web interface setting...
     102WebInterface Yes
     103
     104# Timeout after cupsd exits if idle (applied only if cupsd runs on-demand - with -l)
     105IdleExitTimeout 60
     106
     107# Restrict access to the server...
     108<Location />
     109  Order allow,deny
     110  Allow @local
     111</Location>
     112
     113# Restrict access to the admin pages...
     114<Location /admin>
     115  Order allow,deny
     116  Allow @local
     117</Location>
     118
     119# Restrict access to configuration files...
     120<Location /admin/conf>
     121  AuthType Default
     122  Require user @SYSTEM
     123  Order allow,deny
     124  Allow @local
     125</Location>
     126
     127# Restrict access to log files...
     128<Location /admin/log>
     129  AuthType Default
     130  Require user @SYSTEM
     131  Order allow,deny
     132  Allow @local
     133</Location>
     134
     135# Set the default printer/job policies...
     136<Policy default>
     137  # Job/subscription privacy...
     138  JobPrivateAccess default
     139  JobPrivateValues default
     140  SubscriptionPrivateAccess default
     141  SubscriptionPrivateValues default
     142
     143  # Job-related operations must be done by the owner or an administrator...
     144  <Limit Create-Job Print-Job Print-URI Validate-Job>
     145    Order deny,allow
     146  </Limit>
     147
     148  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
     149    Require user @OWNER @SYSTEM
     150    Order deny,allow
     151  </Limit>
     152
     153  # All administration operations require an administrator to authenticate...
     154  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
     155    AuthType Default
     156    Require user @SYSTEM
     157    Order deny,allow
     158  </Limit>
     159
     160  # All printer operations require a printer operator to authenticate...
     161  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
     162    AuthType Default
     163    Require user @SYSTEM
     164    Order deny,allow
     165  </Limit>
     166
     167  # Only the owner or an administrator can cancel or authenticate a job...
     168  <Limit Cancel-Job CUPS-Authenticate-Job>
     169    Require user @OWNER @SYSTEM
     170    Order deny,allow
     171  </Limit>
     172
     173  <Limit All>
     174    Order deny,allow
     175  </Limit>
     176</Policy>
     177
     178# Set the authenticated printer/job policies...
     179<Policy authenticated>
     180  # Job/subscription privacy...
     181  JobPrivateAccess default
     182  JobPrivateValues default
     183  SubscriptionPrivateAccess default
     184  SubscriptionPrivateValues default
     185
     186  # Job-related operations must be done by the owner or an administrator...
     187  <Limit Create-Job Print-Job Print-URI Validate-Job>
     188    AuthType Default
     189    Order deny,allow
     190  </Limit>
     191
     192  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
     193    AuthType Default
     194    Require user @OWNER @SYSTEM
     195    Order deny,allow
     196  </Limit>
     197
     198  # All administration operations require an administrator to authenticate...
     199  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
     200    AuthType Default
     201    Require user @SYSTEM
     202    Order deny,allow
     203  </Limit>
     204
     205  # All printer operations require a printer operator to authenticate...
     206  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
     207    AuthType Default
     208    Require user @SYSTEM
     209    Order deny,allow
     210  </Limit>
     211
     212  # Only the owner or an administrator can cancel or authenticate a job...
     213  <Limit Cancel-Job CUPS-Authenticate-Job>
     214    AuthType Default
     215    Require user @OWNER @SYSTEM
     216    Order deny,allow
     217  </Limit>
     218
     219  <Limit All>
     220    Order deny,allow
     221  </Limit>
     222</Policy>
     223
     224# Set the kerberized printer/job policies...
     225<Policy kerberos>
     226  # Job/subscription privacy...
     227  JobPrivateAccess default
     228  JobPrivateValues default
     229  SubscriptionPrivateAccess default
     230  SubscriptionPrivateValues default
     231
     232  # Job-related operations must be done by the owner or an administrator...
     233  <Limit Create-Job Print-Job Print-URI Validate-Job>
     234    AuthType Negotiate
     235    Order deny,allow
     236  </Limit>
     237
     238  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
     239    AuthType Negotiate
     240    Require user @OWNER @SYSTEM
     241    Order deny,allow
     242  </Limit>
     243
     244  # All administration operations require an administrator to authenticate...
     245  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
     246    AuthType Default
     247    Require user @SYSTEM
     248    Order deny,allow
     249  </Limit>
     250
     251  # All printer operations require a printer operator to authenticate...
     252  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
     253    AuthType Default
     254    Require user @SYSTEM
     255    Order deny,allow
     256  </Limit>
     257
     258  # Only the owner or an administrator can cancel or authenticate a job...
     259  <Limit Cancel-Job CUPS-Authenticate-Job>
     260    AuthType Negotiate
     261    Require user @OWNER @SYSTEM
     262    Order deny,allow
     263  </Limit>
     264
     265  <Limit All>
     266    Order deny,allow
     267  </Limit>
     268</Policy>
     269}}}
     270
     271The line localhost:631 limits access so that only the page could only be accessed from the 825 itself. Commented this out be placing # in front and added line Port 631 below it.
     272
     273Added Allow @local just above each of the four </Location> lines.
     274
     275Then restart the cups service
     276{{{
     277sudo systemctl restart cups
     278}}}