Comparar commits

..

97 Commits

Autor SHA1 Mensagem Data
Michael Sweet e52ed6e0a7 Bump versions. 2016-06-14 13:45:32 -04:00
Michael Sweet d2d26087df Fix typos and remove more files from tarballs. 2016-06-14 13:41:39 -04:00
Michael Sweet 29ff85270e Mirror updates to makesrcdist script. 2016-06-14 13:36:37 -04:00
Michael Sweet 6bde932e8a Changelog. 2016-06-08 14:54:28 -04:00
Michael Sweet 8cae1ac9af Mirror fix from master. 2016-06-08 14:52:57 -04:00
Michael Sweet 91480df95e Mirror fix from master. 2016-05-30 19:11:07 -04:00
Michael Sweet f626646001 Mirror fix from master. 2016-05-11 11:25:56 -04:00
Michael Sweet a0e8526903 Mirror fix from master. 2016-05-11 10:39:23 -04:00
Michael R Sweet f94124cb92 Mirror fix from master. 2016-03-24 18:00:11 -04:00
Michael R Sweet 840c1efb00 Mirror fix from master. 2016-03-24 17:51:13 -04:00
Michael R Sweet 344ab3b0e2 Mirror fix from master. 2016-03-24 17:45:54 -04:00
Michael R Sweet 0d6f0677c3 Ignore patches directory. 2016-03-24 17:35:56 -04:00
Michael R Sweet 60f4a67a67 Mirror fix from master. 2016-03-24 17:30:24 -04:00
Michael R Sweet 0417631599 Mirror fix from master. 2016-03-24 17:27:37 -04:00
Michael R Sweet 4cc64a80fd Mirror fix from master. 2016-03-24 17:19:51 -04:00
Michael Sweet 8056da7897 Ignore all generated files. 2016-03-15 12:20:25 -04:00
Michael Sweet b1f200bb75 Merge branch 'branch-2.1' of https://github.com/michaelrsweet/cups into branch-2.1 2016-03-15 10:54:13 -04:00
Michael Sweet 6355478e27 Pull in changes from CUPS 2.1svn-r13137 2016-03-15 10:45:51 -04:00
Michael Sweet ba4f314f2b Import CUPS v2.1.3 2016-03-15 10:43:33 -04:00
Michael Sweet d3331249b0 Import CUPS v2.1.2 2016-03-15 10:43:30 -04:00
Michael Sweet bc05464ada Import CUPS v2.1.1 2016-03-15 10:43:26 -04:00
msweet 71389998b8 Prep for 1.7.5 release.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12068 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-31 00:25:50 +00:00
msweet 72265b0595 Update the Brazilian Portuguese translation (STR #4456)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12061 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-28 14:07:21 +00:00
msweet 9825762812 Mirror change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12060 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-28 14:04:41 +00:00
msweet d40220801e Mirror changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12057 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-22 14:03:19 +00:00
msweet 3d1f41307e Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12052 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-18 20:37:49 +00:00
msweet fbd45c3e08 Mirror fix from trunk for STR #4452.
Bump version to 1.7.5.


git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12025 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-15 13:00:17 +00:00
msweet 873a628b1c Fix broken links (STR #4453)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12010 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-09 17:08:37 +00:00
msweet 023692e684 Fix build problem (oops).
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12009 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-09 17:02:38 +00:00
msweet 308c21ef44 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@12005 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-08 15:46:59 +00:00
msweet 244a10b5c8 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11998 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-03 14:47:50 +00:00
msweet 031f71f0a8 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11995 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-03 14:38:52 +00:00
msweet c4df903b2d Changelog.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11979 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-02 10:36:23 +00:00
msweet 6b139a7e91 Mirror the libdispatch change from trunk (STR #4397)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11978 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-02 10:35:09 +00:00
msweet 105d3c6459 Mirror changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11971 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-07-01 14:38:29 +00:00
msweet 309e860e17 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11951 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-24 19:08:36 +00:00
msweet d15d70899b Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11948 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-24 18:43:27 +00:00
msweet 101de55370 The RPM spec file did not work due to the new Brazilian Portuguese localization
(STR #4436)



git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11946 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-24 18:01:58 +00:00
msweet 7d6c76f898 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11932 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-16 16:13:06 +00:00
msweet 73e83483db Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11915 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-10 19:48:58 +00:00
msweet 0151d6018c Prep for 1.7.4 release.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11910 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-10 13:42:11 +00:00
msweet 0360d41094 Mirror fixes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11909 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-09 18:58:16 +00:00
msweet 73f741aebc Really mirror fix for STR #4402 (compile problem) that wasn't picked up
(STR #4424)


git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11906 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-06-09 18:33:24 +00:00
msweet dca2386d81 Ignore generated Portuguese files.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11900 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-27 18:29:48 +00:00
msweet c8111ca923 Fix build error with GNU TLS (deprecated types)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11899 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-27 15:10:09 +00:00
msweet 62f67a21cc Update docos.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11898 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-27 15:08:42 +00:00
msweet d7915e0baf Mirror fixes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11897 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-27 15:02:42 +00:00
msweet 6a16dd94b9 Mirror changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11890 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-22 13:59:21 +00:00
msweet 2bc3c8e63d Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11883 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-16 21:04:07 +00:00
msweet 0d44b6f9a4 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11875 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-13 14:57:48 +00:00
msweet 8f7630cffc Add Brazilian Portuguese translation (STR #4409)
Mirror other changes from trunk.


git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11867 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-09 20:33:08 +00:00
msweet e3c4c55263 Merge changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11864 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-08 23:10:47 +00:00
msweet bf5fce9867 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11862 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-05-08 23:01:48 +00:00
msweet 306d87d977 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11833 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-04-24 15:04:15 +00:00
msweet 5638753fdf New changes are for 1.7.3.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11812 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-04-10 15:47:53 +00:00
msweet 9f8ca40773 Prep for 1.7.2 release.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11809 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-04-10 15:18:44 +00:00
msweet 5415d8c212 Fix packaging issue for 1.7.2.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11808 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-04-10 15:11:43 +00:00
msweet 22c761b4a8 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11779 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 20:48:44 +00:00
msweet ce8b298254 Mirror cupsfilter fix from trunk to read from cups-files.conf instead.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11772 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 15:08:30 +00:00
msweet ca0c126882 Fix builds on OS X with Xcode 5.x.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11767 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 13:52:05 +00:00
msweet e7d39d5957 Changelog.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11766 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 13:51:54 +00:00
msweet 36a710dd8a One more fix for STR #4358, otherwise we'll leak the SSPI data for each
connection.


git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11761 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 13:04:33 +00:00
msweet 8c535064f7 Fix SSL support on Windows (STR #4358)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11760 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-28 12:58:24 +00:00
msweet 6c019649f4 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11759 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-27 20:57:33 +00:00
msweet 94f7cfc5d0 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11756 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-27 17:06:25 +00:00
msweet 962493c168 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11745 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-26 21:17:02 +00:00
msweet ea1500e49d Fix early 200 response bug.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11739 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-26 21:06:04 +00:00
msweet ef80c6e4e9 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11734 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-25 18:01:47 +00:00
msweet 0d66577b2d Fix compiled on Linux.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11721 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-21 18:18:56 +00:00
msweet 90af1dd8be Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11707 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-19 18:38:23 +00:00
msweet 16a3c06507 Fix builds on Windows.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11689 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-05 21:22:12 +00:00
msweet 98c6e426bc Mirror changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11688 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-05 21:11:32 +00:00
msweet 40457f6cc5 Mirror fixes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11684 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-05 20:01:48 +00:00
msweet f4d45889eb Fix the Japanese localization (STR #4385)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11678 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-05 18:34:26 +00:00
msweet 588cfd8b22 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11675 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-05 12:53:37 +00:00
msweet 0e27be7747 Mirror change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11670 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-03-04 14:53:59 +00:00
msweet 03163319af Mirror change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11654 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-28 17:19:58 +00:00
msweet 87473b5777 Mirror change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11650 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-27 17:06:15 +00:00
msweet 72f8a73af8 Add German localization (STR #4363)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11643 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-27 15:58:35 +00:00
msweet 35929e590c Mirror changes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11642 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-27 15:57:59 +00:00
msweet 1576ab1c78 Mirror fixes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11623 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-19 20:18:10 +00:00
msweet 104ec216a3 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11614 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-19 16:49:47 +00:00
msweet 7c399480cd Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11588 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-02-13 19:49:59 +00:00
msweet c09f64e2f3 Mirror fixes from trunk.
Bump version to 1.7.2.


git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11551 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-29 16:31:35 +00:00
msweet 2106cc63ca Mirror change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11520 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-08 16:37:04 +00:00
msweet 2f96aa3b41 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11516 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-08 16:24:32 +00:00
msweet 1bd4599421 Update versions and dates.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11513 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-08 16:15:07 +00:00
msweet d780a217b3 Update copyright.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11511 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-08 16:05:54 +00:00
msweet 42cf2f9f2e Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11510 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-08 16:00:25 +00:00
msweet 530f64721a Mirror fixes from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11500 a1ca3aef-8c08-0410-bb20-df032aa958be
2014-01-06 22:21:15 +00:00
msweet 8a2e36146f Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11495 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-22 05:29:16 +00:00
msweet d67e4b67b2 Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11491 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-22 05:18:05 +00:00
msweet cd5ce0053e Mirror fix from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11488 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-22 05:04:41 +00:00
msweet a20f5c90aa Mirror fix for STR #4319.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11485 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-22 00:44:35 +00:00
msweet 1110e39948 Mirror CMP change from trunk.
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11473 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-19 16:42:37 +00:00
msweet 6aa0a54981 The libusb-based USB backend incorrectly used write timeouts
(<rdar://problem/15564888>)



git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11456 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-09 19:26:47 +00:00
msweet e1de635a20 Fix tel: URIs (<rdar://problem/15418463>)
git-svn-id: svn+ssh://src.apple.com/svn/cups/cups.org/branches/branch-1.7@11445 a1ca3aef-8c08-0410-bb20-df032aa958be
2013-12-05 19:57:43 +00:00
153 arquivos alterados com 12676 adições e 1061 exclusões
+144
Ver Arquivo
@@ -0,0 +1,144 @@
*.a
*.cgi
*.dylib
*.gz
*.o
*.so
*.so.*
.buildrev
autom4te.cache
config.h
config.log
config.status
cups-config
Makedefs
backend/dnssd
backend/http
backend/ipp
backend/lpd
backend/mdns
backend/snmp
backend/socket
backend/test1284
backend/testbackend
backend/testsupplies
backend/usb
berkeley/lpc
berkeley/lpq
berkeley/lpr
berkeley/lprm
cgi-bin/testcgi
cgi-bin/testhi
cgi-bin/testhi.index
cgi-bin/testtemplate
conf/cups-files.conf
conf/cupsd.conf
conf/mime.convs
conf/pam.std
conf/snmp.conf
cups/locale/
cups/test.pwg
cups/testadmin
cups/testarray
cups/testcache
cups/testconflicts
cups/testcups
cups/testdest
cups/testfile
cups/testhttp
cups/testi18n
cups/testipp
cups/testlang
cups/testoptions
cups/testppd
cups/testpwg
cups/testsnmp
cups/tlscheck
desktop/cups.desktop
doc/index.html
filter/commandtops
filter/gziptoany
filter/pstops
filter/rasterbench
filter/rastertoepson
filter/rastertohp
filter/rastertolabel
filter/rastertopwg
filter/test.raster
filter/testraster
locale/checkpo
locale/po2strings
locale/strings2po
man/client.conf.man
man/cups-files.conf.man
man/cups-lpd.man
man/cups-snmp.man
man/cupsaddsmb.man
man/cupsd.conf.man
man/cupsd.man
man/lpoptions.man
man/mantohtml
monitor/bcp
monitor/tbcp
notifier/mailto
notifier/rss
notifier/testnotify
packaging/cups.list
patches
ppdc/genstrings
ppdc/ppd/
ppdc/ppd2/
ppdc/ppdc
ppdc/ppdc-static
ppdc/ppdhtml
ppdc/ppdi
ppdc/ppdi-static
ppdc/ppdmerge
ppdc/ppdpo
ppdc/sample-import.drv
ppdc/sample.c
ppdc/testcatalog
scheduler/convert
scheduler/cups-deviced
scheduler/cups-driverd
scheduler/cups-exec
scheduler/cups-lpd
scheduler/cups-lpd.xinetd
scheduler/cups.sh
scheduler/cups.xml
scheduler/cupsd
scheduler/cupsfilter
scheduler/org.cups.cups-lpd.plist
scheduler/org.cups.cups-lpdAT.service
scheduler/org.cups.cupsd.path
scheduler/org.cups.cupsd.service
scheduler/org.cups.cupsd.socket
scheduler/testlpd
scheduler/testmime
scheduler/testspeed
scheduler/testsub
systemv/accept
systemv/cancel
systemv/cupsaccept
systemv/cupsaddsmb
systemv/cupsctl
systemv/cupsdisable
systemv/cupsenable
systemv/cupsreject
systemv/cupstestdsc
systemv/cupstestppd
systemv/lp
systemv/lpadmin
systemv/lpinfo
systemv/lpmove
systemv/lpoptions
systemv/lpstat
systemv/reject
templates/header.tmpl
test/cups-str-*.html
test/error_log-*
test/ippfind
test/ippfind-static
test/ippserver
test/ipptool
test/ipptool-static
+101 -26
Ver Arquivo
@@ -1,35 +1,110 @@
CHANGES.txt - 2.1.0 - 2015-08-31
CHANGES.txt - 2.1.4 - 2016-06-14
--------------------------------
CHANGES IN CUPS V2.1.4
- Fixed reporting of 1284 Device IDs (Issue #3835, PR #3836)
- Fixed printing of multiple files to raw queues (Issue #4782)
- The scheduler did not implement the Hold-New-Jobs opertion correctly
(Issue #4767)
- The ipptool program truncated values at 8k (Issue #4786)
- The ipptool program did not correctly report uriScheme values in plist
output (Issue #4785)
- The cups-lpd mini-daemon incorrectly included the document-name
attribute when creating a job. It should only be included when
sending a job (Issue #4790)
- USB quirk updates (Issue #4778, Issue #4789)
- Documentation update (Issue #4772)
CHANGES IN CUPS V2.1.3
- The default password function did not work on some platforms
(Issue #4750)
- The scheduler should not exit under memory pressure
(<rdar://problem/23255001>)
- The EPL2 and ZPL sample drivers did not properly support the CutMedia
option.
- Pending subscriptions would prevent the scheduler from idle exiting
(Issue #4754)
- Fixed some issues in ipptool for skipped tests
(<rdar://problem/24137160>)
- The "lp -H resume" command did not reset the "job-state-reasons"
attribute value (Issue #4752)
- The scheduler did not allow access to resource files (icons, etc.)
when the web interface was disabled (Issue #4755)
- Localization fix (Issue #4756)
CHANGES IN CUPS V2.1.2
- Re-release of CUPS 2.1.1 as CUPS 2.1.2 due to error in tagging of the
2.1.1 release (pulled content from the 2.2.x tree instead)
CHANGES IN CUPS V2.1.1
- Security hardening fixes (<rdar://problem/23131948>,
<rdar://problem/23132108>, <rdar://problem/23132353>,
<rdar://problem/23132803>, <rdar://problem/23133230>,
<rdar://problem/23133393>, <rdar://problem/23133466>,
<rdar://problem/23133833>, <rdar://problem/23133998>,
<rdar://problem/23134228>, <rdar://problem/23134299>,
<rdar://problem/23134356>, <rdar://problem/23134415>,
<rdar://problem/23134506>, <rdar://problem/23135066>,
<rdar://problem/23135122>, <rdar://problem/23135207>,
<rdar://problem/23144290>, <rdar://problem/23144358>,
<rdar://problem/23144461>)
- The cupsGetPPD* functions did not work with IPP printers (Issue #4725)
- Some older HP LaserJet printers need a delayed close when printing
using the libusb-based USB backend (Issue #4549)
- The libusb-based USB backend did not unload the kernel usblp module
if it was preventing the backend from accessing the printer
(Issue #4707)
- Current Primera printers were incorrectly reported as Fargo printers
(Issue #4708)
- The IPP backend did not always handle jobs getting canceled at the
printer (<rdar://problem/22716820>)
- Scheduler logging change (Issue #4728)
- Added USB quirk for Canon MP530 (Issue #4730)
- The scheduler did not deliver job notifications for jobs submitted to
classes (Issue #4733)
- Changing the printer-is-shared value for a remote queue did not
produce an error (Issue #4738)
- The IPP backend incorrectly included the job-password attribute in
Validate-Job requests (<rdar://problem/23531939>)
- Updated localizations (Issue #4709)
CHANGES IN CUPS V2.1.0
- Fixed more scheduler crash bugs in the new logging code (STR #4687,
STR #4690)
- Fixed more scheduler crash bugs in the new logging code (Issue #4687,
Issue #4690)
- The scheduler did not use the ConfigFilePerm setting when copying PPD
files or interface scripts attached to a request (STR #4703)
files or interface scripts attached to a request (Issue #4703)
- Now support new Chinese locale IDs and their correct fallback locales
(<rdar://problem/22086642>, <rdar://problem/22130168>)
- "make check" incorrectly reported an expectation of 18 warning
messages when 8 were expected (STR #4684)
- The new PDF file type rule did not work (STR #4692)
messages when 8 were expected (Issue #4684)
- The new PDF file type rule did not work (Issue #4692)
- The scheduler did not update the jobs.cache file when job files were
expired (STR #4706)
- Fixed some configure script issues (STR #4694, STR #4695, STR #4698)
- Documentation updates (STR #4691, STR #4693)
expired (Issue #4706)
- Fixed some configure script issues (Issue #4694, Issue #4695, Issue #4698)
- Documentation updates (Issue #4691, Issue #4693)
CHANGES IN CUPS V2.1rc1
- Added support for 3D printers (basic types only, no built-in filters)
based on PWG white paper.
- Fixed bugs in the new journald support (STR #4655, STR #4658,
STR #4661)
- Fixed domain socket support on Linux (STR #4679)
- Fixed signal handlers in the dnssd and usb backends (STR #4671)
- Fixed bugs in the new journald support (Issue #4655, Issue #4658,
Issue #4661)
- Fixed domain socket support on Linux (Issue #4679)
- Fixed signal handlers in the dnssd and usb backends (Issue #4671)
- <Limit All> in <Policy> sections now applies to all operations when
used by itself (STR #4659)
- Configure script changes for systemd support (STR #4669)
- Updated autoconf sources to use newer form of AC_INIT (STR #4664)
used by itself (Issue #4659)
- Configure script changes for systemd support (Issue #4669)
- Updated autoconf sources to use newer form of AC_INIT (Issue #4664)
CHANGES IN CUPS V2.1b1
@@ -44,30 +119,30 @@ CHANGES IN CUPS V2.1b1
- The IPP backend now updates the cupsMandatory values when the printer
configuration changes (<rdar://problem/18126570>)
- No longer install banner files since third-party banner filters now
supply their own (STR #4518)
supply their own (Issue #4518)
- Added support for EXPECT-ALL directive in ipptool test files
(STR #4469)
(Issue #4469)
- Added support for WITH-VALUE-FROM predicate in ipptool test files
(STR #4470)
(Issue #4470)
- The scheduler no longer listens on the loopback interface unless the
web interface or printer sharing are enabled
(<rdar://problem/9136448>)
- Added a PPD generator for IPP Everywhere printers (STR #4258)
- Added a PPD generator for IPP Everywhere printers (Issue #4258)
- Now install "default" versions of more configuration files
(<rdar://problem/19024491>)
- The cupstestppd program did not handle "maxsize(nnn)" entries in
cupsFilter/cupsFilter2 values (<rdar://problem/18974858>)
- The scheduler now checks the return value of rename() calls
(STR #4589)
(Issue #4589)
- The scheduler now validates ErrorPolicy values in config files
(STR #4591)
- Long cookies caused the web interface to stop working (STR #4619)
(Issue #4591)
- Long cookies caused the web interface to stop working (Issue #4619)
- Added SSLOptions values to allow Diffie-Hellman key exchange and
disable TLS/1.0 support.
- Updated the scheduler to support more IPP Everywhere attributes
(STR #4630)
(Issue #4630)
- The scheduler now supports advanced ASL and journald logging when
"syslog" output is configured (STR #4474)
"syslog" output is configured (Issue #4474)
- The scheduler now supports logging to stderr when running in the
foreground (STR #4505)
foreground (Issue #4505)
+1 -1
Ver Arquivo
@@ -1,4 +1,4 @@
INSTALL - CUPS v2.1.0 - 2015-08-31
INSTALL - CUPS v2.1.4 - 2016-06-14
----------------------------------
This file describes how to compile and install CUPS from source code. For more
+2 -2
Ver Arquivo
@@ -1,4 +1,4 @@
README - CUPS v2.1.0 - 2015-08-31
README - CUPS v2.1.4 - 2016-06-14
---------------------------------
Looking for compile instructions? Read the file "INSTALL.txt" instead...
@@ -140,7 +140,7 @@ PRINTING FILES
LEGAL STUFF
CUPS is Copyright 2007-2015 by Apple Inc. CUPS and the CUPS logo are
CUPS is Copyright 2007-2016 by Apple Inc. CUPS and the CUPS logo are
trademarks of Apple Inc.
The MD5 Digest code is Copyright 1999 Aladdin Enterprises.
+6 -14
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: dnssd.c 12818 2015-07-31 13:29:25Z msweet $"
* "$Id: dnssd.c 12970 2015-11-13 20:02:51Z msweet $"
*
* DNS-SD discovery backend for CUPS.
*
@@ -921,13 +921,6 @@ get_device(cups_array_t *devices, /* I - Device array */
* Yes, add the device...
*/
#ifdef HAVE_DNSSD
DNSServiceConstructFullName(fullName, serviceName, regtype, replyDomain);
#else /* HAVE_AVAHI */
avahi_service_name_join(fullName, kDNSServiceMaxDomainName,
serviceName, regtype, replyDomain);
#endif /* HAVE_DNSSD */
device = calloc(sizeof(cups_device_t), 1);
device->name = strdup(serviceName);
device->domain = strdup(replyDomain);
@@ -943,8 +936,7 @@ get_device(cups_array_t *devices, /* I - Device array */
#ifdef HAVE_DNSSD
DNSServiceConstructFullName(fullName, serviceName, regtype, replyDomain);
#else /* HAVE_AVAHI */
avahi_service_name_join(fullName, kDNSServiceMaxDomainName,
serviceName, regtype, replyDomain);
avahi_service_name_join(fullName, kDNSServiceMaxDomainName, serviceName, regtype, replyDomain);
#endif /* HAVE_DNSSD */
device->fullName = strdup(fullName);
@@ -1202,9 +1194,9 @@ query_callback(
snprintf(device_id, sizeof(device_id), "MFG:%s;MDL:%s;",
make_and_model, model);
else if (!_cups_strncasecmp(model, "designjet ", 10))
snprintf(device_id, sizeof(device_id), "MFG:HP;MDL:%s", model + 10);
snprintf(device_id, sizeof(device_id), "MFG:HP;MDL:%s;", model + 10);
else if (!_cups_strncasecmp(model, "stylus ", 7))
snprintf(device_id, sizeof(device_id), "MFG:EPSON;MDL:%s", model + 7);
snprintf(device_id, sizeof(device_id), "MFG:EPSON;MDL:%s;", model + 7);
else if ((ptr = strchr(model, ' ')) != NULL)
{
/*
@@ -1214,7 +1206,7 @@ query_callback(
memcpy(make_and_model, model, (size_t)(ptr - model));
make_and_model[ptr - model] = '\0';
snprintf(device_id, sizeof(device_id), "MFG:%s;MDL:%s",
snprintf(device_id, sizeof(device_id), "MFG:%s;MDL:%s;",
make_and_model, ptr + 1);
}
}
@@ -1330,5 +1322,5 @@ unquote(char *dst, /* I - Destination buffer */
/*
* End of "$Id: dnssd.c 12818 2015-07-31 13:29:25Z msweet $".
* End of "$Id: dnssd.c 12970 2015-11-13 20:02:51Z msweet $".
*/
+24 -6
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: ipp.c 12757 2015-06-24 19:55:31Z msweet $"
* "$Id: ipp.c 12896 2015-10-09 13:15:22Z msweet $"
*
* IPP backend for CUPS.
*
@@ -1800,7 +1800,7 @@ main(int argc, /* I - Number of command-line args */
fprintf(stderr, "DEBUG: Send-Document: %s (%s)\n",
ippErrorString(cupsLastError()), cupsLastErrorString());
if (cupsLastError() > IPP_OK_CONFLICT)
if (cupsLastError() > IPP_OK_CONFLICT && !job_canceled)
{
ipp_status = cupsLastError();
@@ -1818,6 +1818,9 @@ main(int argc, /* I - Number of command-line args */
}
}
if (job_canceled)
break;
if (ipp_status <= IPP_OK_CONFLICT && argc > 6)
{
fprintf(stderr, "PAGE: 1 %d\n", copies_sup ? atoi(argv[4]) : 1);
@@ -2444,6 +2447,17 @@ monitor_printer(
}
}
fprintf(stderr, "DEBUG: (monitor) job-state = %s\n",
ippEnumString("job-state", monitor->job_state));
if (!job_canceled &&
(monitor->job_state == IPP_JOB_CANCELED ||
monitor->job_state == IPP_JOB_ABORTED))
{
job_canceled = -1;
fprintf(stderr, "DEBUG: (monitor) job_canceled = -1\n");
}
if ((attr = ippFindAttribute(response, "job-state-reasons",
IPP_TAG_KEYWORD)) != NULL)
{
@@ -2465,7 +2479,8 @@ monitor_printer(
new_reasons |= _CUPS_JSR_JOB_PASSWORD_WAIT;
else if (!strcmp(attr->values[i].string.text, "job-release-wait"))
new_reasons |= _CUPS_JSR_JOB_RELEASE_WAIT;
else if (!strncmp(attr->values[i].string.text, "job-canceled-", 13) || !strcmp(attr->values[i].string.text, "aborted-by-system"))
if (!job_canceled &&
(!strncmp(attr->values[i].string.text, "job-canceled-", 13) || !strcmp(attr->values[i].string.text, "aborted-by-system")))
job_canceled = 1;
}
@@ -2492,7 +2507,7 @@ monitor_printer(
ippDelete(response);
fprintf(stderr, "DEBUG: (monitor) job-state=%s\n",
fprintf(stderr, "DEBUG: (monitor) job-state = %s\n",
ippEnumString("job-state", monitor->job_state));
if (!job_canceled &&
@@ -2530,7 +2545,10 @@ monitor_printer(
monitor->user, monitor->version);
if (cupsLastError() > IPP_OK_CONFLICT)
{
fprintf(stderr, "DEBUG: (monitor) cancel_job() = %s\n", cupsLastErrorString());
_cupsLangPrintFilter(stderr, "ERROR", _("Unable to cancel print job."));
}
}
}
@@ -3258,7 +3276,7 @@ sigterm_handler(int sig) /* I - Signal */
* Flag that the job should be canceled...
*/
write(2, "DEBUG: job_canceled = 1.\n", 25);
write(2, "DEBUG: sigterm_handler: job_canceled = 1.\n", 25);
job_canceled = 1;
return;
@@ -3484,5 +3502,5 @@ update_reasons(ipp_attribute_t *attr, /* I - printer-state-reasons or NULL */
}
/*
* End of "$Id: ipp.c 12757 2015-06-24 19:55:31Z msweet $".
* End of "$Id: ipp.c 12896 2015-10-09 13:15:22Z msweet $".
*/
+3 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: lpd.c 12024 2014-07-15 12:58:39Z msweet $"
* "$Id: lpd.c 13040 2016-01-11 20:29:13Z msweet $"
*
* Line Printer Daemon backend for CUPS.
*
@@ -1251,7 +1251,7 @@ rresvport_af(int *port, /* IO - Port number to bind to */
*/
memset(&addr, 0, sizeof(addr));
addr.addr.sa_family = family;
addr.addr.sa_family = (sa_family_t)family;
/*
* Try to bind the socket to a reserved port...
@@ -1320,5 +1320,5 @@ sigterm_handler(int sig) /* I - Signal */
/*
* End of "$Id: lpd.c 12024 2014-07-15 12:58:39Z msweet $".
* End of "$Id: lpd.c 13040 2016-01-11 20:29:13Z msweet $".
*/
+46 -26
Ver Arquivo
@@ -5,6 +5,7 @@
# product ID (omit for all vendor products), and a list of known issues:
#
# blacklist The printer is not functional with the USB backend.
# delay-close Delay close/reset of selected interface
# no-reattach Do no re-attach usblp kernel module after printing.
# soft-reset Do a soft reset after printing for cleanup.
# unidir Only supported unidirectional I/O
@@ -51,67 +52,67 @@
# NEC Picty800 (HP OEM)
0x0409 0xf1be unidir
# Lexmark International, Inc. (e250d), https://bugs.launchpad.net/bugs/1084164
# Lexmark International, Inc. (e250d) (https://bugs.launchpad.net/bugs/1084164)
0x043d 0x00f3 no-reattach
# Kyocera Mita FS 820, by zut <kernel@zut.de>
0x0482 0x0010 unidir
# Canon, Inc. PIXMA iP6000D Printer, https://bugs.launchpad.net/bugs/1160638
# Canon, Inc. PIXMA iP6000D Printer (https://bugs.launchpad.net/bugs/1160638)
0x04a9 0x1095 unidir
# Canon, Inc. PIXMA iP4200 Printer, http://www.cups.org/str.php?L4155
# Canon, Inc. PIXMA iP4200 Printer (Issue #4155)
0x04a9 0x10a2 unidir
# Canon, Inc. PIXMA iP4300 Printer, https://bugs.launchpad.net/bugs/1032385
# Canon, Inc. PIXMA iP4300 Printer (https://bugs.launchpad.net/bugs/1032385)
0x04a9 0x10b6 unidir
# Canon, Inc. MP210 https://bugzilla.redhat.com/show_bug.cgi?id=847923#c53
# Canon, Inc. MP210 (https://bugzilla.redhat.com/show_bug.cgi?id=847923#c53)
0x04a9 0x1721 unidir
# Canon, Inc. MP500 Printer, https://bugs.launchpad.net/bugs/1032456
# Canon, Inc. MP500 Printer (https://bugs.launchpad.net/bugs/1032456)
0x04a9 0x170c unidir
# Canon, Inc. MP510 Printer, https://bugs.launchpad.net/bugs/1050009
# Canon, Inc. MP510 Printer (https://bugs.launchpad.net/bugs/1050009)
0x04a9 0x1717 unidir
# Canon, Inc. MP550 Printer, http://www.cups.org/str.php?L4155
# Canon, Inc. MP550 Printer (Issue #4155)
0x04a9 0x173d unidir
# Canon, Inc. MP560 Printer, http://www.cups.org/str.php?L4155
# Canon, Inc. MP560 Printer (Issue #4155)
0x04a9 0x173e unidir
# Canon, Inc. MF4150 Printer, https://bugs.launchpad.net/bugs/1160638
# Canon, Inc. MF4150 Printer (https://bugs.launchpad.net/bugs/1160638)
0x04a9 0x26a3 no-reattach
# Brother Industries, Ltd HL-1250 Laser Printer, https://bugs.debian.org/712512
# Brother Industries, Ltd HL-1250 Laser Printer (https://bugs.debian.org/712512)
0x04f9 0x0007 no-reattach
# Brother Industries, Ltd HL-1430 Laser Printer, https://bugs.launchpad.net/bugs/1038695
# Brother Industries, Ltd HL-1430 Laser Printer (https://bugs.launchpad.net/bugs/1038695)
0x04f9 0x001a no-reattach
# Brother Industries, Ltd HL-1440 Laser Printer, https://bugs.launchpad.net/bugs/1000253
# Brother Industries, Ltd HL-1440 Laser Printer (https://bugs.launchpad.net/bugs/1000253)
0x04f9 0x000d no-reattach unidir
# Brother Industries, Ltd HL-1450 Laser Printer, https://bugs.launchpad.net/bugs/1000253
# Brother Industries, Ltd HL-1450 Laser Printer (https://bugs.launchpad.net/bugs/1000253)
0x04f9 0x000e no-reattach unidir
# Oki Data Corp. Okipage 14ex Printer, https://bugs.launchpad.net/bugs/872483
# Oki Data Corp. Okipage 14ex Printer (https://bugs.launchpad.net/bugs/872483)
0x06bc 0x000b no-reattach
# Oki Data Corp. B410d, https://bugs.launchpad.net/bugs/872483
# Oki Data Corp. B410d (https://bugs.launchpad.net/bugs/872483)
0x06bc 0x01c7 no-reattach
# Seiko Epson Corp. Stylus Color 740 / Photo 750, http://bugs.debian.org/697970
# Seiko Epson Corp. Stylus Color 740 / Photo 750 (http://bugs.debian.org/697970)
0x04b8 0x0001 no-reattach unidir
# Seiko Epson Corp. Stylus Color 670, https://bugs.launchpad.net/bugs/872483
# Seiko Epson Corp. Stylus Color 670 (https://bugs.launchpad.net/bugs/872483)
0x04b8 0x0005 no-reattach
# Seiko Epson Receipt Printer M129C
0x04b8 0x0202 vendor-class
# Prolific Technology, Inc. PL2305 Parallel Port (USB -> Parallel adapter), https://bugs.launchpad.net/bugs/987485
# Prolific Technology, Inc. PL2305 Parallel Port (USB -> Parallel adapter) (https://bugs.launchpad.net/bugs/987485)
0x067b 0x2305 no-reattach soft-reset unidir
# Xerox Phaser 3124 https://bugzilla.redhat.com/show_bug.cgi?id=867392
@@ -120,13 +121,13 @@
# Xerox WorkCentre 3210 https://bugs.launchpad.net/bugs/1102470
0x0924 0x4293 no-reattach
# QinHeng Electronics CH340S (USB -> Parallel adapter), https://bugs.launchpad.net/bugs/1000253
# QinHeng Electronics CH340S (USB -> Parallel adapter) (https://bugs.launchpad.net/bugs/1000253)
0x1a86 0x7584 no-reattach
# All Samsung devices, https://bugs.launchpad.net/bugs/1032456
# All Samsung devices (https://bugs.launchpad.net/bugs/1032456)
0x04e8 soft-reset
# All Zebra devices, https://bugs.launchpad.net/bugs/1001028
# All Zebra devices (https://bugs.launchpad.net/bugs/1001028)
0x0a5f unidir
# Canon CP-10
@@ -216,14 +217,33 @@
# Lexmark E238 (<rdar://problem/14493054>)
0x043d 0x00d7 no-reattach
# Lexmark E238 (STR #4448)
# Lexmark E238 (Issue #4448)
0x043d 0x009a no-reattach
# Canon MX310 (STR #4482)
# Canon MX310 (Issue #4482)
0x04a9 0x1728 unidir
# Canon MX320 (STR #4482)
# Canon MX320 (Issue #4482)
0x04A9 0x1736 unidir
# All Intermec devices (STR #4553)
# All Intermec devices (Issue #4553)
0x067e no-reattach
# HP LaserJet 1150 (Issue #4549)
0x03f0 0x0f17 delay-close
# HP LaserJet 1300 (Issue #4549)
0x03f0 0x1017 delay-close
0x03f0 0x1117 delay-close
# HP LaserJet 1320 (Issue #4549)
0x03f0 0x1d17 delay-close
# Canon, Inc. MP530 Printer
0x04a9 0x1712 unidir
# Xerox WorkCentre 3220 (https://bugs.launchpad.net/bugs/1406203, Issue #4789)
0x0924 0x4294 no-reattach
# Lexmark C540n (Issue #4778)
0x043d 0x0139 no-reattach
+3 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: usb-darwin.c 12818 2015-07-31 13:29:25Z msweet $"
* "$Id: usb-darwin.c 12928 2015-10-23 21:31:58Z msweet $"
*
* Copyright 2005-2015 Apple Inc. All rights reserved.
*
@@ -1654,7 +1654,7 @@ static CFStringRef copy_printer_interface_deviceid(printer_interface_t printer,
{
ret = CFStringCreateWithBytes(NULL, (const UInt8 *) &request.pData[2], actualLength - 2, kCFStringEncodingUTF8, false);
}
else {
else if (actualLength > 2) {
err = sendRequest(actualLength);
if (err == kIOReturnSuccess && request.wLenDone > 0)
{
@@ -2537,5 +2537,5 @@ log_usb_class_driver(int is_64bit) /* I - Is the USB class driver 64-bit? */
/*
* End of "$Id: usb-darwin.c 12818 2015-07-31 13:29:25Z msweet $".
* End of "$Id: usb-darwin.c 12928 2015-10-23 21:31:58Z msweet $".
*/
+20 -3
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: usb-libusb.c 12348 2014-12-09 22:10:45Z msweet $"
* "$Id: usb-libusb.c 12881 2015-09-15 21:20:02Z msweet $"
*
* LIBUSB interface code for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
*
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
@@ -103,6 +103,7 @@ typedef struct usb_globals_s /* Global USB printer information */
#define USB_QUIRK_USB_INIT 0x0010 /* Needs vendor USB init string */
#define USB_QUIRK_VENDOR_CLASS 0x0020 /* Descriptor uses vendor-specific
Class or SubClass */
#define USB_QUIRK_DELAY_CLOSE 0x0040 /* Delay close */
#define USB_QUIRK_WHITELIST 0x0000 /* no quirks */
@@ -641,6 +642,9 @@ print_device(const char *uri, /* I - Device URI */
* Close the connection and input file and general clean up...
*/
if (g.printer->quirks & USB_QUIRK_DELAY_CLOSE)
sleep(1);
close_device(g.printer);
/*
@@ -1211,6 +1215,9 @@ load_quirks(void)
if (strstr(line, " blacklist"))
quirk->quirks |= USB_QUIRK_BLACKLIST;
if (strstr(line, " delay-close"))
quirk->quirks |= USB_QUIRK_DELAY_CLOSE;
if (strstr(line, " no-reattach"))
quirk->quirks |= USB_QUIRK_NO_REATTACH;
@@ -1522,6 +1529,16 @@ open_device(usb_printer_t *printer, /* I - Printer */
goto error;
}
else if ((errcode = libusb_detach_kernel_driver(printer->handle, printer->iface)) < 0)
{
fprintf(stderr,
"DEBUG: Failed to detach \"usblp\" module from %04x:%04x\n",
devdesc.idVendor, devdesc.idProduct);
goto error;
}
sleep (1);
}
/*
@@ -2004,6 +2021,6 @@ soft_reset_printer(
/*
* End of "$Id: usb-libusb.c 12348 2014-12-09 22:10:45Z msweet $".
* End of "$Id: usb-libusb.c 12881 2015-09-15 21:20:02Z msweet $".
*/
+7
Ver Arquivo
@@ -39,6 +39,13 @@ WebInterface @CUPS_WEBIF@
Order allow,deny
</Location>
# Restrict access to log files...
<Location /admin/log>
AuthType Default
Require user @SYSTEM
Order allow,deny
</Location>
# Set the default printer/job policies...
<Policy default>
# Job/subscription privacy...
+1 -1
Ver Arquivo
@@ -17,7 +17,7 @@ dnl Set the name of the config header file...
AC_CONFIG_HEADER(config.h)
dnl Version number information...
CUPS_VERSION=2.1.0
CUPS_VERSION="AC_PACKAGE_VERSION"
case "$CUPS_VERSION" in
*svn)
externo
+10 -10
Ver Arquivo
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.68 for CUPS 2.1.0.
# Generated by GNU Autoconf 2.68 for CUPS 2.1.4.
#
# Report bugs to <https://www.cups.org/str.php>.
#
@@ -560,8 +560,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='CUPS'
PACKAGE_TARNAME='cups'
PACKAGE_VERSION='2.1.0'
PACKAGE_STRING='CUPS 2.1.0'
PACKAGE_VERSION='2.1.4'
PACKAGE_STRING='CUPS 2.1.4'
PACKAGE_BUGREPORT='https://www.cups.org/str.php'
PACKAGE_URL='https://www.cups.org/'
@@ -1447,7 +1447,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures CUPS 2.1.0 to adapt to many kinds of systems.
\`configure' configures CUPS 2.1.4 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1508,7 +1508,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of CUPS 2.1.0:";;
short | recursive ) echo "Configuration of CUPS 2.1.4:";;
esac
cat <<\_ACEOF
@@ -1687,7 +1687,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
CUPS configure 2.1.0
CUPS configure 2.1.4
generated by GNU Autoconf 2.68
Copyright (C) 2010 Free Software Foundation, Inc.
@@ -2151,7 +2151,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by CUPS $as_me 2.1.0, which was
It was created by CUPS $as_me 2.1.4, which was
generated by GNU Autoconf 2.68. Invocation command line was
$ $0 $@
@@ -2526,7 +2526,7 @@ esac
ac_config_headers="$ac_config_headers config.h"
CUPS_VERSION=2.1.0
CUPS_VERSION="2.1.4"
case "$CUPS_VERSION" in
*svn)
@@ -10765,7 +10765,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by CUPS $as_me 2.1.0, which was
This file was extended by CUPS $as_me 2.1.4, which was
generated by GNU Autoconf 2.68. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -10828,7 +10828,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
CUPS config.status 2.1.0
CUPS config.status 2.1.4
configured by $0, generated by GNU Autoconf 2.68,
with options \\"\$ac_cs_config\\"
+4 -4
Ver Arquivo
@@ -1,9 +1,9 @@
dnl
dnl "$Id: configure.ac 12831 2015-08-05 14:24:32Z msweet $"
dnl "$Id: configure.ac 13087 2016-02-12 18:53:24Z msweet $"
dnl
dnl Configuration script for CUPS.
dnl
dnl Copyright 2007-2015 by Apple Inc.
dnl Copyright 2007-2016 by Apple Inc.
dnl Copyright 1997-2007 by Easy Software Products, all rights reserved.
dnl
dnl These coded instructions, statements, and computer programs are the
@@ -17,7 +17,7 @@ dnl We need at least autoconf 2.60...
AC_PREREQ(2.60)
dnl Package name and version...
AC_INIT([CUPS], [2.1.0], [https://www.cups.org/str.php], [cups], [https://www.cups.org/])
AC_INIT([CUPS], [2.1.4], [https://www.cups.org/str.php], [cups], [https://www.cups.org/])
sinclude(config-scripts/cups-opsys.m4)
sinclude(config-scripts/cups-common.m4)
@@ -95,5 +95,5 @@ AC_OUTPUT(Makedefs
chmod +x cups-config
dnl
dnl End of "$Id: configure.ac 12831 2015-08-05 14:24:32Z msweet $".
dnl End of "$Id: configure.ac 13087 2016-02-12 18:53:24Z msweet $".
dnl
+47 -4
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: adminutil.c 11598 2014-02-18 18:58:19Z msweet $"
* "$Id: adminutil.c 12945 2015-10-26 19:46:02Z msweet $"
*
* Administration utility API definitions for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
* Copyright 2001-2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -1175,6 +1175,7 @@ cupsAdminSetServerSettings(
in_cancel_job, /* In a cancel-job section? */
in_admin_location, /* In the /admin location? */
in_conf_location, /* In the /admin/conf location? */
in_log_location, /* In the /admin/log location? */
in_root_location; /* In the / location? */
const char *val; /* Setting value */
int share_printers, /* Share local printers */
@@ -1188,6 +1189,7 @@ cupsAdminSetServerSettings(
wrote_loglevel, /* Wrote the LogLevel line? */
wrote_admin_location, /* Wrote the /admin location? */
wrote_conf_location, /* Wrote the /admin/conf location? */
wrote_log_location, /* Wrote the /admin/log location? */
wrote_root_location; /* Wrote the / location? */
int indent; /* Indentation */
int cupsd_num_settings; /* New number of settings */
@@ -1401,12 +1403,14 @@ cupsAdminSetServerSettings(
in_conf_location = 0;
in_default_policy = 0;
in_location = 0;
in_log_location = 0;
in_policy = 0;
in_root_location = 0;
linenum = 0;
wrote_admin_location = 0;
wrote_browsing = 0;
wrote_conf_location = 0;
wrote_log_location = 0;
wrote_loglevel = 0;
wrote_policy = 0;
wrote_port_listen = 0;
@@ -1550,8 +1554,10 @@ cupsAdminSetServerSettings(
indent += 2;
if (!strcmp(value, "/admin"))
in_admin_location = 1;
if (!strcmp(value, "/admin/conf"))
else if (!strcmp(value, "/admin/conf"))
in_conf_location = 1;
else if (!strcmp(value, "/admin/log"))
in_log_location = 1;
else if (!strcmp(value, "/"))
in_root_location = 1;
@@ -1593,6 +1599,23 @@ cupsAdminSetServerSettings(
cupsFilePrintf(temp, " Allow %s\n",
remote_any > 0 ? "all" : "@LOCAL");
}
else if (in_log_location && remote_admin >= 0)
{
wrote_log_location = 1;
if (remote_admin)
cupsFilePuts(temp, " # Allow remote access to the log "
"files...\n");
else
cupsFilePuts(temp, " # Restrict access to the log "
"files...\n");
cupsFilePuts(temp, " Order allow,deny\n");
if (remote_admin)
cupsFilePrintf(temp, " Allow %s\n",
remote_any > 0 ? "all" : "@LOCAL");
}
else if (in_root_location &&
(remote_admin >= 0 || remote_any > 0 || share_printers >= 0))
{
@@ -1619,6 +1642,7 @@ cupsAdminSetServerSettings(
in_admin_location = 0;
in_conf_location = 0;
in_log_location = 0;
in_root_location = 0;
cupsFilePuts(temp, "</Location>\n");
@@ -1867,6 +1891,25 @@ cupsAdminSetServerSettings(
cupsFilePuts(temp, "</Location>\n");
}
if (!wrote_log_location && remote_admin >= 0)
{
if (remote_admin)
cupsFilePuts(temp,
"# Allow remote access to the log files...\n");
else
cupsFilePuts(temp, "# Restrict access to the log files...\n");
cupsFilePuts(temp, "<Location /admin/log>\n"
" AuthType Default\n"
" Require user @SYSTEM\n"
" Order allow,deny\n");
if (remote_admin)
cupsFilePrintf(temp, " Allow %s\n", remote_any > 0 ? "all" : "@LOCAL");
cupsFilePuts(temp, "</Location>\n");
}
if (!wrote_policy && user_cancel_any >= 0)
{
cupsFilePuts(temp, "<Policy default>\n"
@@ -2326,5 +2369,5 @@ write_option(cups_file_t *dstfp, /* I - PPD file */
/*
* End of "$Id: adminutil.c 11598 2014-02-18 18:58:19Z msweet $".
* End of "$Id: adminutil.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+10 -24
Ver Arquivo
@@ -1,22 +1,16 @@
/*
* "$Id: attr.c 10996 2013-05-29 11:51:34Z msweet $"
* "$Id: attr.c 12867 2015-09-13 23:49:19Z msweet $"
*
* PPD model-specific attribute routines for CUPS.
* PPD model-specific attribute routines for CUPS.
*
* Copyright 2007-2012 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products.
* Copyright 2007-2015 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
* law. Distribution and use rights are outlined in the file "LICENSE.txt"
* which should have been included with this file. If this file is
* file is missing or damaged, see the license at "http://www.cups.org/".
*
* Contents:
*
* ppdFindAttr() - Find the first matching attribute.
* ppdFindNextAttr() - Find the next matching attribute.
* _ppdNormalizeMakeAndModel() - Normalize a product/make-and-model string.
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
* law. Distribution and use rights are outlined in the file "LICENSE.txt"
* which should have been included with this file. If this file is
* file is missing or damaged, see the license at "http://www.cups.org/".
*/
/*
@@ -229,14 +223,6 @@ _ppdNormalizeMakeAndModel(
snprintf(buffer, bufsize, "Canon %s", make_and_model);
}
else if (!_cups_strncasecmp(make_and_model, "primera", 7))
{
/*
* Fargo...
*/
snprintf(buffer, bufsize, "Fargo %s", make_and_model);
}
else if (!_cups_strncasecmp(make_and_model, "designjet", 9) ||
!_cups_strncasecmp(make_and_model, "deskjet", 7))
{
@@ -331,5 +317,5 @@ _ppdNormalizeMakeAndModel(
/*
* End of "$Id: attr.c 10996 2013-05-29 11:51:34Z msweet $".
* End of "$Id: attr.c 12867 2015-09-13 23:49:19Z msweet $".
*/
+5 -5
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: cups.h 12733 2015-06-12 01:21:05Z msweet $"
* "$Id: cups.h 13087 2016-02-12 18:53:24Z msweet $"
*
* API definitions for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -58,10 +58,10 @@ extern "C" {
* Constants...
*/
# define CUPS_VERSION 2.0100
# define CUPS_VERSION 2.0104
# define CUPS_VERSION_MAJOR 2
# define CUPS_VERSION_MINOR 1
# define CUPS_VERSION_PATCH 0
# define CUPS_VERSION_PATCH 4
# define CUPS_BC_FD 3
/* Back-channel file descriptor for
@@ -636,5 +636,5 @@ extern int cupsSetServerCredentials(const char *path, const char *common_name,
#endif /* !_CUPS_CUPS_H_ */
/*
* End of "$Id: cups.h 12733 2015-06-12 01:21:05Z msweet $".
* End of "$Id: cups.h 13087 2016-02-12 18:53:24Z msweet $".
*/
+253 -251
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: debug.c 12327 2014-12-09 20:38:39Z msweet $"
* "$Id: debug.c 12928 2015-10-23 21:31:58Z msweet $"
*
* Debugging functions for CUPS.
*
* Copyright 2008-2014 by Apple Inc.
* Copyright 2008-2015 by Apple Inc.
*
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
@@ -82,14 +82,258 @@ debug_thread_id(void)
/*
* 'debug_vsnprintf()' - Format a string into a fixed size buffer.
* '_cups_debug_printf()' - Write a formatted line to the log.
*/
static ssize_t /* O - Number of bytes formatted */
debug_vsnprintf(char *buffer, /* O - Output buffer */
size_t bufsize, /* O - Size of output buffer */
const char *format, /* I - printf-style format string */
va_list ap) /* I - Pointer to additional arguments */
void DLLExport
_cups_debug_printf(const char *format, /* I - Printf-style format string */
...) /* I - Additional arguments as needed */
{
va_list ap; /* Pointer to arguments */
struct timeval curtime; /* Current time */
char buffer[2048]; /* Output buffer */
ssize_t bytes; /* Number of bytes in buffer */
int level; /* Log level in message */
/*
* See if we need to do any logging...
*/
if (!debug_init)
_cups_debug_set(getenv("CUPS_DEBUG_LOG"), getenv("CUPS_DEBUG_LEVEL"),
getenv("CUPS_DEBUG_FILTER"), 0);
if (_cups_debug_fd < 0)
return;
/*
* Filter as needed...
*/
if (isdigit(format[0]))
level = *format++ - '0';
else
level = 0;
if (level > _cups_debug_level)
return;
if (debug_filter)
{
int result; /* Filter result */
_cupsMutexLock(&debug_init_mutex);
result = regexec(debug_filter, format, 0, NULL, 0);
_cupsMutexUnlock(&debug_init_mutex);
if (result)
return;
}
/*
* Format the message...
*/
gettimeofday(&curtime, NULL);
snprintf(buffer, sizeof(buffer), "T%03d %02d:%02d:%02d.%03d ",
debug_thread_id(), (int)((curtime.tv_sec / 3600) % 24),
(int)((curtime.tv_sec / 60) % 60),
(int)(curtime.tv_sec % 60), (int)(curtime.tv_usec / 1000));
va_start(ap, format);
bytes = _cups_safe_vsnprintf(buffer + 19, sizeof(buffer) - 20, format, ap) + 19;
va_end(ap);
if ((size_t)bytes >= (sizeof(buffer) - 1))
{
buffer[sizeof(buffer) - 2] = '\n';
bytes = sizeof(buffer) - 1;
}
else if (buffer[bytes - 1] != '\n')
{
buffer[bytes++] = '\n';
buffer[bytes] = '\0';
}
/*
* Write it out...
*/
_cupsMutexLock(&debug_log_mutex);
write(_cups_debug_fd, buffer, (size_t)bytes);
_cupsMutexUnlock(&debug_log_mutex);
}
/*
* '_cups_debug_puts()' - Write a single line to the log.
*/
void DLLExport
_cups_debug_puts(const char *s) /* I - String to output */
{
struct timeval curtime; /* Current time */
char buffer[2048]; /* Output buffer */
ssize_t bytes; /* Number of bytes in buffer */
int level; /* Log level in message */
/*
* See if we need to do any logging...
*/
if (!debug_init)
_cups_debug_set(getenv("CUPS_DEBUG_LOG"), getenv("CUPS_DEBUG_LEVEL"),
getenv("CUPS_DEBUG_FILTER"), 0);
if (_cups_debug_fd < 0)
return;
/*
* Filter as needed...
*/
if (isdigit(s[0]))
level = *s++ - '0';
else
level = 0;
if (level > _cups_debug_level)
return;
if (debug_filter)
{
int result; /* Filter result */
_cupsMutexLock(&debug_init_mutex);
result = regexec(debug_filter, s, 0, NULL, 0);
_cupsMutexUnlock(&debug_init_mutex);
if (result)
return;
}
/*
* Format the message...
*/
gettimeofday(&curtime, NULL);
bytes = snprintf(buffer, sizeof(buffer), "T%03d %02d:%02d:%02d.%03d %s",
debug_thread_id(), (int)((curtime.tv_sec / 3600) % 24),
(int)((curtime.tv_sec / 60) % 60),
(int)(curtime.tv_sec % 60), (int)(curtime.tv_usec / 1000),
s);
if ((size_t)bytes >= (sizeof(buffer) - 1))
{
buffer[sizeof(buffer) - 2] = '\n';
bytes = sizeof(buffer) - 1;
}
else if (buffer[bytes - 1] != '\n')
{
buffer[bytes++] = '\n';
buffer[bytes] = '\0';
}
/*
* Write it out...
*/
_cupsMutexLock(&debug_log_mutex);
write(_cups_debug_fd, buffer, (size_t)bytes);
_cupsMutexUnlock(&debug_log_mutex);
}
/*
* '_cups_debug_set()' - Enable or disable debug logging.
*/
void DLLExport
_cups_debug_set(const char *logfile, /* I - Log file or NULL */
const char *level, /* I - Log level or NULL */
const char *filter, /* I - Filter string or NULL */
int force) /* I - Force initialization */
{
_cupsMutexLock(&debug_init_mutex);
if (!debug_init || force)
{
/*
* Restore debug settings to defaults...
*/
if (_cups_debug_fd != -1)
{
close(_cups_debug_fd);
_cups_debug_fd = -1;
}
if (debug_filter)
{
regfree((regex_t *)debug_filter);
debug_filter = NULL;
}
_cups_debug_level = 1;
/*
* Open logs, set log levels, etc.
*/
if (!logfile)
_cups_debug_fd = -1;
else if (!strcmp(logfile, "-"))
_cups_debug_fd = 2;
else
{
char buffer[1024]; /* Filename buffer */
snprintf(buffer, sizeof(buffer), logfile, getpid());
if (buffer[0] == '+')
_cups_debug_fd = open(buffer + 1, O_WRONLY | O_APPEND | O_CREAT, 0644);
else
_cups_debug_fd = open(buffer, O_WRONLY | O_TRUNC | O_CREAT, 0644);
}
if (level)
_cups_debug_level = atoi(level);
if (filter)
{
if ((debug_filter = (regex_t *)calloc(1, sizeof(regex_t))) == NULL)
fputs("Unable to allocate memory for CUPS_DEBUG_FILTER - results not "
"filtered!\n", stderr);
else if (regcomp(debug_filter, filter, REG_EXTENDED))
{
fputs("Bad regular expression in CUPS_DEBUG_FILTER - results not "
"filtered!\n", stderr);
free(debug_filter);
debug_filter = NULL;
}
}
debug_init = 1;
}
_cupsMutexUnlock(&debug_init_mutex);
}
#endif /* DEBUG */
/*
* '_cups_safe_vsnprintf()' - Format a string into a fixed size buffer,
* quoting special characters.
*/
ssize_t /* O - Number of bytes formatted */
_cups_safe_vsnprintf(
char *buffer, /* O - Output buffer */
size_t bufsize, /* O - Size of output buffer */
const char *format, /* I - printf-style format string */
va_list ap) /* I - Pointer to additional arguments */
{
char *bufptr, /* Pointer to position in buffer */
*bufend, /* Pointer to end of buffer */
@@ -401,247 +645,5 @@ debug_vsnprintf(char *buffer, /* O - Output buffer */
/*
* '_cups_debug_printf()' - Write a formatted line to the log.
*/
void DLLExport
_cups_debug_printf(const char *format, /* I - Printf-style format string */
...) /* I - Additional arguments as needed */
{
va_list ap; /* Pointer to arguments */
struct timeval curtime; /* Current time */
char buffer[2048]; /* Output buffer */
ssize_t bytes; /* Number of bytes in buffer */
int level; /* Log level in message */
/*
* See if we need to do any logging...
*/
if (!debug_init)
_cups_debug_set(getenv("CUPS_DEBUG_LOG"), getenv("CUPS_DEBUG_LEVEL"),
getenv("CUPS_DEBUG_FILTER"), 0);
if (_cups_debug_fd < 0)
return;
/*
* Filter as needed...
*/
if (isdigit(format[0]))
level = *format++ - '0';
else
level = 0;
if (level > _cups_debug_level)
return;
if (debug_filter)
{
int result; /* Filter result */
_cupsMutexLock(&debug_init_mutex);
result = regexec(debug_filter, format, 0, NULL, 0);
_cupsMutexUnlock(&debug_init_mutex);
if (result)
return;
}
/*
* Format the message...
*/
gettimeofday(&curtime, NULL);
snprintf(buffer, sizeof(buffer), "T%03d %02d:%02d:%02d.%03d ",
debug_thread_id(), (int)((curtime.tv_sec / 3600) % 24),
(int)((curtime.tv_sec / 60) % 60),
(int)(curtime.tv_sec % 60), (int)(curtime.tv_usec / 1000));
va_start(ap, format);
bytes = debug_vsnprintf(buffer + 19, sizeof(buffer) - 20, format, ap) + 19;
va_end(ap);
if ((size_t)bytes >= (sizeof(buffer) - 1))
{
buffer[sizeof(buffer) - 2] = '\n';
bytes = sizeof(buffer) - 1;
}
else if (buffer[bytes - 1] != '\n')
{
buffer[bytes++] = '\n';
buffer[bytes] = '\0';
}
/*
* Write it out...
*/
_cupsMutexLock(&debug_log_mutex);
write(_cups_debug_fd, buffer, (size_t)bytes);
_cupsMutexUnlock(&debug_log_mutex);
}
/*
* '_cups_debug_puts()' - Write a single line to the log.
*/
void DLLExport
_cups_debug_puts(const char *s) /* I - String to output */
{
struct timeval curtime; /* Current time */
char buffer[2048]; /* Output buffer */
ssize_t bytes; /* Number of bytes in buffer */
int level; /* Log level in message */
/*
* See if we need to do any logging...
*/
if (!debug_init)
_cups_debug_set(getenv("CUPS_DEBUG_LOG"), getenv("CUPS_DEBUG_LEVEL"),
getenv("CUPS_DEBUG_FILTER"), 0);
if (_cups_debug_fd < 0)
return;
/*
* Filter as needed...
*/
if (isdigit(s[0]))
level = *s++ - '0';
else
level = 0;
if (level > _cups_debug_level)
return;
if (debug_filter)
{
int result; /* Filter result */
_cupsMutexLock(&debug_init_mutex);
result = regexec(debug_filter, s, 0, NULL, 0);
_cupsMutexUnlock(&debug_init_mutex);
if (result)
return;
}
/*
* Format the message...
*/
gettimeofday(&curtime, NULL);
bytes = snprintf(buffer, sizeof(buffer), "T%03d %02d:%02d:%02d.%03d %s",
debug_thread_id(), (int)((curtime.tv_sec / 3600) % 24),
(int)((curtime.tv_sec / 60) % 60),
(int)(curtime.tv_sec % 60), (int)(curtime.tv_usec / 1000),
s);
if ((size_t)bytes >= (sizeof(buffer) - 1))
{
buffer[sizeof(buffer) - 2] = '\n';
bytes = sizeof(buffer) - 1;
}
else if (buffer[bytes - 1] != '\n')
{
buffer[bytes++] = '\n';
buffer[bytes] = '\0';
}
/*
* Write it out...
*/
_cupsMutexLock(&debug_log_mutex);
write(_cups_debug_fd, buffer, (size_t)bytes);
_cupsMutexUnlock(&debug_log_mutex);
}
/*
* '_cups_debug_set()' - Enable or disable debug logging.
*/
void DLLExport
_cups_debug_set(const char *logfile, /* I - Log file or NULL */
const char *level, /* I - Log level or NULL */
const char *filter, /* I - Filter string or NULL */
int force) /* I - Force initialization */
{
_cupsMutexLock(&debug_init_mutex);
if (!debug_init || force)
{
/*
* Restore debug settings to defaults...
*/
if (_cups_debug_fd != -1)
{
close(_cups_debug_fd);
_cups_debug_fd = -1;
}
if (debug_filter)
{
regfree((regex_t *)debug_filter);
debug_filter = NULL;
}
_cups_debug_level = 1;
/*
* Open logs, set log levels, etc.
*/
if (!logfile)
_cups_debug_fd = -1;
else if (!strcmp(logfile, "-"))
_cups_debug_fd = 2;
else
{
char buffer[1024]; /* Filename buffer */
snprintf(buffer, sizeof(buffer), logfile, getpid());
if (buffer[0] == '+')
_cups_debug_fd = open(buffer + 1, O_WRONLY | O_APPEND | O_CREAT, 0644);
else
_cups_debug_fd = open(buffer, O_WRONLY | O_TRUNC | O_CREAT, 0644);
}
if (level)
_cups_debug_level = atoi(level);
if (filter)
{
if ((debug_filter = (regex_t *)calloc(1, sizeof(regex_t))) == NULL)
fputs("Unable to allocate memory for CUPS_DEBUG_FILTER - results not "
"filtered!\n", stderr);
else if (regcomp(debug_filter, filter, REG_EXTENDED))
{
fputs("Bad regular expression in CUPS_DEBUG_FILTER - results not "
"filtered!\n", stderr);
free(debug_filter);
debug_filter = NULL;
}
}
debug_init = 1;
}
_cupsMutexUnlock(&debug_init_mutex);
}
#endif /* DEBUG */
/*
* End of "$Id: debug.c 12327 2014-12-09 20:38:39Z msweet $".
* End of "$Id: debug.c 12928 2015-10-23 21:31:58Z msweet $".
*/
+7 -8
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: dest.c 12733 2015-06-12 01:21:05Z msweet $"
* "$Id: dest.c 13075 2016-01-29 21:14:05Z msweet $"
*
* User-defined destination (and option) support for CUPS.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -122,7 +122,7 @@ typedef struct _cups_dnssd_resolve_s /* Data for resolving URI */
#ifdef __APPLE__
static CFArrayRef appleCopyLocations(void);
static CFStringRef appleCopyNetwork(void);
static char *appleGetPaperSize(char *name, int namesize);
static char *appleGetPaperSize(char *name, size_t namesize);
static CFStringRef appleGetPrinter(CFArrayRef locations,
CFStringRef network, CFIndex *locindex);
#endif /* __APPLE__ */
@@ -2491,8 +2491,8 @@ appleCopyNetwork(void)
*/
static char * /* O - Default paper size */
appleGetPaperSize(char *name, /* I - Paper size name buffer */
int namesize) /* I - Size of buffer */
appleGetPaperSize(char *name, /* I - Paper size name buffer */
size_t namesize) /* I - Size of buffer */
{
CFStringRef defaultPaperID; /* Default paper ID */
pwg_media_t *pwgmedia; /* PWG media size */
@@ -2501,8 +2501,7 @@ appleGetPaperSize(char *name, /* I - Paper size name buffer */
defaultPaperID = _cupsAppleCopyDefaultPaperID();
if (!defaultPaperID ||
CFGetTypeID(defaultPaperID) != CFStringGetTypeID() ||
!CFStringGetCString(defaultPaperID, name, namesize,
kCFStringEncodingUTF8))
!CFStringGetCString(defaultPaperID, name, (CFIndex)namesize, kCFStringEncodingUTF8))
name[0] = '\0';
else if ((pwgmedia = pwgMediaForLegacy(name)) != NULL)
strlcpy(name, pwgmedia->pwg, namesize);
@@ -3943,5 +3942,5 @@ cups_make_string(
/*
* End of "$Id: dest.c 12733 2015-06-12 01:21:05Z msweet $".
* End of "$Id: dest.c 13075 2016-01-29 21:14:05Z msweet $".
*/
+6 -6
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: encode.c 12668 2015-05-27 19:30:32Z msweet $"
* "$Id: encode.c 13064 2016-01-27 16:05:09Z msweet $"
*
* Option encoding routines for CUPS.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -542,14 +542,13 @@ cupsEncodeOptions2(
else if (*sep == ',' && !quote)
count ++;
else if (*sep == '\\' && sep[1])
sep ++;
sep += 2;
}
}
else
count = 1;
DEBUG_printf(("2cupsEncodeOptions2: option=\"%s\", count=%d",
option->name, count));
DEBUG_printf(("2cupsEncodeOptions2: option=\"%s\", value=\"%s\", count=%d", option->name, option->value, count));
/*
* Allocate memory for the attribute values...
@@ -633,6 +632,7 @@ cupsEncodeOptions2(
* Skip quoted character...
*/
memmove(sep, sep + 1, strlen(sep));
sep ++;
}
}
@@ -853,5 +853,5 @@ compare_ipp_options(_ipp_option_t *a, /* I - First option */
/*
* End of "$Id: encode.c 12668 2015-05-27 19:30:32Z msweet $".
* End of "$Id: encode.c 13064 2016-01-27 16:05:09Z msweet $".
*/
+8 -2
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: http-support.c 12752 2015-06-24 19:30:47Z msweet $"
* "$Id: http-support.c 12970 2015-11-13 20:02:51Z msweet $"
*
* HTTP support routines for CUPS.
*
@@ -1233,6 +1233,12 @@ httpSeparateURI(
*port = (int)strtol(uri + 1, (char **)&uri, 10);
if (*port <= 0 || *port > 65535)
{
*port = 0;
return (HTTP_URI_STATUS_BAD_PORT);
}
if (*uri != '/' && *uri)
{
*port = 0;
@@ -2544,5 +2550,5 @@ http_resolve_cb(
/*
* End of "$Id: http-support.c 12752 2015-06-24 19:30:47Z msweet $".
* End of "$Id: http-support.c 12970 2015-11-13 20:02:51Z msweet $".
*/
+3 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: http.c 12848 2015-08-26 18:51:57Z msweet $"
* "$Id: http.c 12970 2015-11-13 20:02:51Z msweet $"
*
* HTTP routines for CUPS.
*
@@ -3003,7 +3003,7 @@ _httpUpdate(http_t *http, /* I - HTTP connection */
*status = http->status;
return (0);
}
else if (!strncmp(line, "HTTP/", 5))
else if (!strncmp(line, "HTTP/", 5) && http->mode == _HTTP_MODE_CLIENT)
{
/*
* Got the beginning of a response...
@@ -4850,5 +4850,5 @@ http_write_chunk(http_t *http, /* I - HTTP connection */
/*
* End of "$Id: http.c 12848 2015-08-26 18:51:57Z msweet $".
* End of "$Id: http.c 12970 2015-11-13 20:02:51Z msweet $".
*/
+3 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: ppd-cache.c 12733 2015-06-12 01:21:05Z msweet $"
* "$Id: ppd-cache.c 12980 2015-11-17 21:23:32Z msweet $"
*
* PPD cache implementation for CUPS.
*
@@ -85,7 +85,7 @@ _cupsConvertOptions(ipp_t *request, /* I - IPP request */
* Send standard IPP attributes...
*/
if (pc->password && (keyword = cupsGetOption("job-password", num_options, options)) != NULL)
if (pc->password && (keyword = cupsGetOption("job-password", num_options, options)) != NULL && ippGetOperation(request) != IPP_OP_VALIDATE_JOB)
{
ippAddOctetString(request, IPP_TAG_OPERATION, "job-password", keyword, (int)strlen(keyword));
@@ -3811,5 +3811,5 @@ pwg_unppdize_name(const char *ppd, /* I - PPD keyword */
/*
* End of "$Id: ppd-cache.c 12733 2015-06-12 01:21:05Z msweet $".
* End of "$Id: ppd-cache.c 12980 2015-11-17 21:23:32Z msweet $".
*/
+4 -3
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: string-private.h 11889 2014-05-22 13:54:15Z msweet $"
* "$Id: string-private.h 12928 2015-10-23 21:31:58Z msweet $"
*
* Private string definitions for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -147,6 +147,7 @@ extern int _cups_toupper(int ch);
* Prototypes...
*/
extern ssize_t _cups_safe_vsnprintf(char *, size_t, const char *, va_list);
extern void _cups_strcpy(char *dst, const char *src);
# ifndef HAVE_STRDUP
@@ -218,5 +219,5 @@ extern char *_cupsStrDate(char *buf, size_t bufsize, time_t timeval);
#endif /* !_CUPS_STRING_H_ */
/*
* End of "$Id: string-private.h 11889 2014-05-22 13:54:15Z msweet $".
* End of "$Id: string-private.h 12928 2015-10-23 21:31:58Z msweet $".
*/
+82 -17
Ver Arquivo
@@ -1,21 +1,17 @@
/*
* "$Id: testoptions.c 1992 2010-03-24 14:32:08Z msweet $"
* "$Id: testoptions.c 13061 2016-01-26 21:31:40Z msweet $"
*
* Option test program for CUPS.
* Option unit test program for CUPS.
*
* Copyright 2008-2010 by Apple Inc.
* Copyright 2008-2016 by Apple Inc.
*
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
* law. Distribution and use rights are outlined in the file "LICENSE.txt"
* which should have been included with this file. If this file is
* file is missing or damaged, see the license at "http://www.cups.org/".
* These coded instructions, statements, and computer programs are the
* property of Apple Inc. and are protected by Federal copyright
* law. Distribution and use rights are outlined in the file "LICENSE.txt"
* which should have been included with this file. If this file is
* file is missing or damaged, see the license at "http://www.cups.org/".
*
* This file is subject to the Apple OS-Developed Software exception.
*
* Contents:
*
* main() - Test option processing functions.
* This file is subject to the Apple OS-Developed Software exception.
*/
/*
@@ -37,6 +33,9 @@ main(int argc, /* I - Number of command-line arguments */
num_options; /* Number of options */
cups_option_t *options; /* Options */
const char *value; /* Value of an option */
ipp_t *request; /* IPP request */
ipp_attribute_t *attr; /* IPP attribute */
int count; /* Number of attributes */
if (argc == 1)
@@ -53,11 +52,12 @@ main(int argc, /* I - Number of command-line arguments */
"baz={param1=1 param2=2} "
"foobar=FOO\\ BAR "
"barfoo=barfoo "
"barfoo=\"\'BAR FOO\'\"", 0, &options);
"barfoo=\"\'BAR FOO\'\" "
"auth-info=user,pass\\\\,word\\\\\\\\", 0, &options);
if (num_options != 5)
if (num_options != 6)
{
printf("FAIL (num_options=%d, expected 5)\n", num_options);
printf("FAIL (num_options=%d, expected 6)\n", num_options);
status ++;
}
else if ((value = cupsGetOption("foo", num_options, options)) == NULL ||
@@ -91,6 +91,71 @@ main(int argc, /* I - Number of command-line arguments */
printf("FAIL (barfoo=\"%s\", expected \"\'BAR FOO\'\")\n", value);
status ++;
}
else if ((value = cupsGetOption("auth-info", num_options, options)) == NULL ||
strcmp(value, "user,pass\\,word\\\\"))
{
printf("FAIL (auth-info=\"%s\", expected \"user,pass\\,word\\\\\")\n", value);
status ++;
}
else
puts("PASS");
fputs("cupsEncodeOptions2: ", stdout);
request = ippNew();
ippSetOperation(request, IPP_OP_PRINT_JOB);
cupsEncodeOptions2(request, num_options, options, IPP_TAG_JOB);
for (count = 0, attr = ippFirstAttribute(request); attr; attr = ippNextAttribute(request), count ++);
if (count != 6)
{
printf("FAIL (%d attributes, expected 6)\n", count);
status ++;
}
else if ((attr = ippFindAttribute(request, "foo", IPP_TAG_ZERO)) == NULL)
{
puts("FAIL (Unable to find attribute \"foo\")");
status ++;
}
else if (ippGetValueTag(attr) != IPP_TAG_NAME)
{
printf("FAIL (\"foo\" of type %s, expected name)\n", ippTagString(ippGetValueTag(attr)));
status ++;
}
else if (ippGetCount(attr) != 1)
{
printf("FAIL (\"foo\" has %d values, expected 1)\n", (int)ippGetCount(attr));
status ++;
}
else if (strcmp(ippGetString(attr, 0, NULL), "1234"))
{
printf("FAIL (\"foo\" has value %s, expected 1234)\n", ippGetString(attr, 0, NULL));
status ++;
}
else if ((attr = ippFindAttribute(request, "auth-info", IPP_TAG_ZERO)) == NULL)
{
puts("FAIL (Unable to find attribute \"auth-info\")");
status ++;
}
else if (ippGetValueTag(attr) != IPP_TAG_TEXT)
{
printf("FAIL (\"auth-info\" of type %s, expected text)\n", ippTagString(ippGetValueTag(attr)));
status ++;
}
else if (ippGetCount(attr) != 2)
{
printf("FAIL (\"auth-info\" has %d values, expected 2)\n", (int)ippGetCount(attr));
status ++;
}
else if (strcmp(ippGetString(attr, 0, NULL), "user"))
{
printf("FAIL (\"auth-info\"[0] has value \"%s\", expected \"user\")\n", ippGetString(attr, 0, NULL));
status ++;
}
else if (strcmp(ippGetString(attr, 1, NULL), "pass,word\\"))
{
printf("FAIL (\"auth-info\"[1] has value \"%s\", expected \"pass,word\\\")\n", ippGetString(attr, 1, NULL));
status ++;
}
else
puts("PASS");
}
@@ -112,5 +177,5 @@ main(int argc, /* I - Number of command-line arguments */
/*
* End of "$Id: testoptions.c 1992 2010-03-24 14:32:08Z msweet $".
* End of "$Id: testoptions.c 13061 2016-01-26 21:31:40Z msweet $".
*/
+5 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: usersys.c 12817 2015-07-30 15:45:46Z msweet $"
* "$Id: usersys.c 13030 2016-01-04 14:35:45Z msweet $"
*
* User, system, and password routines for CUPS.
*
@@ -710,6 +710,8 @@ _cupsGetPassword(const char *prompt) /* I - Prompt string */
noecho = original;
noecho.c_lflag &= (tcflag_t)~(ICANON | ECHO | ECHOE | ISIG);
noecho.c_cc[VMIN] = 1;
noecho.c_cc[VTIME] = 0;
if (tcsetattr(tty, TCSAFLUSH, &noecho))
{
@@ -1237,7 +1239,7 @@ cups_set_ssl_options(
for (start = temp; *start; start = end)
{
/*
/*
* Find end of keyword...
*/
@@ -1285,5 +1287,5 @@ cups_set_user(
/*
* End of "$Id: usersys.c 12817 2015-07-30 15:45:46Z msweet $".
* End of "$Id: usersys.c 13030 2016-01-04 14:35:45Z msweet $".
*/
+5 -6
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: util.c 12448 2015-01-29 20:32:07Z msweet $"
* "$Id: util.c 12884 2015-10-07 20:31:46Z msweet $"
*
* Printing utilities for CUPS.
*
@@ -1528,10 +1528,9 @@ cups_get_printer_uri(
}
if (device_uri &&
(!strncmp(device_uri, "ipp://", 6) ||
!strncmp(device_uri, "ipps://", 7) ||
((strstr(device_uri, "._ipp.") != NULL ||
strstr(device_uri, "._ipps.") != NULL) &&
(((!strncmp(device_uri, "ipp://", 6) || !strncmp(device_uri, "ipps://", 7)) &&
(strstr(device_uri, "/printers/") != NULL || strstr(device_uri, "/classes/") != NULL)) ||
((strstr(device_uri, "._ipp.") != NULL || strstr(device_uri, "._ipps.") != NULL) &&
!strcmp(device_uri + strlen(device_uri) - 5, "/cups"))))
{
/*
@@ -1655,5 +1654,5 @@ cups_get_printer_uri(
/*
* End of "$Id: util.c 12448 2015-01-29 20:32:07Z msweet $".
* End of "$Id: util.c 12884 2015-10-07 20:31:46Z msweet $".
*/
+5 -5
Ver Arquivo
@@ -45,15 +45,15 @@ The following options are recognized:
<dd style="margin-left: 5.0em">Specifies an alternate username to use when authenticating with the scheduler.
<dt><b>-h </b><i>server</i>[<b>:</b><i>port</i>]
<dd style="margin-left: 5.0em">Specifies the server address.
<dt><b>--fR[fBno-fR]fBdebug-logging</b>
<dt><b>--</b>[<b>no-</b>]<b>debug-logging</b>
<dd style="margin-left: 5.0em">Enables (disables) debug logging to the <i>error_log</i> file.
<dt><b>--fR[fBno-fR]fBremote-admin</b>
<dt><b>--</b>[<b>no-</b>]<b>remote-admin</b>
<dd style="margin-left: 5.0em">Enables (disables) remote administration.
<dt><b>--fR[fBno-fR]fBremote-any</b>
<dt><b>--</b>[<b>no-</b>]<b>remote-any</b>
<dd style="margin-left: 5.0em">Enables (disables) printing from any address, e.g., the Internet.
<dt><b>--fR[fBno-fR]fBshare-printers</b>
<dt><b>--</b>[<b>no-</b>]<b>share-printers</b>
<dd style="margin-left: 5.0em">Enables (disables) sharing of local printers with other computers.
<dt><b>--fR[fBno-fR]fBuser-cancel-any</b>
<dt><b>--</b>[<b>no-</b>]<b>user-cancel-any</b>
<dd style="margin-left: 5.0em">Allows (prevents) users to cancel jobs owned by others.
</dl>
<h2 class="title"><a name="EXAMPLES">Examples</a></h2>
+11 -5
Ver Arquivo
@@ -13,7 +13,7 @@ cupsd - cups scheduler
<b>cupsd</b>
[
<b>-c</b>
<i>config-file</i>
<i>cupsd.conf</i>
] [
<b>-f</b>
] [
@@ -23,17 +23,20 @@ cupsd - cups scheduler
] [
<b>-l</b>
] [
<b>-s</b>
<i>cups-files.conf</i>
] [
<b>-t</b>
]
<h2 class="title"><a name="DESCRIPTION">Description</a></h2>
<b>cupsd</b>
is the scheduler for CUPS. It implements a printing system based upon the Internet Printing Protocol, version 2.1. If no options are specified on the command-line then the default configuration file
is the scheduler for CUPS. It implements a printing system based upon the Internet Printing Protocol, version 2.1, and supports most of the requirements for IPP Everywhere. If no options are specified on the command-line then the default configuration file
<i>/etc/cups/cupsd.conf</i>
will be used.
<h2 class="title"><a name="OPTIONS">Options</a></h2>
<dl class="man">
<dt><b>-c</b><i> config-file</i>
<dd style="margin-left: 5.0em">Uses the named configuration file.
<dt><b>-c</b><i> cupsd.conf</i>
<dd style="margin-left: 5.0em">Uses the named cupsd.conf configuration file.
<dt><b>-f</b>
<dd style="margin-left: 5.0em">Run
<b>cupsd</b>
@@ -54,6 +57,8 @@ when it is run from
<b>launchd</b>(8)
or
<b>systemd</b>(8).
<dt><b>-s</b><i> cups-files.conf</i>
<dd style="margin-left: 5.0em">Uses the named cups-files.conf configuration file.
<dt><b>-t</b>
<dd style="margin-left: 5.0em">Test the configuration file for syntax errors.
</dl>
@@ -99,6 +104,7 @@ in the foreground with a test configuration file called
<a href="man-backend.html?TOPIC=Man+Pages"><b>backend</b>(7),</a>
<a href="man-classes.conf.html?TOPIC=Man+Pages"><b>classes.conf</b>(5),</a>
<a href="man-cups.html?TOPIC=Man+Pages"><b>cups</b>(1),</a>
<a href="man-cups-files.conf.html?TOPIC=Man+Pages"><b>cups-files.conf</b>(5),</a>
<a href="man-cups-lpd.html?TOPIC=Man+Pages"><b>cups-lpd</b>(8),</a>
<a href="man-cupsd.conf.html?TOPIC=Man+Pages"><b>cupsd.conf</b>(5),</a>
<a href="man-cupsd-helper.html?TOPIC=Man+Pages"><b>cupsd-helper</b>(8),</a>
@@ -111,7 +117,7 @@ in the foreground with a test configuration file called
<b>systemd</b>(8),
CUPS Online Help (<a href="http://localhost:631/help">http://localhost:631/help</a>)
<h2 class="title"><a name="COPYRIGHT">Copyright</a></h2>
Copyright &copy; 2007-2015 by Apple Inc.
Copyright &copy; 2007-2016 by Apple Inc.
</body>
</html>
+1 -1
Ver Arquivo
@@ -45,7 +45,7 @@ This man page provides a quick reference to the supported keywords and should be
<dd style="margin-left: 5.0em"><dt><b>Darkness </b><i>temperature </i><b>"</b><i>name</i><b>/</b><i>text</i><b>"</b>
<dd style="margin-left: 5.0em"><dt><b>DriverType </b><i>type</i>
<dd style="margin-left: 5.0em"><dt><b>Duplex </b><i>type</i>
<dd style="margin-left: 5.0em"><dt><b>Filter Imime-type cost program</b>
<dd style="margin-left: 5.0em"><dt><b>Filter </b><i>mime-type cost program</i>
<dd style="margin-left: 5.0em"><dt><b>Finishing </b><i>name</i>
<dd style="margin-left: 5.0em"><dt><b>Finishing "</b><i>name</i><b>/</b><i>text</i><b>"</b>
<dd style="margin-left: 5.0em"><dt><b>Font *</b>
+107
Ver Arquivo
@@ -0,0 +1,107 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<TITLE>Home - CUPS @CUPS_VERSION@@CUPS_REVISION@</TITLE>
<LINK REL="STYLESHEET" TYPE="text/css" HREF="/cups.css">
<LINK REL="SHORTCUT ICON" HREF="/images/cups-icon.png" TYPE="image/png">
</HEAD>
<BODY>
<TABLE CLASS="page" SUMMARY="{title}">
<TR><TD CLASS="body">
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
<TR HEIGHT="36">
<TD><A HREF="http://www.cups.org/" TARGET="_blank"><IMG
SRC="/images/left.gif" WIDTH="64" HEIGHT="36" BORDER="0" ALT=""></A></TD>
<TD CLASS="sel"><A HREF="/">&nbsp;&nbsp;In&iacute;cio&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel"><A HREF="/admin">&nbsp;&nbsp;Administra&ccedil;&atilde;o&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel"><A HREF="/classes/">&nbsp;&nbsp;Classes&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel"><A HREF="/help/">&nbsp;&nbsp;Ajuda&nbsp;online&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel"><A HREF="/jobs/">&nbsp;&nbsp;Trabalhos&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel"><A HREF="/printers/">&nbsp;&nbsp;Impressoras&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel" WIDTH="100%"><FORM ACTION="/help/" METHOD="GET"><INPUT
TYPE="SEARCH" NAME="QUERY" SIZE="20" PLACEHOLDER="Procurar ajuda"
AUTOSAVE="org.cups.help" RESULTS="20"></FORM></TD>
<TD><IMG SRC="/images/right.gif" WIDTH="4" HEIGHT="36" ALT=""></TD>
</TR>
</TABLE>
<TABLE CLASS="indent" SUMMARY="">
<TR><TD STYLE="padding-right: 20px;">
<H1>CUPS @CUPS_VERSION@</H1>
<P>CUPS &eacute; o sistema de impress&atilde;o de c&oacute;digo aberto e baseado em padr&otilde;es desenvolvido pela
<A HREF="http://www.apple.com/">Apple Inc.</A> para o OS<SUP>&reg;</SUP> X e
outros sistemas operacionais similares ao UNIX<SUP>&reg;</SUP>.</P>
</TD>
<TD><A HREF="http://www.cups.org/"><IMG SRC="images/cups-icon.png" WIDTH="128"
HEIGHT="128" ALT="CUPS"></A></TD>
</TR>
</TABLE>
<TABLE CLASS="indent" SUMMARY="">
<TR><TD VALIGN="top" STYLE="border-right: dotted thin #cccccc; padding-right: 20px;">
<H2>CUPS para usu&aacute;rios</H2>
<P><A HREF="help/overview.html">Vis&atilde;o geral do CUPS</A></P>
<P><A HREF="help/options.html">Impress&atilde;o e op&ccedil;&otilde;es em linha de comando</A></P>
<P><A HREF="help/whatsnew.html">O que h&aacute; de novo no CUPS 1.7</A></P>
<P><A HREF="http://www.cups.org/newsgroups.php?gcups.general">F&oacute;rum de usu&aacute;rios</A></P>
</TD><TD VALIGN="top" STYLE="border-right: dotted thin #cccccc; padding-left: 20px; padding-right: 20px;">
<H2>CUPS para administradores</H2>
<P><A HREF="admin">Adicionar impressoras e classes</A></P>
<P><A HREF="help/policies.html">Gerenciar pol&iacute;ticas de opera&ccedil;&atilde;o</A></P>
<P><A HREF="help/accounting.html">B&aacute;sico de contabilidade de impress&atilde;o</A></P>
<P><A HREF="help/security.html">Seguran&ccedil;a do servidor</A></P>
<P><A HREF="help/kerberos.html">Usar autentica&ccedil;&atilde;o via kerberos</A></P>
<P><A HREF="help/network.html">Usar impressoras de rede</A></P>
<P><A HREF="help/ref-cupsd-conf.html">Refer&ecirc;ncia para o cupsd.conf</A></P>
<P><A HREF="http://www.cups.org/ppd.php">Encontrar drivers de impressora</A></P>
</TD><TD VALIGN="top" STYLE="padding-left: 20px;">
<H2>CUPS para desenvolvedores</H2>
<P><A HREF="help/api-overview.html">Introdu&ccedil;&atilde;o &agrave; programa&ccedil;&atilde;o do CUPS</A></P>
<P><A HREF="help/api-cups.html">API do CUPS</A></P>
<P><A HREF="help/api-filter.html">Programa&ccedil;&atilde;o de filtros e retaguarda</A></P>
<P><A HREF="help/api-httpipp.html">APIs HTTP e IPP</A></P>
<P><A HREF="help/api-ppd.html">API PPD</A></P>
<P><A HREF="help/api-raster.html">API de rasteriza&ccedil;&atilde;o</A></P>
<P><A HREF="help/ref-ppdcfile.html">Refer&ecirc;ncia para o compilador de arquivos de informa&ccedil;&atilde;o de driver PPD</A></P>
<P><A HREF="http://www.cups.org/newsgroups.php?gcups.development">F&oacute;rum de desenvolvedores</A></P>
</TD></TR>
</TABLE>
</TD></TR>
<TR><TD>&nbsp;</TD></TR>
<TR><TD CLASS="trailer">CUPS e o logo do CUPS s&atilde;o marcas registradas de
<A HREF="http://www.apple.com">Apple Inc.</A> Copyright 2007-2014 Apple
Inc. Todos os direitos reservados.</TD></TR>
</TABLE>
</BODY>
</HTML>
+65
Ver Arquivo
@@ -0,0 +1,65 @@
README.txt - 2014-08-28
-----------------------
INTRODUCTION
This directory contains the IPP Everywhere Printer Self-Certification tools.
In addition to the files in this directory, you must also download and
extract one or more PWG Raster Format file archives from:
http://ftp.pwg.org/pub/pwg/ipp/examples/
These archives are used for the Document Data tests.
CONTENTS
Scripts for running the self-certification tests:
bonjour-tests.bat Bonjour Tests for Windows
bonjour-tests.sh Bonjour Tests for Linux and OS X
ipp-tests.bat IPP Tests for Windows
ipp-tests.sh IPP Tests for Linux and OS X
document-tests.bat Document Data Tests for Windows
document-tests.sh Document Data Tests for Linux and OS X
Tools:
ippfind Tool for finding printers with Bonjour/DNS-SD
ippserver Sample IPP server, useful for testing
ipptool IPP test tool
Documentation:
LICENSE.txt CUPS software license
man-*.html HTML documentation for the tools
README.txt This README file
GETTING SUPPORT AND OTHER RESOURCES
The IPP Everywhere home page provides access to all information relevant to
IPP Eveywhere:
http://www.pwg.org/ipp/everywhere.html
The "ippeveselfcert@pwg.org" mailing list is used to discuss IPP Everywhere
Printer Self-Certification. You can subscribe from the following page:
https://www.pwg.org/mailman/listinfo/ippeveselfcert
LEGAL STUFF
These tools are Copyright 2014 by The Printer Working Group and Copyright
2007-2014 by Apple Inc. CUPS and the CUPS logo are trademarks of Apple Inc.
PWG and IPP Everywhere are trademarks of the IEEE-ISTO.
CUPS is provided under the terms of version 2 of the GNU General Public
License and GNU Library General Public License. This program is distributed
in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the file "LICENSE.txt" for more information.
+42
Ver Arquivo
@@ -0,0 +1,42 @@
#
# "$Id: bonjour-access-tests.test 12120 2014-08-27 20:52:33Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 5: Bonjour Tests.
#
# Copyright 2014 by The Printer Working Group.
# Copyright 2007-2013 by Apple Inc.
# Copyright 2001-2006 by Easy Software Products. All rights reserved.
#
# These coded instructions, statements, and computer programs are the
# property of Apple Inc. and are protected by Federal copyright
# law. Distribution and use rights are outlined in the file "LICENSE.txt"
# which should have been included with this file. If this file is
# file is missing or damaged, see the license at "http://www.cups.org/".
#
# Usage:
#
# ./ipptool -tI printer-uri bonjour-access-tests.test
#
FILE-ID "org.pwg.ipp-everywhere.20140826.bonjour"
{
# The name of the test...
NAME "Validate access using Get-Printer-Attributes"
# The operation to use
OPERATION Get-Printer-Attributes
# Attributes, starting in the operation group...
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR language attributes-natural-language en
ATTR uri printer-uri $uri
# What statuses are OK?
STATUS successful-ok
}
#
# End of "$Id: bonjour-access-tests.test 12120 2014-08-27 20:52:33Z msweet $".
#
+391
Ver Arquivo
@@ -0,0 +1,391 @@
@echo off
::
:: "$Id: bonjour-tests.bat 12249 2014-11-14 12:54:05Z msweet $"
::
:: IPP Everywhere Printer Self-Certification Manual 1.0: Section 5: Bonjour Tests.
::
:: Copyright 2014 by The Printer Working Group.
::
:: This program may be copied and furnished to others, and derivative works
:: that comment on, or otherwise explain it or assist in its implementation may
:: be prepared, copied, published and distributed, in whole or in part, without
:: restriction of any kind, provided that the above copyright notice and this
:: paragraph are included on all such copies and derivative works.
::
:: The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
:: WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
:: WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
::
:: Usage:
::
:: bonjour-tests.bat 'Printer Name'
::
set PLIST=%1 Bonjour Results.plist
echo Sending output to "%PLIST%"...
:: Write the standard XML plist header...
echo ^<?xml version=^"1.0^" encoding=^"UTF-8^"?^> >"%PLIST%"
echo ^<!DOCTYPE plist PUBLIC ^"-//Apple Computer//DTD PLIST 1.0//EN^" ^"http://www.apple.com/DTDs/PropertyList-1.0.dtd^"^> >>"%PLIST%"
echo ^<plist version=^"1.0^"^> >>"%PLIST%"
echo ^<dict^> >>"%PLIST%"
echo ^<key^>Tests^</key^>^<array^> >>"%PLIST%"
set total=0
set pass=0
set fail=0
set skip=0
:: B-1. IPP Browse test: Printers appear in a search for "_ipp._tcp,_print" services?
set /a total+=1
set <NUL /p="B-1. IPP Browse test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-1. IPP Browse test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
set result=FAIL
ippfind _ipp._tcp,_print.local. --name "%1" --quiet && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
:: B-2. IPP TXT keys test: The IPP TXT record contains all required keys.
set /a total+=1
set <NUL /p="B-2. IPP TXT keys test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-2. IPP TXT keys test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
set result=FAIL
ippfind "%1._ipp._tcp.local." --txt adminurl --txt pdl --txt rp --txt UUID --quiet && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo adminurl="{txt_adminurl}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo pdl="{txt_pdl}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo rp="{txt_rp}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo UUID="{txt_uuid}" ";" >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo adminurl="{txt_adminurl}" ";"
ippfind "%1._ipp._tcp.local." -x echo pdl="{txt_pdl}" ";"
ippfind "%1._ipp._tcp.local." -x echo rp="{txt_rp}" ";"
ippfind "%1._ipp._tcp.local." -x echo UUID="{txt_uuid}" ";"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
:: B-3. IPP Resolve test: Printer responds to an IPP Get-Printer-Attributes request using the resolved hostname, port, and resource path.
set /a total+=1
set <NUL /p="B-3. IPP Resolve test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-3. IPP Resolve test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
set result=FAIL
(ippfind "%1._ipp._tcp.local." --ls && set result=PASS) >nul:
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipp._tcp.local." --ls >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
:: B-4. IPP TXT values test: The IPP TXT record values match the reported IPP attribute values.
set /a total+=1
set <NUL /p="B-4. IPP TXT values test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-4. IPP TXT values test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
set result=FAIL
ippfind "%1._ipp._tcp.local." --txt-adminurl ^^^(http:^|https:^)// --txt-pdl image/pwg-raster --txt-pdl image/jpeg --txt-rp ^^ipp/^(print^|print/[^^/]+^)$ --txt-UUID ^^[0-9a-fA-F]{8,8}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{12,12}$ -x ipptool -q -d "ADMINURL={txt_adminurl}" -d "UUID={txt_uuid}" "{}" bonjour-value-tests.test ";" && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo adminurl="{txt_adminurl}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo pdl="{txt_pdl}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo rp="{txt_rp}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo UUID="{txt_uuid}" ";" >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x ipptool -t "{}" bonjour-value-tests.test ";" | findstr /r [TG][EO][DT]: >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
ippfind "%1._ipp._tcp.local." -x echo adminurl="{txt_adminurl}" ";"
ippfind "%1._ipp._tcp.local." -x echo pdl="{txt_pdl}" ";"
ippfind "%1._ipp._tcp.local." -x echo rp="{txt_rp}" ";"
ippfind "%1._ipp._tcp.local." -x echo UUID="{txt_uuid}" ";"
ippfind "%1._ipp._tcp.local." -x ipptool -t "{}" bonjour-value-tests.test ";" | findstr /r [TG][EO][DT]:
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
:: B-5. TLS tests: Performed only if TLS is supported
set /a total+=1
set <NUL /p="B-5. TLS tests: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5. TLS tests^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
set result=SKIP
ippfind "%1._ipp._tcp.local." --txt tls --quiet && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
set HAVE_TLS=1
) else (
set /a skip+=1
set HAVE_TLS=0
)
echo %result%
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
:: B-5.1 HTTP Upgrade test: Printer responds to an IPP Get-Printer-Attributes request after doing an HTTP Upgrade to TLS.
set /a total+=1
set <NUL /p="B-5.1 HTTP Upgrade test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5.1 HTTP Upgrade test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
if "%HAVE_TLS%" == "1" (
set result=FAIL
ippfind "%1._ipp._tcp.local." -x ipptool -E -q "{}" bonjour-access-tests.test ";" && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST"
ippfind "%1._ipp._tcp.local." -x ipptool -E -q "{}" bonjour-access-tests.test ";" >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
) else (
set /a skip+=1
set result=SKIP
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
) else (
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
)
echo ^</dict^> >>"%PLIST%"
:: B-5.2 IPPS Browse test: Printer appears in a search for "_ipps._tcp,_print" services.
set /a total+=1
set <NUL /p="B-5.2 IPPS Browse test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5.2 IPPS Browse test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
if "%HAVE_TLS%" == "1" (
set result=FAIL
ippfind _ipps._tcp,_print.local. --name "%1" --quiet && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
)
) else (
set /a skip+=1
set result=SKIP
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
) else (
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
)
echo ^</dict^> >>"%PLIST%"
:: B-5.3 IPPS TXT keys test: The TXT record for IPPS contains all required keys
set /a total+=1
set <NUL /p="B-5.3 IPPS TXT keys test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5.3 IPPS TXT keys test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
if "%HAVE_TLS%" == "1" (
set result=FAIL
ippfind "%1._ipps._tcp.local." --txt adminurl --txt pdl --txt rp --txt TLS --txt UUID --quiet && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo adminurl={txt_adminurl}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo pdl={txt_pdl}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo rp={txt_rp}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo TLS={txt_tls}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo UUID={txt_uuid}" ";" >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
) else (
set /a skip+=1
set result=SKIP
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo adminurl={txt_adminurl}" ";"
ippfind "%1._ipps._tcp.local." -x echo pdl={txt_pdl}" ";"
ippfind "%1._ipps._tcp.local." -x echo rp={txt_rp}" ";"
ippfind "%1._ipps._tcp.local." -x echo TLS={txt_tls}" ";"
ippfind "%1._ipps._tcp.local." -x echo UUID={txt_uuid}" ";"
) else (
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
)
echo ^</dict^> >>"%PLIST%"
:: B-5.4 IPPS Resolve test: Printer responds to an IPPS Get-Printer-Attributes request using the resolved hostname, port, and resource path.
set /a total+=1
set <NUL /p="B-5.4 IPPS Resolve test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5.4 IPPS Resolve test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
if "%HAVE_TLS%" == "1" (
set result=FAIL
(ippfind "%1._ipps._tcp.local." --ls && set result=PASS) >nul:
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipps._tcp.local." --ls >>"%PLIST%"
echo ^</string^>^</array^> >>"%PLIST%"
)
) else (
set /a skip+=1
set result=SKIP
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
) else (
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
)
echo ^</dict^> >>"%PLIST%"
:: B-5.5 IPPS TXT values test: The TXT record values for IPPS match the reported IPPS attribute values.
set /a total+=1
set <NUL /p="B-5.5 IPPS TXT values test: "
echo ^<dict^>^<key^>Name^</key^>^<string^>B-5.5 IPPS TXT values test^</string^> >>"%PLIST%"
echo ^<key^>FileId^</key^>^<string^>org.pwg.ipp-everywhere.20140826.bonjour^</string^> >>"%PLIST%"
if "%HAVE_TLS%" == "1" (
set result=FAIL
ippfind "%1._ipps._tcp.local." --txt-adminurl ^^^(http:^|https:^)// --txt-pdl image/pwg-raster --txt-pdl image/jpeg --txt-rp ^^ipp/^(print^|print/[^^/]+^)$ --txt-UUID ^^[0-9a-fA-F]{8,8}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{12,12}$ -x ipptool -q "{}" bonjour-value-tests.test ";" && set result=PASS
if "%result%" == "PASS" (
set /a pass+=1
) else (
set /a fail+=1
echo ^<key^>Errors^</key^>^<array^>^<string^> >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo adminurl="{txt_adminurl}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo pdl="{txt_pdl}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo rp="{txt_rp}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo TLS="{txt_tls}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo UUID="{txt_uuid}" ";" >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x ipptool -t "{}" bonjour-value-tests.test ";" | findstr /r [TG][EO][DT]: >>"%PLIST"
echo ^</string^>^</array^> >>"%PLIST%"
)
) else (
set /a skip+=1
set result=SKIP
)
echo %result%
if "%result%" == "FAIL" (
echo ^<key^>Successful^</key^>^<false /^> >>"%PLIST%"
ippfind "%1._ipps._tcp.local." -x echo adminurl="{txt_adminurl}" ";"
ippfind "%1._ipps._tcp.local." -x echo pdl="{txt_pdl}" ";"
ippfind "%1._ipps._tcp.local." -x echo rp="{txt_rp}" ";"
ippfind "%1._ipps._tcp.local." -x echo TLS="{txt_tls}" ";"
ippfind "%1._ipps._tcp.local." -x echo UUID="{txt_uuid}" ";"
ippfind "%1._ipp._tcp.local." -x ipptool -t "{}" bonjour-value-tests.test ";" | findstr /r [TG][EO][DT]:
) else (
if "%result%" == "SKIP" (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
echo ^<key^>Skipped^</key^>^<true /^> >>"%PLIST%"
) else (
echo ^<key^>Successful^</key^>^<true /^> >>"%PLIST%"
)
)
echo ^</dict^> >>"%PLIST%"
:: Finish up...
echo ^</array^> >>"%PLIST%"
echo ^<key^>Successful^</key^> >>"%PLIST%"
if %fail% gtr 0 (
echo ^<false /^> >>"%PLIST%"
) else (
echo ^<true /^> >>"%PLIST%"
)
echo ^</dict^> >>"%PLIST%"
echo ^</plist^> >>"%PLIST%"
set /a score=%pass% + %skip%
set /a score=100 * %score% / %total%
echo Summary: %total% tests, %pass% passed, %fail% failed, %skip% skipped
echo Score: %score%%%
::
:: End of "$Id: bonjour-tests.bat 12249 2014-11-14 12:54:05Z msweet $".
::
Arquivo executável
+344
Ver Arquivo
@@ -0,0 +1,344 @@
#!/bin/sh
#
# "$Id: bonjour-tests.sh 12144 2014-09-02 13:40:27Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 5: Bonjour Tests.
#
# Copyright 2014 by The Printer Working Group.
#
# This program may be copied and furnished to others, and derivative works
# that comment on, or otherwise explain it or assist in its implementation may
# be prepared, copied, published and distributed, in whole or in part, without
# restriction of any kind, provided that the above copyright notice and this
# paragraph are included on all such copies and derivative works.
#
# The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
# WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
# WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
#
# Usage:
#
# ./bonjour-tests.sh "Printer Name"
#
if test -x ../test/ippfind-static; then
IPPFIND="../test/ippfind-static"
elif test -x ./ippfind; then
IPPFIND="./ippfind"
else
IPPFIND="ippfind"
fi
if test -x ../test/ipptool-static; then
IPPTOOL="../test/ipptool-static"
elif test -x ./ipptool; then
IPPTOOL="./ipptool"
else
IPPTOOL="ipptool"
fi
PLIST="$1 Bonjour Results.plist"
#
# Figure out the proper echo options...
#
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
ac_n=-n
ac_c=
else
ac_n=
ac_c='\c'
fi
# Special case "_failN" name to show bad/missing TXT keys
if test "$2" = _fail2 -o "$2" = _fail4 -o "$2" = _fail5.3 -o "$2" = _fail5.5; then
echo "FAIL"
echo "<key>Errors</key><array>" >>"$PLIST"
if test "${IPPFIND_TXT_ADMINURL:-NOTSET}" = NOTSET; then
echo " adminurl is not set."
echo "<string>adminurl is not set.</string>" >>"$PLIST"
elif test "$2" = _fail4 -o "$2" = _fail5.5; then
case "$IPPFIND_TXT_ADMINURL" in
http://* | https://*)
;;
*)
echo " adminurl has bad value '$IPPFIND_TXT_ADMINURL'."
echo "<string>adminurl has bad value '$IPPFIND_TXT_ADMINURL'.</string>" >>"$PLIST"
;;
esac
fi
if test "${IPPFIND_TXT_PDL:-NOTSET}" = NOTSET; then
echo " pdl is not set."
echo "<string>pdl is not set.</string>" >>"$PLIST"
elif test "$2" = _fail4 -o "$2" = _fail5.5; then
case "$IPPFIND_TXT_PDL" in
*image/jpeg*)
;;
*)
echo " pdl is missing image/jpeg: '$IPPFIND_TXT_PDL'"
echo "<string>pdl is missing image/jpeg: '$IPPFIND_TXT_PDL'.</string>" >>"$PLIST"
;;
esac
case "$IPPFIND_TXT_PDL" in
*image/pwg-raster*)
;;
*)
echo " pdl is missing image/pwg-raster: '$IPPFIND_TXT_PDL'"
echo "<string>pdl is missing image/pwg-raster: '$IPPFIND_TXT_PDL'.</string>" >>"$PLIST"
;;
esac
fi
if test "${IPPFIND_TXT_RP:-NOTSET}" = NOTSET; then
echo " rp is not set."
echo "<string>rp is not set.</string>" >>"$PLIST"
elif test "$2" = _fail4 -o "$2" = _fail5.5; then
case "$IPPFIND_TXT_RP" in
ipp/print | ipp/print/*)
;;
*)
echo " rp has bad value '$IPPFIND_TXT_RP'"
echo "<string>rp has bad value '$IPPFIND_TXT_RP'.</string>" >>"$PLIST"
;;
esac
fi
if test "${IPPFIND_TXT_UUID:-NOTSET}" = NOTSET; then
echo " UUID is not set."
echo "<string>UUID is not set.</string>" >>"$PLIST"
elif test "$2" = _fail4 -o "$2" = _fail5.5; then
case "$IPPFIND_TXT_UUID" in
[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]-[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]-[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]-[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]-[0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F])
;;
*)
echo " UUID has bad value '$IPPFIND_TXT_UUID'"
echo "<string>UUID has bad value '$IPPFIND_TXT_UUID'.</string>" >>"$PLIST"
;;
esac
fi
if test "$2" = _fail4 -o "$2" = _fail5.5; then
$IPPTOOL -t $IPPFIND_SERVICE_URI bonjour-value-tests.test
$IPPTOOL -t $IPPFIND_SERVICE_URI bonjour-value-tests.test | egrep '(GOT|EXPECTED):' | sed -e '1,$s/^[ ]*//' | awk '{print "<string>" $0 "</string>" }' >>"$PLIST"
fi
echo "</array>" >>"$PLIST"
echo "<key>Successful</key><false />" >>"$PLIST"
echo "</dict>" >>"$PLIST"
exit 0
fi
# Write the standard XML plist header...
cat >"$PLIST" <<EOF
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Tests</key><array>
EOF
total=0
pass=0
fail=0
skip=0
# start_test "name"
start_test() {
total=`expr $total + 1`
echo $ac_n "$1: $ac_c"
echo "<dict><key>Name</key><string>$1</string>" >>"$PLIST"
echo "<key>FileId</key><string>org.pwg.ipp-everywhere.20140826.bonjour</string>" >>"$PLIST"
}
# end_test PASS/FAIL/SKIP
end_test() {
echo $1
if test $1 = FAIL; then
echo "<key>Successful</key><false />" >>"$PLIST"
elif test $1 = SKIP; then
echo "<key>Successful</key><true />" >>"$PLIST"
echo "<key>Skipped</key><true />" >>"$PLIST"
else
echo "<key>Successful</key><true />" >>"$PLIST"
fi
echo "</dict>" >>"$PLIST"
}
# B-1. IPP Browse test: Printers appear in a search for "_ipp._tcp,_print" services?
start_test "B-1. IPP Browse test"
$IPPFIND _ipp._tcp,_print.local. --name "$1" --quiet
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
end_test FAIL
fi
# B-2. IPP TXT keys test: The IPP TXT record contains all required keys.
start_test "B-2. IPP TXT keys test"
$IPPFIND "$1._ipp._tcp.local." --txt adminurl --txt pdl --txt rp --txt UUID --quiet
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
$IPPFIND "$1._ipp._tcp.local." -x ./bonjour-tests.sh '{service_name}' _fail2 \;
fi
# B-3. IPP Resolve test: Printer responds to an IPP Get-Printer-Attributes request using the resolved hostname, port, and resource path.
start_test "B-3. IPP Resolve test"
$IPPFIND "$1._ipp._tcp.local." --ls >/dev/null
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
echo "<key>Errors</key><array>" >>"$PLIST"
$IPPFIND "$1._ipp._tcp.local." --ls | awk '{ print "<string>" $0 "</string>" }' >>"$PLIST"
echo "</array>" >>"$PLIST"
end_test FAIL
fi
# B-4. IPP TXT values test: The IPP TXT record values match the reported IPP attribute values.
start_test "B-4. IPP TXT values test"
$IPPFIND "$1._ipp._tcp.local." --txt-adminurl '^(http:|https:)//' --txt-pdl 'image/pwg-raster' --txt-pdl 'image/jpeg' --txt-rp '^ipp/(print|print/[^/]+)$' --txt-UUID '^[0-9a-fA-F]{8,8}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{12,12}$' -x $IPPTOOL -q '{}' bonjour-value-tests.test \;
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
$IPPFIND "$1._ipp._tcp.local." -x ./bonjour-tests.sh '{service_name}' _fail4 \;
fi
# B-5. TLS tests: Performed only if TLS is supported
start_test "B-5. TLS tests"
$IPPFIND "$1._ipp._tcp.local." --txt tls --quiet
if test $? = 0; then
pass=`expr $pass + 1`
HAVE_TLS=1
end_test PASS
else
skip=`expr $skip + 1`
HAVE_TLS=0
end_test SKIP
fi
# B-5.1 HTTP Upgrade test: Printer responds to an IPP Get-Printer-Attributes request after doing an HTTP Upgrade to TLS.
start_test "B-5.1 HTTP Upgrade test"
if test $HAVE_TLS = 1; then
error=`$IPPFIND "$1._ipp._tcp.local." -x $IPPTOOL -E -q '{}' bonjour-access-tests.test \; 2>&1`
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
echo "<key>Errors</key><array><string>$error</string></array>" >>"$PLIST"
end_test FAIL
echo " $error"
fi
else
skip=`expr $skip + 1`
end_test SKIP
fi
# B-5.2 IPPS Browse test: Printer appears in a search for "_ipps._tcp,_print" services.
start_test "B-5.2 IPPS Browse test"
if test $HAVE_TLS = 1; then
$IPPFIND _ipps._tcp,_print.local. --name "$1" --quiet
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
end_test FAIL
fi
else
skip=`expr $skip + 1`
end_test SKIP
fi
# B-5.3 IPPS TXT keys test: The TXT record for IPPS contains all required keys
start_test "B-5.3 IPPS TXT keys test"
if test $HAVE_TLS = 1; then
$IPPFIND "$1._ipps._tcp.local." --txt adminurl --txt pdl --txt rp --txt TLS --txt UUID --quiet
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
$IPPFIND "$1._ipps._tcp.local." -x ./bonjour-tests.sh '{service_name}' _fail5.3 \;
fi
else
skip=`expr $skip + 1`
end_test SKIP
fi
# B-5.4 IPPS Resolve test: Printer responds to an IPPS Get-Printer-Attributes request using the resolved hostname, port, and resource path.
start_test "B-5.4 IPPS Resolve test"
if test $HAVE_TLS = 1; then
$IPPFIND "$1._ipps._tcp.local." --ls >/dev/null
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
echo "<key>Errors</key><array>" >>"$PLIST"
$IPPFIND "$1._ipps._tcp.local." --ls | awk '{ print "<string>" $0 "</string>" }' >>"$PLIST"
echo "</array>" >>"$PLIST"
end_test FAIL
fi
else
skip=`expr $skip + 1`
end_test SKIP
fi
# B-5.5 IPPS TXT values test: The TXT record values for IPPS match the reported IPPS attribute values.
start_test "B-5.5 IPPS TXT values test"
if test $HAVE_TLS = 1; then
$IPPFIND "$1._ipps._tcp.local." --txt-adminurl '^(http:|https:)//' --txt-pdl 'image/pwg-raster' --txt-pdl 'image/jpeg' --txt-rp '^ipp/(print|print/[^/]+)$' --txt-UUID '^[0-9a-fA-F]{8,8}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{4,4}-[0-9a-fA-F]{12,12}$' -x $IPPTOOL -q '{}' bonjour-value-tests.test \;
if test $? = 0; then
pass=`expr $pass + 1`
end_test PASS
else
fail=`expr $fail + 1`
$IPPFIND "$1._ipps._tcp.local." -x ./bonjour-tests.sh '{service_name}' _fail5.5 \;
fi
else
skip=`expr $skip + 1`
end_test SKIP
fi
# Finish up...
if test $fail -gt 0; then
cat >>"$PLIST" <<EOF
</array>
<key>Successful</key>
<false />
EOF
else
cat >>"$PLIST" <<EOF
</array>
<key>Successful</key>
<true />
EOF
fi
cat >>"$PLIST" <<EOF
</dict>
</plist>
EOF
score=`expr $pass + $skip`
score=`expr 100 \* $score / $total`
echo "Summary: $total tests, $pass passed, $fail failed, $skip skipped"
echo "Score: ${score}%"
#
# End of "$Id: bonjour-tests.sh 12144 2014-09-02 13:40:27Z msweet $".
#
+47
Ver Arquivo
@@ -0,0 +1,47 @@
#
# "$Id: bonjour-value-tests.test 12143 2014-09-02 13:37:30Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 5: Bonjour Tests.
#
# Copyright 2014 by The Printer Working Group.
# Copyright 2007-2013 by Apple Inc.
# Copyright 2001-2006 by Easy Software Products. All rights reserved.
#
# These coded instructions, statements, and computer programs are the
# property of Apple Inc. and are protected by Federal copyright
# law. Distribution and use rights are outlined in the file "LICENSE.txt"
# which should have been included with this file. If this file is
# file is missing or damaged, see the license at "http://www.cups.org/".
#
# Usage:
#
# (run from within ippfind)
# ippfind ... -x ipptool -t "{}" bonjour-value-tests.test ";"
#
FILE-ID "org.pwg.ipp-everywhere.20140826.bonjour"
{
# The name of the test...
NAME "Validate TXT record values using Get-Printer-Attributes"
# The operation to use
OPERATION Get-Printer-Attributes
# Attributes, starting in the operation group...
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR language attributes-natural-language en
ATTR uri printer-uri $uri
# What statuses are OK?
STATUS successful-ok
# What attributes do we expect?
EXPECT printer-more-info OF-TYPE uri IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "$ENV[IPPFIND_TXT_ADMINURL]"
EXPECT printer-uuid OF-TYPE uri IN-GROUP printer-attributes-tag COUNT 1 WITH-VALUE "urn:uuid:$ENV[IPPFIND_TXT_UUID]"
}
#
# End of "$Id: bonjour-value-tests.test 12143 2014-09-02 13:37:30Z msweet $".
#
+28
Ver Arquivo
@@ -0,0 +1,28 @@
@echo off
::
:: "$Id: document-tests.bat 12249 2014-11-14 12:54:05Z msweet $"
::
:: IPP Everywhere Printer Self-Certification Manual 1.0: Section 7: Document Data Tests.
::
:: Copyright 2014 by The Printer Working Group.
::
:: This program may be copied and furnished to others, and derivative works
:: that comment on, or otherwise explain it or assist in its implementation may
:: be prepared, copied, published and distributed, in whole or in part, without
:: restriction of any kind, provided that the above copyright notice and this
:: paragraph are included on all such copies and derivative works.
::
:: The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
:: WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
:: WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
::
:: Usage:
::
:: document-tests.bat 'Printer Name'
::
ippfind "%1._ipp._tcp.local." -x ipptool -P "\"%1 Document Results.plist\"" -I "{}" document-tests.test ";"
::
:: End of "$Id: document-tests.bat 12249 2014-11-14 12:54:05Z msweet $".
::
Arquivo executável
+59
Ver Arquivo
@@ -0,0 +1,59 @@
#!/bin/sh
#
# "$Id: document-tests.sh 12127 2014-08-28 18:57:27Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 7: Document Data Tests.
#
# Copyright 2014 by The Printer Working Group.
#
# This program may be copied and furnished to others, and derivative works
# that comment on, or otherwise explain it or assist in its implementation may
# be prepared, copied, published and distributed, in whole or in part, without
# restriction of any kind, provided that the above copyright notice and this
# paragraph are included on all such copies and derivative works.
#
# The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
# WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
# WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
#
# Usage:
#
# ./document-tests.sh "Printer Name"
#
if test -x ../test/ippfind-static; then
IPPFIND="../test/ippfind-static"
elif test -x ./ippfind; then
IPPFIND="./ippfind"
else
IPPFIND="ippfind"
fi
if test -x ../test/ipptool-static; then
IPPTOOL="../test/ipptool-static"
elif test -x ./ipptool; then
IPPTOOL="./ipptool"
else
IPPTOOL="ipptool"
fi
for file in color.jpg document-a4.pdf document-letter.pdf; do
if test ! -f $file -a -f ../test/$file; then
ln -s ../test/$file .
fi
done
if test "`ls -d pwg-raster-samples-*dpi-20111130 2>/dev/null`" = ""; then
echo "You must first download and extract the PWG Raster Format sample files from:"
echo ""
echo " http://ftp.pwg.org/pub/pwg/ipp/examples/"
echo ""
echo "Before you can run this script."
exit 1
fi
$IPPFIND "$1._ipp._tcp.local." -x $IPPTOOL -P "$1 Document Results.plist" -I '{}' document-tests.test \;
#
# End of "$Id: document-tests.sh 12127 2014-08-28 18:57:27Z msweet $".
#
+618
Ver Arquivo
@@ -0,0 +1,618 @@
#
# "$Id: document-tests.test 12127 2014-08-28 18:57:27Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 7: Document Data Tests.
#
# Copyright 2014 by The Printer Working Group.
# Copyright 2007-2013 by Apple Inc.
# Copyright 2001-2006 by Easy Software Products. All rights reserved.
#
# These coded instructions, statements, and computer programs are the
# property of Apple Inc. and are protected by Federal copyright
# law. Distribution and use rights are outlined in the file "LICENSE.txt"
# which should have been included with this file. If this file is
# file is missing or damaged, see the license at "http://www.cups.org/".
#
# Usage:
#
# ./ipptool -tI printer-uri document-tests.test
#
# This test file depends on document data files available at:
#
# http://ftp.pwg.org/pub/pwg/ipp/examples
#
# The ZIP files should be extracted in the same directory as the test files,
# for example the 600dpi files will exist in a directory called
# "pwg-raster-samples-600dpi-20111130". The script used to generate the raster
# data is available in the "everywhere" subdirectory of the CUPS source code.
#
FILE-ID "org.pwg.ipp-everywhere.20140826.document"
{
NAME "D-1. PWG Raster Format Tests (mandatory)"
OPERATION Get-Printer-Attributes
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
STATUS successful-ok
EXPECT compression-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "deflate" DEFINE-MATCH HAVE_DEFLATE
EXPECT compression-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "gzip" DEFINE-MATCH HAVE_GZIP
EXPECT document-format-supported OF-TYPE mimeMediaType IN-GROUP printer-attributes-tag WITH-VALUE "image/pwg-raster"
EXPECT pwg-raster-document-resolution-supported OF-TYPE resolution IN-GROUP printer-attributes-tag DEFINE-VALUE RASTER_RESOLUTION
EXPECT pwg-raster-document-type-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "black-1" DEFINE-MATCH HAVE_BLACK
EXPECT pwg-raster-document-type-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "sgray-8" DEFINE-MATCH HAVE_SGRAY
EXPECT pwg-raster-document-type-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "srgb-8" DEFINE-MATCH HAVE_SRGB
EXPECT pwg-raster-document-type-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "cmyk-8" DEFINE-MATCH HAVE_CMYK
}
#### 1.1 NO COMPRESSION ####
{
SKIP-IF-NOT-DEFINED HAVE_BLACK
NAME "D-1.1 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, black-1"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, black-1"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/black-1/color.jpg-4x6-black-1-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SGRAY
NAME "D-1.1 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, sgray-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, sgray-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/sgray-8/color.jpg-4x6-sgray-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SRGB
NAME "D-1.1 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, srgb-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, srgb-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/srgb-8/color.jpg-4x6-srgb-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_CMYK
NAME "D-1.1 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, cmyk-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, cmyk-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/cmyk-8/color.jpg-4x6-cmyk-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### 1.2 DEFLATE COMPRESSION ####
{
SKIP-IF-NOT-DEFINED HAVE_BLACK
SKIP-IF-NOT-DEFINED HAVE_DEFLATE
NAME "D-1.2 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, black-1, deflate"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, black-1\, deflate"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression deflate
COMPRESSION deflate
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/black-1/color.jpg-4x6-black-1-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SGRAY
SKIP-IF-NOT-DEFINED HAVE_DEFLATE
NAME "D-1.2 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, sgray-8, deflate"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, sgray-8\, deflate"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression deflate
COMPRESSION deflate
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/sgray-8/color.jpg-4x6-sgray-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SRGB
SKIP-IF-NOT-DEFINED HAVE_DEFLATE
NAME "D-1.2 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, srgb-8, deflate"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, srgb-8\, deflate"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression deflate
COMPRESSION deflate
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/srgb-8/color.jpg-4x6-srgb-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_CMYK
SKIP-IF-NOT-DEFINED HAVE_DEFLATE
NAME "D-1.2 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, cmyk-8, deflate"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, cmyk-8\, deflate"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression deflate
COMPRESSION deflate
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/cmyk-8/color.jpg-4x6-cmyk-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### 1.3 GZIP COMPRESSION ####
{
SKIP-IF-NOT-DEFINED HAVE_BLACK
SKIP-IF-NOT-DEFINED HAVE_GZIP
NAME "D-1.3 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, black-1, gzip"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, black-1\, gzip"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression gzip
COMPRESSION gzip
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/black-1/color.jpg-4x6-black-1-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SGRAY
SKIP-IF-NOT-DEFINED HAVE_GZIP
NAME "D-1.3 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, sgray-8, gzip"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, sgray-8\, gzip"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression gzip
COMPRESSION gzip
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/sgray-8/color.jpg-4x6-sgray-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SRGB
SKIP-IF-NOT-DEFINED HAVE_GZIP
NAME "D-1.3 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, srgb-8, gzip"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, srgb-8\, gzip"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression gzip
COMPRESSION gzip
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/srgb-8/color.jpg-4x6-srgb-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_CMYK
SKIP-IF-NOT-DEFINED HAVE_GZIP
NAME "D-1.3 Print color.jpg-4x6.pwg @ $RASTER_RESOLUTION, cmyk-8, gzip"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg-4x6.pwg @ $RASTER_RESOLUTION\, cmyk-8\, gzip"
ATTR mimeMediaType document-format "image/pwg-raster"
ATTR keyword compression gzip
COMPRESSION gzip
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/cmyk-8/color.jpg-4x6-cmyk-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### 1.4 A4 TESTS ####
{
SKIP-IF-NOT-DEFINED HAVE_BLACK
NAME "D-1.4 Print document-a4.pwg @ $RASTER_RESOLUTION, black-1"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-a4.pwg @ $RASTER_RESOLUTION\, black-1"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/black-1/document-a4-black-1-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SGRAY
NAME "D-1.4 Print document-a4.pwg @ $RASTER_RESOLUTION, sgray-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-a4.pwg @ $RASTER_RESOLUTION\, sgray-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/sgray-8/document-a4-sgray-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SRGB
NAME "D-1.4 Print document-a4.pwg @ $RASTER_RESOLUTION, srgb-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-a4.pwg @ $RASTER_RESOLUTION\, srgb-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/srgb-8/document-a4-srgb-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_CMYK
NAME "D-1.4 Print document-a4.pwg @ $RASTER_RESOLUTION, cmyk-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-a4.pwg @ $RASTER_RESOLUTION\, cmyk-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/cmyk-8/document-a4-cmyk-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### 1.5 US Letter TESTS ####
{
SKIP-IF-NOT-DEFINED HAVE_BLACK
NAME "D-1.5 Print document-letter.pwg @ $RASTER_RESOLUTION, black-1"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pwg @ $RASTER_RESOLUTION\, black-1"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/black-1/document-letter-black-1-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SGRAY
NAME "D-1.5 Print document-letter.pwg @ $RASTER_RESOLUTION, sgray-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pwg @ $RASTER_RESOLUTION\, sgray-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/sgray-8/document-letter-sgray-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_SRGB
NAME "D-1.5 Print document-letter.pwg @ $RASTER_RESOLUTION, srgb-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pwg @ $RASTER_RESOLUTION\, srgb-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/srgb-8/document-letter-srgb-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_CMYK
NAME "D-1.5 Print document-letter.pwg @ $RASTER_RESOLUTION, cmyk-8"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pwg @ $RASTER_RESOLUTION\, cmyk-8"
ATTR mimeMediaType document-format "image/pwg-raster"
FILE "pwg-raster-samples-${RASTER_RESOLUTION}-20111130/cmyk-8/document-letter-cmyk-8-600dpi.pwg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### JPEG Tests
{
NAME "D-2. JPEG Tests (mandatory)"
OPERATION Get-Printer-Attributes
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
STATUS successful-ok
EXPECT document-format-supported OF-TYPE mimeMediaType IN-GROUP printer-attributes-tag WITH-VALUE "image/jpeg"
}
{
NAME "D-2.1 Print color.jpg with defaults"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg with defaults"
ATTR mimeMediaType document-format "image/jpeg"
FILE "color.jpg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
NAME "D-2.2 Print color.jpg with copies=2"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg with copies=2"
ATTR mimeMediaType document-format "image/jpeg"
GROUP job-attributes-tag
ATTR integer copies 2
FILE "color.jpg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
NAME "D-2.3 Print color.jpg with print-color-mode=monochrome"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg with print-color-mode=monochrome"
ATTR mimeMediaType document-format "image/jpeg"
GROUP job-attributes-tag
ATTR keyword print-color-mode monochrome
FILE "color.jpg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
NAME "D-2.4 Print color.jpg with media=na_letter_8.5x11in and ipp-attribute-fidelity=true"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg with media=na_letter_8.5x11in and ipp-attribute-fidelity=true"
ATTR mimeMediaType document-format "image/jpeg"
ATTR boolean ipp-attribute-fidelity true
GROUP job-attributes-tag
ATTR keyword media na_letter_8.5x11in
FILE "color.jpg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
NAME "D-2.5 Print color.jpg with media=iso_a4_210x297mm and ipp-attribute-fidelity=true"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "color.jpg with media=iso_a4_210x297mm and ipp-attribute-fidelity=true"
ATTR mimeMediaType document-format "image/jpeg"
ATTR boolean ipp-attribute-fidelity true
GROUP job-attributes-tag
ATTR keyword media iso_a4_210x297mm
FILE "color.jpg"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#### PDF Tests
{
NAME "D-3. PDF Tests (if PDF is supported)"
OPERATION Get-Printer-Attributes
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
STATUS successful-ok
EXPECT document-format-supported OF-TYPE mimeMediaType IN-GROUP printer-attributes-tag WITH-VALUE "application/pdf" DEFINE-MATCH HAVE_PDF
EXPECT sides-supported OF-TYPE keyword IN-GROUP printer-attributes-tag WITH-VALUE "two-sided-long-edge" DEFINE-MATCH HAVE_DUPLEX
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
NAME "D-3.1 Print document-letter.pdf with defaults"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pdf with defaults"
ATTR mimeMediaType document-format "application/pdf"
FILE "document-letter.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
NAME "D-3.2 Print document-letter.pdf with copies=2"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pdf with copies=2"
ATTR mimeMediaType document-format "application/pdf"
GROUP job-attributes-tag
ATTR integer copies 2
FILE "document-letter.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
NAME "D-3.3 Print document-letter.pdf with page-ranges=3-3 and print-color-mode=monochrome"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pdf with page-ranges=3-3 and print-color-mode=monochrome"
ATTR mimeMediaType document-format "application/pdf"
GROUP job-attributes-tag
ATTR rangeOfInteger page-ranges 3-3
ATTR keyword print-color-mode monochrome
FILE "document-letter.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
SKIP-IF-NOT-DEFINED HAVE_DUPLEX
NAME "D-3.4 Print document-letter.pdf with sides=two-sided-long-edge"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pdf with sides=two-sided-long-edge"
ATTR mimeMediaType document-format "application/pdf"
GROUP job-attributes-tag
ATTR keyword sides two-sided-long-edge
FILE "document-letter.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
NAME "D-3.5 Print document-letter.pdf with media=iso_a4_210x297mm and ipp-attribute-fidelity=true"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-letter.pdf with media=iso_a4_210x297mm and ipp-attribute-fidelity=true"
ATTR mimeMediaType document-format "application/pdf"
ATTR boolean ipp-attribute-fidelity true
GROUP job-attributes-tag
ATTR keyword media iso_a4_210x297mm
FILE "document-letter.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
{
SKIP-IF-NOT-DEFINED HAVE_PDF
NAME "D-3.6 Print document-a4.pdf with media=na_letter_8.5x11in and ipp-attribute-fidelity=true"
OPERATION Print-Job
GROUP operation-attributes-tag
ATTR charset attributes-charset utf-8
ATTR naturalLanguage attributes-natural-language en
ATTR uri printer-uri $uri
ATTR name requesting-user-name $user
ATTR name job-name "document-a4.pdf with media=na_letter_8.5x11in and ipp-attribute-fidelity=true"
ATTR mimeMediaType document-format "application/pdf"
ATTR boolean ipp-attribute-fidelity true
GROUP job-attributes-tag
ATTR keyword media na_letter_8.5x11in
FILE "document-a4.pdf"
STATUS successful-ok
STATUS server-error-busy REPEAT-MATCH REPEAT-LIMIT 30
}
#
# End of "$Id: document-tests.test 12127 2014-08-28 18:57:27Z msweet $".
#
+28
Ver Arquivo
@@ -0,0 +1,28 @@
@echo off
::
:: "$Id: ipp-tests.bat 12249 2014-11-14 12:54:05Z msweet $"
::
:: IPP Everywhere Printer Self-Certification Manual 1.0: Section 6: IPP Tests.
::
:: Copyright 2014 by The Printer Working Group.
::
:: This program may be copied and furnished to others, and derivative works
:: that comment on, or otherwise explain it or assist in its implementation may
:: be prepared, copied, published and distributed, in whole or in part, without
:: restriction of any kind, provided that the above copyright notice and this
:: paragraph are included on all such copies and derivative works.
::
:: The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
:: WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
:: WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
::
:: Usage:
::
:: ipp-tests.bat 'Printer Name'
::
ippfind "%1._ipp._tcp.local." -x ipptool -P "\"%1 IPP Results.plist\"" -I "{}" ipp-tests.test ";"
::
:: End of "$Id: ipp-tests.bat 12249 2014-11-14 12:54:05Z msweet $".
::
Arquivo executável
+50
Ver Arquivo
@@ -0,0 +1,50 @@
#!/bin/sh
#
# "$Id: ipp-tests.sh 12127 2014-08-28 18:57:27Z msweet $"
#
# IPP Everywhere Printer Self-Certification Manual 1.0: Section 6: IPP Tests.
#
# Copyright 2014 by The Printer Working Group.
#
# This program may be copied and furnished to others, and derivative works
# that comment on, or otherwise explain it or assist in its implementation may
# be prepared, copied, published and distributed, in whole or in part, without
# restriction of any kind, provided that the above copyright notice and this
# paragraph are included on all such copies and derivative works.
#
# The IEEE-ISTO and the Printer Working Group DISCLAIM ANY AND ALL WARRANTIES,
# WHETHER EXPRESS OR IMPLIED INCLUDING (WITHOUT LIMITATION) ANY IMPLIED
# WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
#
# Usage:
#
# ./ipp-tests.sh "Printer Name"
#
if test -x ../test/ippfind-static; then
IPPFIND="../test/ippfind-static"
elif test -x ./ippfind; then
IPPFIND="./ippfind"
else
IPPFIND="ippfind"
fi
if test -x ../test/ipptool-static; then
IPPTOOL="../test/ipptool-static"
elif test -x ./ipptool; then
IPPTOOL="./ipptool"
else
IPPTOOL="ipptool"
fi
for file in color.jpg; do
if test ! -f $file -a -f ../test/$file; then
ln -s ../test/$file .
fi
done
$IPPFIND "$1._ipp._tcp.local." -x $IPPTOOL -P "$1 IPP Results.plist" -I '{}' ipp-tests.test \;
#
# End of "$Id: ipp-tests.sh 12127 2014-08-28 18:57:27Z msweet $".
#
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
+72
Ver Arquivo
@@ -0,0 +1,72 @@
#!/bin/sh
#
# "$Id: make-ippeveselfcert.sh 12130 2014-08-28 22:40:36Z msweet $"
#
# Make an IPP Everywhere Printer self-certification package.
#
# Copyright 2014 The Printer Working Group.
# Copyright 2007-2013 by Apple Inc.
# Copyright 1997-2007 by Easy Software Products, all rights reserved.
#
# These coded instructions, statements, and computer programs are the
# property of Apple Inc. and are protected by Federal copyright
# law. Distribution and use rights are outlined in the file "LICENSE.txt"
# which should have been included with this file. If this file is
# file is missing or damaged, see the license at "http://www.cups.org/".
#
# Make sure we are running in the right directory...
if test ! -f everywhere/make-ippeveselfcert.sh; then
echo "Run this script from the top-level CUPS source directory, e.g.:"
echo ""
echo " everywhere/make-ippeveselfcert.sh $*"
echo ""
exit 1
fi
if test $# != 2; then
echo "Usage: everywhere/make-ippeveselfcert.sh platform YYYYMMDD"
exit 1
fi
platform="$1"
fileversion="$2"
echo Creating package directory...
pkgdir="sw-ippeveselfcert10-$fileversion"
test -d $pkgdir && rm -r $pkgdir
mkdir $pkgdir || exit 1
echo Copying package files
cp LICENSE.txt $pkgdir
cp doc/help/man-ipp*.html $pkgdir
cp everywhere/README.txt $pkgdir
cp everywhere/man-ippserver.html $pkgdir
cp everywhere/*-tests.* $pkgdir
cp test/color.jpg $pkgdir
cp test/document-*.pdf $pkgdir
cp test/ippfind-static $pkgdir/ippfind
cp test/ippserver $pkgdir
cp test/ipptool-static $pkgdir/ipptool
cp test/printer.png $pkgdir
if test x$platform = xosx; then
pkgfile="$pkgdir-osx.dmg"
echo Creating disk image $pkgfile...
test -f $pkgfile && rm $pkgfile
hdiutil create -srcfolder $pkgdir $pkgfile
else
pkgfile="$pkgdir-$platform.tar.gz"
echo Creating archive $pkgfile...
tar czf $pkgfile $pkgdir || exit 1
fi
echo Removing temporary files...
rm -r $pkgdir
echo Done.
#
# End of "$Id: make-ippeveselfcert.sh 12130 2014-08-28 22:40:36Z msweet $".
#
+151
Ver Arquivo
@@ -0,0 +1,151 @@
<!DOCTYPE HTML>
<html>
<!-- SECTION: Man Pages -->
<head>
<link rel="stylesheet" type="text/css" href="../cups-printable.css">
<title>ippserver(1)</title>
</head>
<body>
<h1 class="title">ippserver(1)</h1>
<h2 class="title"><a name="NAME">Name</a></h2>
ippserver - a simple internet printing protocol server
<h2 class="title"><a name="SYNOPSIS">Synopsis</a></h2>
<b>ippserver</b>
[
<b>-2</b>
] [
<b>-M</b>
<i>manufacturer</i>
] [
<b>-P</b>
] [
<b>-c</b>
<i>command</i>
] [
<b>-d</b>
<i>spool-directory</i>
] [
<b>-f</b>
<i>type/subtype[,...]</i>
] [
<b>-h</b>
] [
<b>-i</b>
<i>iconfile.png</i>
] [
<b>-k</b>
] [
<b>-l</b>
<i>location</i>
] [
<b>-m</b>
<i>model</i>
] [
<b>-n</b>
<i>hostname</i>
] [
<b>-p</b>
<i>port</i>
] [
<b>-r</b>
<i>subtype</i>
] [
<b>-s</b>
<i>speed[,color-speed]</i>
] [
<b>-v[vvv]</b>
]
<i>service-name</i>
<h2 class="title"><a name="DESCRIPTION">Description</a></h2>
<b>ippserver</b>
is a simple Internet Printing Protocol (IPP) server conforming to the IPP Everywhere (PWG 5100.14) specification. It can be used to test client software or act as a very basic print server that runs a command for every job that is printed.
<h2 class="title"><a name="OPTIONS">Options</a></h2>
The following options are recognized by
<b>ippserver:</b>
<dl class="man">
<dt><b>-2</b>
<dd style="margin-left: 5.0em">Report support for two-sided (duplex) printing.
<dt><b>-M </b><i>manufacturer</i>
<dd style="margin-left: 5.0em">Set the manufacturer of the printer.
The default is "Test".
<dt><b>-P</b>
<dd style="margin-left: 5.0em">Report support for PIN printing.
<dt><b>-c </b><i>command</i>
<dd style="margin-left: 5.0em">Run the specified command for each document that is printed.
<dt><b>-d </b><i>spool-directory</i>
<dd style="margin-left: 5.0em">Specifies the directory that will hold the print files.
The default is a directory under the user's current temporary directory.
<dt><b>-f </b><i>type/subtype[,...]</i>
<dd style="margin-left: 5.0em">Specifies a list of MIME media types that the server will accept.
The default is "application/pdf,image/jpeg,image/pwg-raster".
<dt><b>-h</b>
<dd style="margin-left: 5.0em">Shows program help.
<dt><b>-i </b><i>iconfile.png</i>
<dd style="margin-left: 5.0em">Specifies the printer icon file for the server.
The default is "printer.png".
<dt><b>-k</b>
<dd style="margin-left: 5.0em">Keeps the print documents in the spool directory rather than deleting them.
<dt><b>-l </b><i>location</i>
<dd style="margin-left: 5.0em">Specifies the human-readable location string that is reported by the server.
The default is the empty string.
<dt><b>-m </b><i>model</i>
<dd style="margin-left: 5.0em">Specifies the model name of the printer.
The default is "Printer".
<dt><b>-n </b><i>hostname</i>
<dd style="margin-left: 5.0em">Specifies the hostname that is reported by the server.
The default is the name returned by the
<b>hostname</b>(1)
command.
<dt><b>-p </b><i>port</i>
<dd style="margin-left: 5.0em">Specifies the port number to listen on.
The default is a user-specific number from 8000 to 8999.
<dt><b>-r </b><i>subtype</i>
<dd style="margin-left: 5.0em">Specifies the Bonjour subtype(s) to advertise.
Separate multiple subtypes with a comma.
The default is "_print".
<dt><b>-s </b><i>speed[,color-speed]</i>
<dd style="margin-left: 5.0em">Specifies the printer speed in pages per minute.
If two numbers are specified and the second number is greater than zero, the server will report support for color printing.
The default is "10,0".
<dt><b>-v[vvv]</b>
<dd style="margin-left: 5.0em">Be (very) verbose when logging activity to the standard output.
</dl>
<h2 class="title"><a name="EXIT_STATUS">Exit Status</a></h2>
The
<b>ippserver</b>
program returns 1 if it is unable to process the command-line arguments or register the IPP service.
Otherwise
<b>ippserver</b>
will run continuously until terminated.
<h2 class="title"><a name="CONFORMING_TO">Conforming To</a></h2>
The
<b>ippserver</b>
program is unique to CUPS and conforms to the IPP Everywhere (PWG 5100.14) specification.
<h2 class="title"><a name="ENVIRONMENT">Environment</a></h2>
<b>ippserver</b>
adds environment variables starting with "IPP_" for all IPP Job attributes in the print request.
For example, when executing a command for an IPP Job containing the "media" Job Template attribute, the "IPP_MEDIA" environment variable will be set to the value of that attribute.
<p>Enumerated values are converted to their keyword equivalents.
For example, a "print-quality" Job Template attribute with a enum value of 3 will become the "IPP_PRINT_QUALITY" environment variable with a value of "draft".
<h2 class="title"><a name="EXAMPLES">Examples</a></h2>
Run
<b>ippserver</b>
with a service name of My Cool Printer:
<pre class="man">
ippserver "My Cool Printer"
</pre>
<p>Run the
<b>file</b>(1)
command whenever a job is sent to the server:
<pre class="man">
ippserver -c file "My Cool Printer"
</pre>
<h2 class="title"><a name="SEE_ALSO">See Also</a></h2>
PWG Internet Printing Protocol Workgroup (<a href="http://www.pwg.org/ipp">http://www.pwg.org/ipp</a>)
<h2 class="title"><a name="COPYRIGHT">Copyright</a></h2>
Copyright &copy; 2007-2014 by Apple Inc.
</body>
</html>
+26 -9
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: raster.c 12747 2015-06-24 15:55:05Z msweet $"
* "$Id: raster.c 12945 2015-10-26 19:46:02Z msweet $"
*
* Raster file routines for CUPS.
*
@@ -64,7 +64,7 @@ static ssize_t cups_raster_io(cups_raster_t *r, unsigned char *buf, size_t bytes
static unsigned cups_raster_read_header(cups_raster_t *r);
static ssize_t cups_raster_read(cups_raster_t *r, unsigned char *buf,
size_t bytes);
static void cups_raster_update(cups_raster_t *r);
static int cups_raster_update(cups_raster_t *r);
static ssize_t cups_raster_write(cups_raster_t *r,
const unsigned char *pixels);
static ssize_t cups_read_fd(void *ctx, unsigned char *buf, size_t bytes);
@@ -566,7 +566,8 @@ cupsRasterWriteHeader(
memset(&(r->header), 0, sizeof(r->header));
memcpy(&(r->header), h, sizeof(cups_page_header_t));
cups_raster_update(r);
if (!cups_raster_update(r))
return (0);
/*
* Write the raster header...
@@ -682,7 +683,8 @@ cupsRasterWriteHeader2(
memcpy(&(r->header), h, sizeof(cups_page_header2_t));
cups_raster_update(r);
if (!cups_raster_update(r))
return (0);
/*
* Write the raster header...
@@ -1015,11 +1017,12 @@ cups_raster_read_header(
* Update the header and row count...
*/
cups_raster_update(r);
if (!cups_raster_update(r))
return (0);
DEBUG_printf(("4cups_raster_read_header: cupsBitsPerPixel=%u, cupsBitsPerColor=%u, cupsBytesPerLine=%u, cupsWidth=%u, cupsHeight=%u, r->bpp=%d", r->header.cupsBitsPerPixel, r->header.cupsBitsPerColor, r->header.cupsBytesPerLine, r->header.cupsWidth, r->header.cupsHeight, r->bpp));
return (r->header.cupsBitsPerPixel != 0 && r->header.cupsBitsPerColor != 0 && r->header.cupsBytesPerLine != 0 && r->header.cupsHeight != 0 && (r->header.cupsBytesPerLine % r->bpp) == 0);
return (r->header.cupsBitsPerPixel > 0 && r->header.cupsBitsPerPixel <= 240 && r->header.cupsBitsPerColor > 0 && r->header.cupsBitsPerColor <= 16 && r->header.cupsBytesPerLine > 0 && r->header.cupsBytesPerLine <= 0x7fffffff && r->header.cupsHeight != 0 && (r->header.cupsBytesPerLine % r->bpp) == 0);
}
@@ -1219,7 +1222,7 @@ cups_raster_read(cups_raster_t *r, /* I - Raster stream */
* current page.
*/
static void
static int /* O - 1 on success, 0 on failure */
cups_raster_update(cups_raster_t *r) /* I - Raster stream */
{
if (r->sync == CUPS_RASTER_SYNCv1 || r->sync == CUPS_RASTER_REVSYNCv1 ||
@@ -1300,6 +1303,10 @@ cups_raster_update(cups_raster_t *r) /* I - Raster stream */
r->header.cupsNumColors = r->header.cupsColorSpace -
CUPS_CSPACE_DEVICE1 + 1;
break;
default :
/* Unknown color space */
return (0);
}
}
@@ -1333,11 +1340,21 @@ cups_raster_update(cups_raster_t *r) /* I - Raster stream */
if (r->pixels != NULL)
free(r->pixels);
r->pixels = calloc(r->header.cupsBytesPerLine, 1);
if ((r->pixels = calloc(r->header.cupsBytesPerLine, 1)) == NULL)
{
r->pcurrent = NULL;
r->pend = NULL;
r->count = 0;
return (0);
}
r->pcurrent = r->pixels;
r->pend = r->pixels + r->header.cupsBytesPerLine;
r->count = 0;
}
return (1);
}
@@ -1546,5 +1563,5 @@ cups_write_fd(void *ctx, /* I - File descriptor pointer */
/*
* End of "$Id: raster.c 12747 2015-06-24 15:55:05Z msweet $".
* End of "$Id: raster.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+27 -3
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: rastertoepson.c 12617 2015-05-06 20:28:22Z msweet $"
* "$Id: rastertoepson.c 12945 2015-10-26 19:46:02Z msweet $"
*
* EPSON ESC/P and ESC/P2 filter for CUPS.
*
@@ -119,6 +119,30 @@ StartPage(
unsigned plane; /* Looping var */
/*
* Show page device dictionary...
*/
fprintf(stderr, "DEBUG: StartPage...\n");
fprintf(stderr, "DEBUG: Duplex = %d\n", header->Duplex);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", header->HWResolution[0], header->HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n", header->ImagingBoundingBox[0], header->ImagingBoundingBox[1], header->ImagingBoundingBox[2], header->ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", header->Margins[0], header->Margins[1]);
fprintf(stderr, "DEBUG: ManualFeed = %d\n", header->ManualFeed);
fprintf(stderr, "DEBUG: MediaPosition = %d\n", header->MediaPosition);
fprintf(stderr, "DEBUG: NumCopies = %d\n", header->NumCopies);
fprintf(stderr, "DEBUG: Orientation = %d\n", header->Orientation);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", header->PageSize[0], header->PageSize[1]);
fprintf(stderr, "DEBUG: cupsWidth = %d\n", header->cupsWidth);
fprintf(stderr, "DEBUG: cupsHeight = %d\n", header->cupsHeight);
fprintf(stderr, "DEBUG: cupsMediaType = %d\n", header->cupsMediaType);
fprintf(stderr, "DEBUG: cupsBitsPerColor = %d\n", header->cupsBitsPerColor);
fprintf(stderr, "DEBUG: cupsBitsPerPixel = %d\n", header->cupsBitsPerPixel);
fprintf(stderr, "DEBUG: cupsBytesPerLine = %d\n", header->cupsBytesPerLine);
fprintf(stderr, "DEBUG: cupsColorOrder = %d\n", header->cupsColorOrder);
fprintf(stderr, "DEBUG: cupsColorSpace = %d\n", header->cupsColorSpace);
fprintf(stderr, "DEBUG: cupsCompression = %d\n", header->cupsCompression);
/*
* Send a reset sequence.
*/
@@ -263,7 +287,7 @@ StartPage(
* Allocate memory for a line/row of graphics...
*/
if ((Planes[0] = malloc(header->cupsBytesPerLine)) == NULL)
if ((Planes[0] = malloc(header->cupsBytesPerLine + NumPlanes)) == NULL)
{
fputs("ERROR: Unable to allocate memory\n", stderr);
exit(1);
@@ -1150,5 +1174,5 @@ main(int argc, /* I - Number of command-line arguments */
/*
* End of "$Id: rastertoepson.c 12617 2015-05-06 20:28:22Z msweet $".
* End of "$Id: rastertoepson.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+6 -30
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: rastertohp.c 12574 2015-03-26 16:36:18Z msweet $"
* "$Id: rastertohp.c 12945 2015-10-26 19:46:02Z msweet $"
*
* Hewlett-Packard Page Control Language filter for CUPS.
*
@@ -90,39 +90,15 @@ StartPage(ppd_file_t *ppd, /* I - PPD file */
*/
fprintf(stderr, "DEBUG: StartPage...\n");
fprintf(stderr, "DEBUG: MediaClass = \"%s\"\n", header->MediaClass);
fprintf(stderr, "DEBUG: MediaColor = \"%s\"\n", header->MediaColor);
fprintf(stderr, "DEBUG: MediaType = \"%s\"\n", header->MediaType);
fprintf(stderr, "DEBUG: OutputType = \"%s\"\n", header->OutputType);
fprintf(stderr, "DEBUG: AdvanceDistance = %d\n", header->AdvanceDistance);
fprintf(stderr, "DEBUG: AdvanceMedia = %d\n", header->AdvanceMedia);
fprintf(stderr, "DEBUG: Collate = %d\n", header->Collate);
fprintf(stderr, "DEBUG: CutMedia = %d\n", header->CutMedia);
fprintf(stderr, "DEBUG: Duplex = %d\n", header->Duplex);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", header->HWResolution[0],
header->HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n",
header->ImagingBoundingBox[0], header->ImagingBoundingBox[1],
header->ImagingBoundingBox[2], header->ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: InsertSheet = %d\n", header->InsertSheet);
fprintf(stderr, "DEBUG: Jog = %d\n", header->Jog);
fprintf(stderr, "DEBUG: LeadingEdge = %d\n", header->LeadingEdge);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", header->Margins[0],
header->Margins[1]);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", header->HWResolution[0], header->HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n", header->ImagingBoundingBox[0], header->ImagingBoundingBox[1], header->ImagingBoundingBox[2], header->ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", header->Margins[0], header->Margins[1]);
fprintf(stderr, "DEBUG: ManualFeed = %d\n", header->ManualFeed);
fprintf(stderr, "DEBUG: MediaPosition = %d\n", header->MediaPosition);
fprintf(stderr, "DEBUG: MediaWeight = %d\n", header->MediaWeight);
fprintf(stderr, "DEBUG: MirrorPrint = %d\n", header->MirrorPrint);
fprintf(stderr, "DEBUG: NegativePrint = %d\n", header->NegativePrint);
fprintf(stderr, "DEBUG: NumCopies = %d\n", header->NumCopies);
fprintf(stderr, "DEBUG: Orientation = %d\n", header->Orientation);
fprintf(stderr, "DEBUG: OutputFaceUp = %d\n", header->OutputFaceUp);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", header->PageSize[0],
header->PageSize[1]);
fprintf(stderr, "DEBUG: Separations = %d\n", header->Separations);
fprintf(stderr, "DEBUG: TraySwitch = %d\n", header->TraySwitch);
fprintf(stderr, "DEBUG: Tumble = %d\n", header->Tumble);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", header->PageSize[0], header->PageSize[1]);
fprintf(stderr, "DEBUG: cupsWidth = %d\n", header->cupsWidth);
fprintf(stderr, "DEBUG: cupsHeight = %d\n", header->cupsHeight);
fprintf(stderr, "DEBUG: cupsMediaType = %d\n", header->cupsMediaType);
@@ -871,5 +847,5 @@ main(int argc, /* I - Number of command-line arguments */
/*
* End of "$Id: rastertohp.c 12574 2015-03-26 16:36:18Z msweet $".
* End of "$Id: rastertohp.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+21 -34
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: rastertolabel.c 11755 2014-03-27 17:06:12Z msweet $"
* "$Id: rastertolabel.c 13022 2015-12-16 18:35:26Z msweet $"
*
* Label printer filter for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
* Copyright 2001-2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -166,39 +166,15 @@ StartPage(ppd_file_t *ppd, /* I - PPD file */
*/
fprintf(stderr, "DEBUG: StartPage...\n");
fprintf(stderr, "DEBUG: MediaClass = \"%s\"\n", header->MediaClass);
fprintf(stderr, "DEBUG: MediaColor = \"%s\"\n", header->MediaColor);
fprintf(stderr, "DEBUG: MediaType = \"%s\"\n", header->MediaType);
fprintf(stderr, "DEBUG: OutputType = \"%s\"\n", header->OutputType);
fprintf(stderr, "DEBUG: AdvanceDistance = %d\n", header->AdvanceDistance);
fprintf(stderr, "DEBUG: AdvanceMedia = %d\n", header->AdvanceMedia);
fprintf(stderr, "DEBUG: Collate = %d\n", header->Collate);
fprintf(stderr, "DEBUG: CutMedia = %d\n", header->CutMedia);
fprintf(stderr, "DEBUG: Duplex = %d\n", header->Duplex);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", header->HWResolution[0],
header->HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n",
header->ImagingBoundingBox[0], header->ImagingBoundingBox[1],
header->ImagingBoundingBox[2], header->ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: InsertSheet = %d\n", header->InsertSheet);
fprintf(stderr, "DEBUG: Jog = %d\n", header->Jog);
fprintf(stderr, "DEBUG: LeadingEdge = %d\n", header->LeadingEdge);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", header->Margins[0],
header->Margins[1]);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", header->HWResolution[0], header->HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n", header->ImagingBoundingBox[0], header->ImagingBoundingBox[1], header->ImagingBoundingBox[2], header->ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", header->Margins[0], header->Margins[1]);
fprintf(stderr, "DEBUG: ManualFeed = %d\n", header->ManualFeed);
fprintf(stderr, "DEBUG: MediaPosition = %d\n", header->MediaPosition);
fprintf(stderr, "DEBUG: MediaWeight = %d\n", header->MediaWeight);
fprintf(stderr, "DEBUG: MirrorPrint = %d\n", header->MirrorPrint);
fprintf(stderr, "DEBUG: NegativePrint = %d\n", header->NegativePrint);
fprintf(stderr, "DEBUG: NumCopies = %d\n", header->NumCopies);
fprintf(stderr, "DEBUG: Orientation = %d\n", header->Orientation);
fprintf(stderr, "DEBUG: OutputFaceUp = %d\n", header->OutputFaceUp);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", header->PageSize[0],
header->PageSize[1]);
fprintf(stderr, "DEBUG: Separations = %d\n", header->Separations);
fprintf(stderr, "DEBUG: TraySwitch = %d\n", header->TraySwitch);
fprintf(stderr, "DEBUG: Tumble = %d\n", header->Tumble);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", header->PageSize[0], header->PageSize[1]);
fprintf(stderr, "DEBUG: cupsWidth = %d\n", header->cupsWidth);
fprintf(stderr, "DEBUG: cupsHeight = %d\n", header->cupsHeight);
fprintf(stderr, "DEBUG: cupsMediaType = %d\n", header->cupsMediaType);
@@ -208,9 +184,6 @@ StartPage(ppd_file_t *ppd, /* I - PPD file */
fprintf(stderr, "DEBUG: cupsColorOrder = %d\n", header->cupsColorOrder);
fprintf(stderr, "DEBUG: cupsColorSpace = %d\n", header->cupsColorSpace);
fprintf(stderr, "DEBUG: cupsCompression = %d\n", header->cupsCompression);
fprintf(stderr, "DEBUG: cupsRowCount = %d\n", header->cupsRowCount);
fprintf(stderr, "DEBUG: cupsRowFeed = %d\n", header->cupsRowFeed);
fprintf(stderr, "DEBUG: cupsRowStep = %d\n", header->cupsRowStep);
switch (ModelNumber)
{
@@ -498,6 +471,13 @@ EndPage(ppd_file_t *ppd, /* I - PPD file */
*/
puts("P1");
/*
* Cut the label as needed...
*/
if (header->CutMedia)
puts("C");
break;
case ZEBRA_ZPL :
@@ -629,6 +609,13 @@ EndPage(ppd_file_t *ppd, /* I - PPD file */
puts("^IDR:CUPS.GRF^FS");
puts("^XZ");
/*
* Cut the label as needed...
*/
if (header->CutMedia)
puts("^CN1");
break;
case ZEBRA_CPCL :
@@ -1294,5 +1281,5 @@ main(int argc, /* I - Number of command-line arguments */
/*
* End of "$Id: rastertolabel.c 11755 2014-03-27 17:06:12Z msweet $".
* End of "$Id: rastertolabel.c 13022 2015-12-16 18:35:26Z msweet $".
*/
+35 -6
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: rastertopwg.c 12609 2015-05-06 12:24:47Z msweet $"
* "$Id: rastertopwg.c 12945 2015-10-26 19:46:02Z msweet $"
*
* CUPS raster to PWG raster format filter for CUPS.
*
@@ -89,6 +89,29 @@ main(int argc, /* I - Number of command-line args */
while (cupsRasterReadHeader2(inras, &inheader))
{
/*
* Show page device dictionary...
*/
fprintf(stderr, "DEBUG: Duplex = %d\n", inheader.Duplex);
fprintf(stderr, "DEBUG: HWResolution = [ %d %d ]\n", inheader.HWResolution[0], inheader.HWResolution[1]);
fprintf(stderr, "DEBUG: ImagingBoundingBox = [ %d %d %d %d ]\n", inheader.ImagingBoundingBox[0], inheader.ImagingBoundingBox[1], inheader.ImagingBoundingBox[2], inheader.ImagingBoundingBox[3]);
fprintf(stderr, "DEBUG: Margins = [ %d %d ]\n", inheader.Margins[0], inheader.Margins[1]);
fprintf(stderr, "DEBUG: ManualFeed = %d\n", inheader.ManualFeed);
fprintf(stderr, "DEBUG: MediaPosition = %d\n", inheader.MediaPosition);
fprintf(stderr, "DEBUG: NumCopies = %d\n", inheader.NumCopies);
fprintf(stderr, "DEBUG: Orientation = %d\n", inheader.Orientation);
fprintf(stderr, "DEBUG: PageSize = [ %d %d ]\n", inheader.PageSize[0], inheader.PageSize[1]);
fprintf(stderr, "DEBUG: cupsWidth = %d\n", inheader.cupsWidth);
fprintf(stderr, "DEBUG: cupsHeight = %d\n", inheader.cupsHeight);
fprintf(stderr, "DEBUG: cupsMediaType = %d\n", inheader.cupsMediaType);
fprintf(stderr, "DEBUG: cupsBitsPerColor = %d\n", inheader.cupsBitsPerColor);
fprintf(stderr, "DEBUG: cupsBitsPerPixel = %d\n", inheader.cupsBitsPerPixel);
fprintf(stderr, "DEBUG: cupsBytesPerLine = %d\n", inheader.cupsBytesPerLine);
fprintf(stderr, "DEBUG: cupsColorOrder = %d\n", inheader.cupsColorOrder);
fprintf(stderr, "DEBUG: cupsColorSpace = %d\n", inheader.cupsColorSpace);
fprintf(stderr, "DEBUG: cupsCompression = %d\n", inheader.cupsCompression);
/*
* Compute the real raster size...
*/
@@ -105,6 +128,13 @@ main(int argc, /* I - Number of command-line args */
linesize = (page_width * inheader.cupsBitsPerPixel + 7) / 8;
lineoffset = page_left * inheader.cupsBitsPerPixel / 8; /* Round down */
if (page_left > page_width || page_top > page_height || page_bottom > page_height)
{
_cupsLangPrintFilter(stderr, "ERROR", _("Unsupported raster data."));
fprintf(stderr, "DEBUG: Bad bottom/left/top margin on page %d.\n", page);
return (1);
}
switch (inheader.cupsColorSpace)
{
case CUPS_CSPACE_W :
@@ -184,7 +214,7 @@ main(int argc, /* I - Number of command-line args */
sizeof(outheader.OutputType));
else
{
fprintf(stderr, "DEBUG: Unsupported print-content-type \"%s\".\n", val);
fputs("DEBUG: Unsupported print-content-optimize value.\n", stderr);
outheader.OutputType[0] = '\0';
}
}
@@ -225,8 +255,7 @@ main(int argc, /* I - Number of command-line args */
sizeof(outheader.cupsRenderingIntent));
else
{
fprintf(stderr, "DEBUG: Unsupported print-rendering-intent \"%s\".\n",
val);
fputs("DEBUG: Unsupported print-rendering-intent value.\n", stderr);
outheader.cupsRenderingIntent[0] = '\0';
}
}
@@ -360,7 +389,7 @@ main(int argc, /* I - Number of command-line args */
* Unsupported value...
*/
fprintf(stderr, "DEBUG: Unsupported cupsBackSide \"%s\".\n", back->value);
fputs("DEBUG: Unsupported cupsBackSide value.\n", stderr);
outheader.cupsInteger[1] = 1; /* CrossFeedTransform */
outheader.cupsInteger[2] = 1; /* FeedTransform */
@@ -459,5 +488,5 @@ main(int argc, /* I - Number of command-line args */
/*
* End of "$Id: rastertopwg.c 12609 2015-05-06 12:24:47Z msweet $".
* End of "$Id: rastertopwg.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+2 -2
Ver Arquivo
@@ -3,7 +3,7 @@
#
# Message catalog template for the Common UNIX Printing System (CUPS).
#
# Copyright 2007-2009 by Apple Inc.
# Copyright 2007-2015 by Apple Inc.
# Copyright 2005-2007 by Easy Software Products.
#
# These coded instructions, statements, and computer programs are the
@@ -4371,7 +4371,7 @@ msgid "The printer is not connected."
msgstr "La impressora no està connectada."
msgid "The printer is not responding."
msgstr "La impressora no respòn."
msgstr "La impressora no respon."
msgid "The printer is now connected."
msgstr "Ara la impressora està connectada."
Diferenças do arquivo suprimidas por serem muito extensas Carregar Diff
+7 -7
Ver Arquivo
@@ -3,7 +3,7 @@
.\"
.\" cupsctl man page for CUPS.
.\"
.\" Copyright 2007-2014 by Apple Inc.
.\" Copyright 2007-2016 by Apple Inc.
.\" Copyright 2007 by Easy Software Products.
.\"
.\" These coded instructions, statements, and computer programs are the
@@ -12,7 +12,7 @@
.\" which should have been included with this file. If this file is
.\" file is missing or damaged, see the license at "http://www.cups.org/".
.\"
.TH cupsctl 8 "CUPS" "11 June 2014" "Apple Inc."
.TH cupsctl 8 "CUPS" "30 May 2016" "Apple Inc."
.SH NAME
cupsctl \- configure cupsd.conf options
.SH SYNOPSIS
@@ -54,19 +54,19 @@ Specifies an alternate username to use when authenticating with the scheduler.
\fB\-h \fIserver\fR[\fB:\fIport\fR]
Specifies the server address.
.TP 5
.B \-\-\fR[\fBno\-\fR]\fBdebug\-logging
\fB\-\-\fR[\fBno\-\fR]\fBdebug\-logging\fR
Enables (disables) debug logging to the \fIerror_log\fR file.
.TP 5
.B \-\-\fR[\fBno\-\fR]\fBremote\-admin
\fB\-\-\fR[\fBno\-\fR]\fBremote\-admin\fR
Enables (disables) remote administration.
.TP 5
.B \-\-\fR[\fBno\-\fR]\fBremote\-any
\fB\-\-\fR[\fBno\-\fR]\fBremote\-any\fR
Enables (disables) printing from any address, e.g., the Internet.
.TP 5
.B \-\-\fR[\fBno\-\fR]\fBshare\-printers
\fB\-\-\fR[\fBno\-\fR]\fBshare\-printers\fR
Enables (disables) sharing of local printers with other computers.
.TP 5
.B \-\-\fR[\fBno\-\fR]\fBuser\-cancel\-any
\fB\-\-\fR[\fBno\-\fR]\fBuser\-cancel\-any\fR
Allows (prevents) users to cancel jobs owned by others.
.SH EXAMPLES
Display the current settings:
+18 -11
Ver Arquivo
@@ -1,9 +1,9 @@
.\"
.\" "$Id: cupsd.man.in 12854 2015-08-28 14:08:00Z msweet $"
.\" "$Id: cupsd.man.in 13087 2016-02-12 18:53:24Z msweet $"
.\"
.\" cupsd man page for CUPS.
.\"
.\" Copyright 2007-2014 by Apple Inc.
.\" Copyright 2007-2016 by Apple Inc.
.\" Copyright 1997-2006 by Easy Software Products.
.\"
.\" These coded instructions, statements, and computer programs are the
@@ -12,14 +12,14 @@
.\" which should have been included with this file. If this file is
.\" file is missing or damaged, see the license at "http://www.cups.org/".
.\"
.TH cupsd 8 "CUPS" "8 July 2014" "Apple Inc."
.TH cupsd 8 "CUPS" "12 February 2016" "Apple Inc."
.SH NAME
cupsd \- cups scheduler
.SH SYNOPSIS
.B cupsd
[
.B \-c
.I config-file
.I cupsd.conf
] [
.B \-f
] [
@@ -27,19 +27,22 @@ cupsd \- cups scheduler
] [
.B \-h
] [
.B -l
.B \-l
] [
.B -t
.B \-s
.I cups-files.conf
] [
.B \-t
]
.SH DESCRIPTION
.B cupsd
is the scheduler for CUPS. It implements a printing system based upon the Internet Printing Protocol, version 2.1. If no options are specified on the command-line then the default configuration file
is the scheduler for CUPS. It implements a printing system based upon the Internet Printing Protocol, version 2.1, and supports most of the requirements for IPP Everywhere. If no options are specified on the command-line then the default configuration file
.I /etc/cups/cupsd.conf
will be used.
.SH OPTIONS
.TP 5
.BI \-c \ config-file
Uses the named configuration file.
.BI \-c \ cupsd.conf
Uses the named cupsd.conf configuration file.
.TP 5
.B \-f
Run
@@ -65,6 +68,9 @@ when it is run from
or
.BR systemd (8).
.TP 5
.BI \-s \ cups-files.conf
Uses the named cups-files.conf configuration file.
.TP 5
.B \-t
Test the configuration file for syntax errors.
.SH FILES
@@ -109,6 +115,7 @@ in the foreground with a test configuration file called
.BR backend (7),
.BR classes.conf (5),
.BR cups (1),
.BR cups-files.conf (5),
.BR cups-lpd (8),
.BR cupsd.conf (5),
.BR cupsd-helper (8),
@@ -121,7 +128,7 @@ in the foreground with a test configuration file called
.BR systemd (8),
CUPS Online Help (http://localhost:631/help)
.SH COPYRIGHT
Copyright \[co] 2007-2015 by Apple Inc.
Copyright \[co] 2007-2016 by Apple Inc.
.\"
.\" End of "$Id: cupsd.man.in 12854 2015-08-28 14:08:00Z msweet $".
.\" End of "$Id: cupsd.man.in 13087 2016-02-12 18:53:24Z msweet $".
.\"
+5 -5
Ver Arquivo
@@ -1,9 +1,9 @@
.\"
.\" "$Id: ppdcfile.man 12854 2015-08-28 14:08:00Z msweet $"
.\" "$Id: ppdcfile.man 13117 2016-03-07 18:36:16Z msweet $"
.\"
.\" ppdcfile man page for CUPS.
.\"
.\" Copyright 2007-2014 by Apple Inc.
.\" Copyright 2007-2016 by Apple Inc.
.\" Copyright 1997-2007 by Easy Software Products.
.\"
.\" These coded instructions, statements, and computer programs are the
@@ -12,7 +12,7 @@
.\" which should have been included with this file. If this file is
.\" file is missing or damaged, see the license at "http://www.cups.org/".
.\"
.TH ppdcfile 5 "CUPS" "12 June 2014" "Apple Inc."
.TH ppdcfile 5 "CUPS" "5 March 2016" "Apple Inc."
.SH NAME
ppdcfile \- cups ppd compiler source file format
.SH DESCRIPTION
@@ -82,7 +82,7 @@ Directives may be placed anywhere on a line and are followed by one or more valu
.TP 5
\fBDuplex \fItype\fR
.TP 5
\fBFilter \Imime-type cost program\fR
\fBFilter \fImime-type cost program\fR
.TP 5
\fBFinishing \fIname\fR
.TP 5
@@ -161,5 +161,5 @@ CUPS Online Help (http://localhost:631/help)
.SH COPYRIGHT
Copyright \[co] 2007-2015 by Apple Inc.
.\"
.\" End of "$Id: ppdcfile.man 12854 2015-08-28 14:08:00Z msweet $".
.\" End of "$Id: ppdcfile.man 13117 2016-03-07 18:36:16Z msweet $".
.\"
+11 -5
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: rss.c 12128 2014-08-28 19:23:23Z msweet $"
* "$Id: rss.c 12945 2015-10-26 19:46:02Z msweet $"
*
* RSS notifier for CUPS.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -641,15 +641,21 @@ save_rss(cups_array_t *rss, /* I - RSS messages */
msg;
msg = (_cups_rss_t *)cupsArrayPrev(rss))
{
char *subject = xml_escape(msg->subject);
char *text = xml_escape(msg->text);
fputs(" <item>\n", fp);
fprintf(fp, " <title>%s</title>\n", msg->subject);
fprintf(fp, " <description>%s</description>\n", msg->text);
fprintf(fp, " <title>%s</title>\n", subject);
fprintf(fp, " <description>%s</description>\n", text);
if (msg->link_url)
fprintf(fp, " <link>%s</link>\n", msg->link_url);
fprintf(fp, " <pubDate>%s</pubDate>\n",
httpGetDateString2(msg->event_time, date, sizeof(date)));
fprintf(fp, " <guid>%d</guid>\n", msg->sequence_number);
fputs(" </item>\n", fp);
free(subject);
free(text);
}
fputs(" </channel>\n", fp);
@@ -729,5 +735,5 @@ xml_escape(const char *s) /* I - String to escape */
/*
* End of "$Id: rss.c 12128 2014-08-28 19:23:23Z msweet $".
* End of "$Id: rss.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+4 -4
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: testnotify.c 10996 2013-05-29 11:51:34Z msweet $"
* "$Id: testnotify.c 13040 2016-01-11 20:29:13Z msweet $"
*
* Test notifier for CUPS.
*
* Copyright 2007-2011 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2005 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -115,7 +115,7 @@ print_attributes(ipp_t *ipp, /* I - IPP request */
ippAttributeString(attr, buffer, sizeof(buffer));
fprintf(stderr, "DEBUG: %*s%s (%s%s) %s", indent, "", attr->name,
fprintf(stderr, "DEBUG: %*s%s (%s%s) %s\n", indent, "", attr->name,
attr->num_values > 1 ? "1setOf " : "",
ippTagString(attr->value_tag), buffer);
}
@@ -123,5 +123,5 @@ print_attributes(ipp_t *ipp, /* I - IPP request */
/*
* End of "$Id: testnotify.c 10996 2013-05-29 11:51:34Z msweet $".
* End of "$Id: testnotify.c 13040 2016-01-11 20:29:13Z msweet $".
*/
+2 -2
Ver Arquivo
@@ -45,12 +45,12 @@
Summary: CUPS
Name: cups
Version: 2.1.0
Version: 2.1.3
Release: 1
Epoch: 1
License: GPL
Group: System Environment/Daemons
Source: http://www.cups.org/software/2.1.0/cups-2.1.0-source.tar.bz2
Source: http://www.cups.org/software/2.1.3/cups-2.1.3-source.tar.bz2
Url: http://www.cups.org
Packager: Anonymous <anonymous@foo.com>
Vendor: Apple Inc.
+68 -193
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: auth.c 12602 2015-05-05 20:19:35Z msweet $"
* "$Id: auth.c 12945 2015-10-26 19:46:02Z msweet $"
*
* Authorization routines for the CUPS scheduler.
*
@@ -111,12 +111,7 @@ cupsdAddIPMask(
cupsd_authmask_t temp; /* New host/domain mask */
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdAddIPMask(masks=%p(%p), address=%x:%x:%x:%x, "
"netmask=%x:%x:%x:%x)",
masks, *masks,
address[0], address[1], address[2], address[3],
netmask[0], netmask[1], netmask[2], netmask[3]);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddIPMask(masks=%p(%p), address=%x:%x:%x:%x, netmask=%x:%x:%x:%x)", masks, *masks, address[0], address[1], address[2], address[3], netmask[0], netmask[1], netmask[2], netmask[3]);
temp.type = CUPSD_AUTH_IP;
memcpy(temp.mask.ip.address, address, sizeof(temp.mask.ip.address));
@@ -156,8 +151,7 @@ cupsdAddLocation(cupsd_location_t *loc) /* I - Location to add */
{
cupsArrayAdd(Locations, loc);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddLocation: Added location \"%s\"",
loc->location ? loc->location : "(null)");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddLocation: Added location \"%s\"", loc->location ? loc->location : "(null)");
}
}
@@ -170,8 +164,7 @@ void
cupsdAddName(cupsd_location_t *loc, /* I - Location to add to */
char *name) /* I - Name to add */
{
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddName(loc=%p, name=\"%s\")",
loc, name);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddName(loc=%p, name=\"%s\")", loc, name);
if (!loc->names)
loc->names = cupsArrayNew3(NULL, NULL, NULL, 0,
@@ -201,9 +194,7 @@ cupsdAddNameMask(cups_array_t **masks, /* IO - Masks array (created as needed) *
*ifptr; /* Pointer to end of name */
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdAddNameMask(masks=%p(%p), name=\"%s\")",
masks, *masks, name);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddNameMask(masks=%p(%p), name=\"%s\")", masks, *masks, name);
if (!_cups_strcasecmp(name, "@LOCAL"))
{
@@ -290,10 +281,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
con->best = cupsdFindBest(con->uri, httpGetState(con->http));
con->type = CUPSD_AUTH_NONE;
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"[Client %d] con->uri=\"%s\", con->best=%p(%s)",
con->number, con->uri, con->best,
con->best ? con->best->location : "");
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "con->uri=\"%s\", con->best=%p(%s)", con->uri, con->best, con->best ? con->best->location : "");
if (con->best && con->best->type != CUPSD_AUTH_NONE)
{
@@ -311,9 +299,6 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
authorization = httpGetField(con->http, HTTP_FIELD_AUTHORIZATION);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "[Client %d] Authorization=\"%s\"",
con->number, authorization);
username[0] = '\0';
password[0] = '\0';
@@ -335,9 +320,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* No authorization data provided, return early...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] No authentication data provided.",
con->number);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "No authentication data provided.");
return;
}
#ifdef HAVE_AUTHORIZATION_H
@@ -363,18 +346,13 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (authlen != kAuthorizationExternalFormLength)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] External Authorization reference size is "
"incorrect.", con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "External Authorization reference size is incorrect.");
return;
}
if ((status = AuthorizationCreateFromExternalForm((AuthorizationExternalForm *)authdata, &con->authref)) != 0)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] AuthorizationCreateFromExternalForm "
"returned %d (%s)", con->number, (int)status,
cssmErrorString(status));
cupsdLogClient(con, CUPSD_LOG_ERROR, "AuthorizationCreateFromExternalForm returned %d (%s)", (int)status, cssmErrorString(status));
return;
}
@@ -388,9 +366,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
{
strlcpy(username, authinfo->items[0].value, sizeof(username));
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as \"%s\" using AuthRef",
con->number, username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as \"%s\" using AuthRef.", username);
}
AuthorizationFreeItemSet(authinfo);
@@ -410,26 +386,19 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (getsockopt(httpGetFd(con->http), 0, LOCAL_PEERCRED, &peercred, &peersize))
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Unable to get peer credentials - %s",
con->number, strerror(errno));
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unable to get peer credentials - %s", strerror(errno));
return;
}
if ((pwd = getpwuid(CUPSD_UCRED_UID(peercred))) == NULL)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Unable to find UID %d for peer "
"credentials.", con->number,
(int)CUPSD_UCRED_UID(peercred));
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unable to find UID %d for peer credentials.", (int)CUPSD_UCRED_UID(peercred));
return;
}
strlcpy(username, pwd->pw_name, sizeof(username));
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as \"%s\" using "
"AuthRef + PeerCred", con->number, username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as \"%s\" using AuthRef + PeerCred.", username);
}
con->type = CUPSD_AUTH_BASIC;
@@ -474,18 +443,14 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (no_peer)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] PeerCred authentication not allowed for "
"resource per AUTHKEY policy.", con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "PeerCred authentication not allowed for resource per AUTHKEY policy.");
return;
}
#endif /* HAVE_AUTHORIZATION_H */
if ((pwd = getpwnam(authorization + 9)) == NULL)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] User \"%s\" does not exist.", con->number,
authorization + 9);
cupsdLogClient(con, CUPSD_LOG_ERROR, "User \"%s\" does not exist.", authorization + 9);
return;
}
@@ -497,27 +462,18 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (getsockopt(httpGetFd(con->http), SOL_SOCKET, SO_PEERCRED, &peercred, &peersize))
# endif /* __APPLE__ */
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Unable to get peer credentials - %s",
con->number, strerror(errno));
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unable to get peer credentials - %s", strerror(errno));
return;
}
if (pwd->pw_uid != CUPSD_UCRED_UID(peercred))
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Invalid peer credentials for \"%s\" - got "
"%d, expected %d!", con->number, authorization + 9,
CUPSD_UCRED_UID(peercred), pwd->pw_uid);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Invalid peer credentials for \"%s\" - got %d, expected %d.", authorization + 9, CUPSD_UCRED_UID(peercred), pwd->pw_uid);
# ifdef HAVE_SYS_UCRED_H
cupsdLogMessage(CUPSD_LOG_DEBUG, "[Client %d] cr_version=%d",
con->number, peercred.cr_version);
cupsdLogMessage(CUPSD_LOG_DEBUG, "[Client %d] cr_uid=%d",
con->number, peercred.cr_uid);
cupsdLogMessage(CUPSD_LOG_DEBUG, "[Client %d] cr_ngroups=%d",
con->number, peercred.cr_ngroups);
cupsdLogMessage(CUPSD_LOG_DEBUG, "[Client %d] cr_groups[0]=%d",
con->number, peercred.cr_groups[0]);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cr_version=%d", peercred.cr_version);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cr_uid=%d", peercred.cr_uid);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cr_ngroups=%d", peercred.cr_ngroups);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cr_groups[0]=%d", peercred.cr_groups[0]);
# endif /* HAVE_SYS_UCRED_H */
return;
}
@@ -528,9 +484,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
con->gss_uid = CUPSD_UCRED_UID(peercred);
# endif /* HAVE_GSSAPI */
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as %s using PeerCred", con->number,
username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as %s using PeerCred.", username);
con->type = CUPSD_AUTH_BASIC;
}
@@ -548,18 +502,14 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if ((localuser = cupsdFindCert(authorization)) == NULL)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Local authentication certificate not found.",
con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Local authentication certificate not found.");
return;
}
strlcpy(username, localuser->username, sizeof(username));
con->type = localuser->type;
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as %s using Local", con->number,
username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as %s using Local.", username);
}
else if (!strncmp(authorization, "Basic", 5))
{
@@ -583,8 +533,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if ((ptr = strchr(username, ':')) == NULL)
{
cupsdLogMessage(CUPSD_LOG_ERROR, "[Client %d] Missing Basic password.",
con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Missing Basic password.");
return;
}
@@ -596,8 +545,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* Username must not be empty...
*/
cupsdLogMessage(CUPSD_LOG_ERROR, "[Client %d] Empty Basic username.",
con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Empty Basic username.");
return;
}
@@ -607,8 +555,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* Password must not be empty...
*/
cupsdLogMessage(CUPSD_LOG_ERROR, "[Client %d] Empty Basic password.",
con->number);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Empty Basic password.");
return;
}
@@ -650,9 +597,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
pamerr = pam_start("cups", username, &pamdata, &pamh);
if (pamerr != PAM_SUCCESS)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] pam_start() returned %d (%s)",
con->number, pamerr, pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_ERROR, "pam_start() returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
return;
}
@@ -660,28 +605,20 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
# ifdef PAM_RHOST
pamerr = pam_set_item(pamh, PAM_RHOST, con->http->hostname);
if (pamerr != PAM_SUCCESS)
cupsdLogMessage(CUPSD_LOG_WARN,
"[Client %d] pam_set_item(PAM_RHOST) "
"returned %d (%s)", con->number, pamerr,
pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_WARN, "pam_set_item(PAM_RHOST) returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
# endif /* PAM_RHOST */
# ifdef PAM_TTY
pamerr = pam_set_item(pamh, PAM_TTY, "cups");
if (pamerr != PAM_SUCCESS)
cupsdLogMessage(CUPSD_LOG_WARN,
"[Client %d] pam_set_item(PAM_TTY) "
"returned %d (%s)!", con->number, pamerr,
pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_WARN, "pam_set_item(PAM_TTY) returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
# endif /* PAM_TTY */
# endif /* HAVE_PAM_SET_ITEM */
pamerr = pam_authenticate(pamh, PAM_SILENT);
if (pamerr != PAM_SUCCESS)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] pam_authenticate() returned %d (%s)",
con->number, pamerr, pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_ERROR, "pam_authenticate() returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
pam_end(pamh, 0);
return;
}
@@ -689,18 +626,13 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
# ifdef HAVE_PAM_SETCRED
pamerr = pam_setcred(pamh, PAM_ESTABLISH_CRED | PAM_SILENT);
if (pamerr != PAM_SUCCESS)
cupsdLogMessage(CUPSD_LOG_WARN,
"[Client %d] pam_setcred() returned %d (%s)",
con->number, pamerr,
pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_WARN, "pam_setcred() returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
# endif /* HAVE_PAM_SETCRED */
pamerr = pam_acct_mgmt(pamh, PAM_SILENT);
if (pamerr != PAM_SUCCESS)
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] pam_acct_mgmt() returned %d (%s)",
con->number, pamerr, pam_strerror(pamh, pamerr));
cupsdLogClient(con, CUPSD_LOG_ERROR, "pam_acct_mgmt() returned %d (%s)", pamerr, pam_strerror(pamh, pamerr));
pam_end(pamh, 0);
return;
}
@@ -728,9 +660,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* No such user...
*/
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Unknown username \"%s\".",
con->number, username);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unknown username \"%s\".", username);
return;
}
@@ -744,9 +674,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* Don't allow blank passwords!
*/
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Username \"%s\" has no shadow "
"password.", con->number, username);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Username \"%s\" has no shadow password.", username);
return;
}
@@ -759,9 +687,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
* Don't allow blank passwords!
*/
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Username \"%s\" has no password.",
con->number, username);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Username \"%s\" has no password.", username);
return;
}
@@ -772,10 +698,6 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
pass = cups_crypt(password, pw->pw_passwd);
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"[Client %d] pw_passwd=\"%s\", crypt=\"%s\"",
con->number, pw->pw_passwd, pass);
if (!pass || strcmp(pw->pw_passwd, pass))
{
# ifdef HAVE_SHADOW_H
@@ -783,33 +705,23 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
{
pass = cups_crypt(password, spw->sp_pwdp);
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"[Client %d] sp_pwdp=\"%s\", crypt=\"%s\"",
con->number, spw->sp_pwdp, pass);
if (pass == NULL || strcmp(spw->sp_pwdp, pass))
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Authentication failed for user "
"\"%s\".", con->number, username);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Authentication failed for user \"%s\".", username);
return;
}
}
else
# endif /* HAVE_SHADOW_H */
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Authentication failed for user "
"\"%s\".", con->number, username);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Authentication failed for user \"%s\".", username);
return;
}
}
#endif /* HAVE_LIBPAM */
}
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as %s using Basic",
con->number, username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as \"%s\" using Basic.", username);
break;
}
@@ -837,10 +749,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (&gss_init_sec_context == NULL)
{
cupsdLogMessage(CUPSD_LOG_WARN,
"[Client %d] GSSAPI/Kerberos authentication failed "
"because the Kerberos framework is not present.",
con->number);
cupsdLogClient(con, CUPSD_LOG_WARN, "GSSAPI/Kerberos authentication failed because the Kerberos framework is not present.");
return;
}
# endif /* __APPLE__ */
@@ -855,9 +764,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (!*authorization)
{
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"[Client %d] No authentication data specified.",
con->number);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "No authentication data specified.");
return;
}
@@ -894,9 +801,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (GSS_ERROR(major_status))
{
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status,
"[Client %d] Error accepting GSSAPI security context",
con->number);
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status, "[Client %d] Error accepting GSSAPI security context.", con->number);
if (context != GSS_C_NO_CONTEXT)
gss_delete_sec_context(&minor_status, &context, GSS_C_NO_BUFFER);
@@ -910,8 +815,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
*/
if (major_status == GSS_S_CONTINUE_NEEDED)
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status,
"[Client %d] Credentials not complete", con->number);
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status, "[Client %d] Credentials not complete.", con->number);
else if (major_status == GSS_S_COMPLETE)
{
major_status = gss_display_name(&minor_status, client_name,
@@ -919,8 +823,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (GSS_ERROR(major_status))
{
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status,
"[Client %d] Error getting username", con->number);
cupsdLogGSSMessage(CUPSD_LOG_DEBUG, major_status, minor_status, "[Client %d] Error getting username.", con->number);
gss_release_name(&minor_status, &client_name);
gss_delete_sec_context(&minor_status, &context, GSS_C_NO_BUFFER);
return;
@@ -928,9 +831,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
strlcpy(username, output_token.value, sizeof(username));
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Authorized as %s using Negotiate",
con->number, username);
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Authorized as \"%s\" using Negotiate.", username);
gss_release_name(&minor_status, &client_name);
gss_release_buffer(&minor_status, &output_token);
@@ -960,15 +861,11 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
&peersize))
# endif /* __APPLE__ */
{
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Unable to get peer credentials - %s",
con->number, strerror(errno));
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unable to get peer credentials - %s", strerror(errno));
}
else
{
cupsdLogMessage(CUPSD_LOG_DEBUG,
"[Client %d] Using credentials for UID %d.",
con->number, CUPSD_UCRED_UID(peercred));
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Using credentials for UID %d.", CUPSD_UCRED_UID(peercred));
con->gss_uid = CUPSD_UCRED_UID(peercred);
}
}
@@ -983,9 +880,7 @@ cupsdAuthorize(cupsd_client_t *con) /* I - Client connection */
if (sscanf(authorization, "%255s", scheme) != 1)
strlcpy(scheme, "UNKNOWN", sizeof(scheme));
cupsdLogMessage(CUPSD_LOG_ERROR,
"[Client %d] Bad authentication data \"%s ...\"",
con->number, scheme);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Bad authentication data \"%s ...\".", scheme);
return;
}
@@ -1261,9 +1156,7 @@ cupsdCheckGroup(
#endif /* HAVE_MBR_UID_TO_UUID */
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdCheckGroup(username=\"%s\", user=%p, groupname=\"%s\")",
username, user, groupname);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdCheckGroup(username=\"%s\", user=%p, groupname=\"%s\")", username, user, groupname);
/*
* Validate input...
@@ -1492,6 +1385,12 @@ cupsdFindBest(const char *path, /* I - Resource path */
strlcpy(uri, path, sizeof(uri));
if ((uriptr = strchr(uri, '?')) != NULL)
*uriptr = '\0'; /* Drop trailing query string */
if ((uriptr = uri + strlen(uri) - 1) > uri && *uriptr == '/')
*uriptr = '\0'; /* Remove trailing '/' */
if (!strncmp(uri, "/printers/", 10) ||
!strncmp(uri, "/classes/", 9))
{
@@ -1505,12 +1404,6 @@ cupsdFindBest(const char *path, /* I - Resource path */
*uriptr = '\0';
}
if ((uriptr = strchr(uri, '?')) != NULL)
*uriptr = '\0'; /* Drop trailing query string */
if ((uriptr = uri + strlen(uri) - 1) > uri && *uriptr == '/')
*uriptr = '\0'; /* Remove trailing '/' */
/*
* Loop through the list of locations to find a match...
*/
@@ -1519,7 +1412,7 @@ cupsdFindBest(const char *path, /* I - Resource path */
best = NULL;
bestlen = 0;
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindBest: uri = \"%s\", limit=%x...", uri, limit);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindBest: uri=\"%s\", limit=%x...", uri, limit);
for (loc = (cupsd_location_t *)cupsArrayFirst(Locations);
@@ -1564,8 +1457,7 @@ cupsdFindBest(const char *path, /* I - Resource path */
* Return the match, if any...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindBest: best = %s",
best ? best->location : "NONE");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindBest: best=%s", best ? best->location : "NONE");
return (best);
}
@@ -1640,13 +1532,9 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
};
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: con->uri=\"%s\", con->best=%p(%s)",
con->uri, con->best, con->best ? con->best->location ?
con->best->location : "(null)" : "");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: con->uri=\"%s\", con->best=%p(%s)", con->uri, con->best, con->best ? con->best->location ? con->best->location : "(null)" : "");
if (owner)
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: owner=\"%s\"", owner);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: owner=\"%s\"", owner);
/*
* If there is no "best" authentication rule for this request, then
@@ -1669,15 +1557,10 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
if ((type = best->type) == CUPSD_AUTH_DEFAULT)
type = cupsdDefaultAuthType();
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: level=CUPSD_AUTH_%s, type=%s, "
"satisfy=CUPSD_AUTH_SATISFY_%s, num_names=%d",
levels[best->level], types[type],
best->satisfy ? "ANY" : "ALL", cupsArrayCount(best->names));
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: level=CUPSD_AUTH_%s, type=%s, satisfy=CUPSD_AUTH_SATISFY_%s, num_names=%d", levels[best->level], types[type], best->satisfy ? "ANY" : "ALL", cupsArrayCount(best->names));
if (best->limit == CUPSD_AUTH_LIMIT_IPP)
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: op=%x(%s)",
best->op, ippOpString(best->op));
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: op=%x(%s)", best->op, ippOpString(best->op));
/*
* Check host/ip-based accesses...
@@ -1716,8 +1599,7 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
auth = cupsdCheckAccess(address, hostname, hostlen, best)
? CUPSD_AUTH_ALLOW : CUPSD_AUTH_DENY;
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: auth=CUPSD_AUTH_%s...",
auth ? "DENY" : "ALLOW");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: auth=CUPSD_AUTH_%s...", auth ? "DENY" : "ALLOW");
if (auth == CUPSD_AUTH_DENY && best->satisfy == CUPSD_AUTH_SATISFY_ALL)
return (HTTP_FORBIDDEN);
@@ -1857,8 +1739,7 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
* allowed...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: Checking user membership...");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: Checking user membership...");
#ifdef HAVE_AUTHORIZATION_H
/*
@@ -1911,8 +1792,7 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
* Check to see if this user is in any of the named groups...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: Checking group membership...");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: Checking group membership...");
/*
* Check to see if this user is in any of the named groups...
@@ -1922,9 +1802,7 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
name;
name = (char *)cupsArrayNext(best->names))
{
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdIsAuthorized: Checking group \"%s\" membership...",
name);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdIsAuthorized: Checking group \"%s\" membership...", name);
if (!_cups_strcasecmp(name, "@SYSTEM"))
{
@@ -1940,8 +1818,7 @@ cupsdIsAuthorized(cupsd_client_t *con, /* I - Connection */
* The user isn't part of the specified group, so deny access...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG,
"cupsdIsAuthorized: User not in group(s)!");
cupsdLogMessage(CUPSD_LOG_DEBUG, "cupsdIsAuthorized: User not in group(s).");
return (con->username[0] ? HTTP_FORBIDDEN : HTTP_UNAUTHORIZED);
}
@@ -2031,9 +1908,7 @@ check_authref(cupsd_client_t *con, /* I - Connection */
return (0);
}
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"AuthorizationCopyRights(\"%s\") succeeded!",
authright.name);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "AuthorizationCopyRights(\"%s\") succeeded.", authright.name);
return (1);
}
@@ -2336,5 +2211,5 @@ to64(char *s, /* O - Output string */
/*
* End of "$Id: auth.c 12602 2015-05-05 20:19:35Z msweet $".
* End of "$Id: auth.c 12945 2015-10-26 19:46:02Z msweet $".
*/
+38 -13
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: cert.c 12034 2014-07-16 19:37:34Z msweet $"
* "$Id: cert.c 12972 2015-11-13 20:30:37Z msweet $"
*
* Authentication certificate routines for the CUPS scheduler.
*
* Copyright 2007-2014 by Apple Inc.
* Copyright 2007-2015 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products.
*
* These coded instructions, statements, and computer programs are the
@@ -26,6 +26,13 @@
#endif /* HAVE_ACL_INIT */
/*
* Local functions...
*/
static int ctcompare(const char *a, const char *b);
/*
* 'cupsdAddCert()' - Add a certificate.
*/
@@ -101,8 +108,7 @@ cupsdAddCert(int pid, /* I - Process ID */
fchmod(fd, 0440);
fchown(fd, RunUser, SystemGroupIDs[0]);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddCert: NumSystemGroups=%d",
NumSystemGroups);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAddCert: NumSystemGroups=%d", NumSystemGroups);
#ifdef HAVE_ACL_INIT
if (NumSystemGroups > 1)
@@ -278,8 +284,7 @@ cupsdDeleteCert(int pid) /* I - Process ID */
* Remove this certificate from the list...
*/
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdDeleteCert: Removing certificate for PID %d", pid);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdDeleteCert: Removing certificate for PID %d.", pid);
DEBUG_printf(("DELETE pid=%d, username=%s, cert=%s\n", cert->pid,
cert->username, cert->certificate));
@@ -353,17 +358,15 @@ cupsdFindCert(const char *certificate) /* I - Certificate */
cupsd_cert_t *cert; /* Current certificate */
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert(certificate=%s)",
certificate);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert(certificate=%s)", certificate);
for (cert = Certs; cert != NULL; cert = cert->next)
if (!_cups_strcasecmp(certificate, cert->certificate))
if (!ctcompare(certificate, cert->certificate))
{
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert: Returning %s...",
cert->username);
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert: Returning \"%s\".", cert->username);
return (cert);
}
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert: Certificate not found!");
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdFindCert: Certificate not found.");
return (NULL);
}
@@ -426,5 +429,27 @@ cupsdInitCerts(void)
/*
* End of "$Id: cert.c 12034 2014-07-16 19:37:34Z msweet $".
* 'ctcompare()' - Compare two strings in constant time.
*/
static int /* O - 0 on match, non-zero on non-match */
ctcompare(const char *a, /* I - First string */
const char *b) /* I - Second string */
{
int result = 0; /* Result */
while (*a && *b)
{
result |= *a ^ *b;
a ++;
b ++;
}
return (result);
}
/*
* End of "$Id: cert.c 12972 2015-11-13 20:30:37Z msweet $".
*/
+125 -120
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: client.c 12751 2015-06-24 18:22:32Z msweet $"
* "$Id: client.c 13061 2016-01-26 21:31:40Z msweet $"
*
* Client routines for the CUPS scheduler.
*
@@ -78,9 +78,7 @@ cupsdAcceptClient(cupsd_listener_t *lis)/* I - Listener socket */
#endif /* HAVE_TCPD_H */
cupsdLogMessage(CUPSD_LOG_DEBUG2,
"cupsdAcceptClient(lis=%p(%d)) Clients=%d",
lis, lis->fd, cupsArrayCount(Clients));
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdAcceptClient(lis=%p(%d)) Clients=%d", lis, lis->fd, cupsArrayCount(Clients));
/*
* Make sure we don't have a full set of clients already...
@@ -383,8 +381,7 @@ cupsdCloseAllClients(void)
cupsd_client_t *con; /* Current client */
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdCloseAllClients() Clients=%d",
cupsArrayCount(Clients));
cupsdLogMessage(CUPSD_LOG_DEBUG2, "cupsdCloseAllClients() Clients=%d", cupsArrayCount(Clients));
for (con = (cupsd_client_t *)cupsArrayFirst(Clients);
con;
@@ -564,22 +561,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
status = HTTP_STATUS_CONTINUE;
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"cupsdReadClient "
"error=%d, "
"used=%d, "
"state=%s, "
"data_encoding=HTTP_ENCODING_%s, "
"data_remaining=" CUPS_LLFMT ", "
"request=%p(%s), "
"file=%d",
httpError(con->http), (int)httpGetReady(con->http),
httpStateString(httpGetState(con->http)),
httpIsChunked(con->http) ? "CHUNKED" : "LENGTH",
CUPS_LLCAST httpGetRemaining(con->http),
con->request,
con->request ? ippStateString(ippGetState(con->request)) : "",
con->file);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cupsdReadClient: error=%d, used=%d, state=%s, data_encoding=HTTP_ENCODING_%s, data_remaining=" CUPS_LLFMT ", request=%p(%s), file=%d", httpError(con->http), (int)httpGetReady(con->http), httpStateString(httpGetState(con->http)), httpIsChunked(con->http) ? "CHUNKED" : "LENGTH", CUPS_LLCAST httpGetRemaining(con->http), con->request, con->request ? ippStateString(ippGetState(con->request)) : "", con->file);
if (httpGetState(con->http) == HTTP_STATE_GET_SEND ||
httpGetState(con->http) == HTTP_STATE_POST_SEND ||
@@ -601,8 +583,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
return;
}
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Closing on unexpected HTTP read state %s.",
httpStateString(httpGetState(con->http)));
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Closing on unexpected HTTP read state %s.", httpStateString(httpGetState(con->http)));
cupsdCloseClient(con);
return;
}
@@ -623,9 +604,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
* Encrypt this connection...
*/
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"Saw first byte %02X, auto-negotiating "
"SSL/TLS session.", buf[0] & 255);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "Saw first byte %02X, auto-negotiating SSL/TLS session.", buf[0] & 255);
if (cupsd_start_tls(con, HTTP_ENCRYPTION_ALWAYS))
cupsdCloseClient(con);
@@ -1177,29 +1156,28 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
break;
}
}
else if (!WebInterface)
{
/*
* Web interface is disabled. Show an appropriate message...
*/
if (!cupsdSendError(con, HTTP_STATUS_CUPS_WEBIF_DISABLED, CUPSD_AUTH_NONE))
{
cupsdCloseClient(con);
return;
}
break;
}
if ((!strncmp(con->uri, "/admin", 6) &&
strncmp(con->uri, "/admin/conf/", 12) &&
strncmp(con->uri, "/admin/log/", 11)) ||
if ((!strncmp(con->uri, "/admin", 6) && strcmp(con->uri, "/admin/conf/cupsd.conf") && strncmp(con->uri, "/admin/log/", 11)) ||
!strncmp(con->uri, "/printers", 9) ||
!strncmp(con->uri, "/classes", 8) ||
!strncmp(con->uri, "/help", 5) ||
!strncmp(con->uri, "/jobs", 5))
{
if (!WebInterface)
{
/*
* Web interface is disabled. Show an appropriate message...
*/
if (!cupsdSendError(con, HTTP_STATUS_CUPS_WEBIF_DISABLED, CUPSD_AUTH_NONE))
{
cupsdCloseClient(con);
return;
}
break;
}
/*
* Send CGI output...
*/
@@ -1266,20 +1244,14 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
if (httpGetVersion(con->http) <= HTTP_VERSION_1_0)
httpSetKeepAlive(con->http, HTTP_KEEPALIVE_OFF);
}
else if ((!strncmp(con->uri, "/admin/conf/", 12) &&
(strchr(con->uri + 12, '/') ||
strlen(con->uri) == 12)) ||
(!strncmp(con->uri, "/admin/log/", 11) &&
(strchr(con->uri + 11, '/') ||
strlen(con->uri) == 11)))
else if (!strncmp(con->uri, "/admin/log/", 11) && (strchr(con->uri + 11, '/') || strlen(con->uri) == 11))
{
/*
* GET can only be done to configuration files directly under
* /admin/conf...
*/
cupsdLogClient(con, CUPSD_LOG_ERROR,
"Request for subdirectory \"%s\"!", con->uri);
cupsdLogClient(con, CUPSD_LOG_ERROR, "Request for subdirectory \"%s\".", con->uri);
if (!cupsdSendError(con, HTTP_STATUS_FORBIDDEN, CUPSD_AUTH_NONE))
{
@@ -1417,9 +1389,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
break;
}
else if ((!strncmp(con->uri, "/admin", 6) &&
strncmp(con->uri, "/admin/conf/", 12) &&
strncmp(con->uri, "/admin/log/", 11)) ||
else if ((!strncmp(con->uri, "/admin", 6) && strncmp(con->uri, "/admin/log/", 11)) ||
!strncmp(con->uri, "/printers", 9) ||
!strncmp(con->uri, "/classes", 8) ||
!strncmp(con->uri, "/help", 5) ||
@@ -1669,9 +1639,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
break;
}
if ((!strncmp(con->uri, "/admin", 6) &&
strncmp(con->uri, "/admin/conf/", 12) &&
strncmp(con->uri, "/admin/log/", 11)) ||
if ((!strncmp(con->uri, "/admin", 6) && strcmp(con->uri, "/admin/conf/cupsd.conf") && strncmp(con->uri, "/admin/log/", 11)) ||
!strncmp(con->uri, "/printers", 9) ||
!strncmp(con->uri, "/classes", 8) ||
!strncmp(con->uri, "/help", 5) ||
@@ -1691,12 +1659,7 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
cupsdLogRequest(con, HTTP_STATUS_OK);
}
else if ((!strncmp(con->uri, "/admin/conf/", 12) &&
(strchr(con->uri + 12, '/') ||
strlen(con->uri) == 12)) ||
(!strncmp(con->uri, "/admin/log/", 11) &&
(strchr(con->uri + 11, '/') ||
strlen(con->uri) == 11)))
else if (!strncmp(con->uri, "/admin/log/", 11) && (strchr(con->uri + 11, '/') || strlen(con->uri) == 11))
{
/*
* HEAD can only be done to configuration files under
@@ -1799,6 +1762,20 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
{
con->bytes += bytes;
if (MaxRequestSize > 0 && con->bytes > MaxRequestSize)
{
close(con->file);
con->file = -1;
unlink(con->filename);
cupsdClearString(&con->filename);
if (!cupsdSendError(con, HTTP_STATUS_REQUEST_TOO_LARGE, CUPSD_AUTH_NONE))
{
cupsdCloseClient(con);
return;
}
}
if (write(con->file, line, (size_t)bytes) < bytes)
{
cupsdLogClient(con, CUPSD_LOG_ERROR,
@@ -1817,6 +1794,11 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
}
}
}
else if (httpGetState(con->http) == HTTP_STATE_PUT_RECV)
{
cupsdCloseClient(con);
return;
}
}
while (httpGetState(con->http) == HTTP_STATE_PUT_RECV && httpGetReady(con->http));
@@ -1960,6 +1942,20 @@ cupsdReadClient(cupsd_client_t *con) /* I - Client to read from */
{
con->bytes += bytes;
if (MaxRequestSize > 0 && con->bytes > MaxRequestSize)
{
close(con->file);
con->file = -1;
unlink(con->filename);
cupsdClearString(&con->filename);
if (!cupsdSendError(con, HTTP_STATUS_REQUEST_TOO_LARGE, CUPSD_AUTH_NONE))
{
cupsdCloseClient(con);
return;
}
}
if (write(con->file, line, (size_t)bytes) < bytes)
{
cupsdLogClient(con, CUPSD_LOG_ERROR,
@@ -2162,8 +2158,7 @@ cupsdSendError(cupsd_client_t *con, /* I - Connection */
char location[HTTP_MAX_VALUE]; /* Location field */
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cupsdSendError code=%d, auth_type=%d",
code, auth_type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "cupsdSendError code=%d, auth_type=%d", code, auth_type);
#ifdef HAVE_SSL
/*
@@ -2838,11 +2833,7 @@ check_if_modified(
if (*ptr == '\0')
return (1);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"check_if_modified "
"filestats=%p(" CUPS_LLFMT ", %d)) If-Modified-Since=\"%s\"",
filestats, CUPS_LLCAST filestats->st_size,
(int)filestats->st_mtime, ptr);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "check_if_modified: filestats=%p(" CUPS_LLFMT ", %d)) If-Modified-Since=\"%s\"", filestats, CUPS_LLCAST filestats->st_size, (int)filestats->st_mtime, ptr);
while (*ptr != '\0')
{
@@ -2909,7 +2900,7 @@ cupsd_start_tls(cupsd_client_t *con, /* I - Client connection */
return (-1);
}
cupsdLogClient(con, CUPSD_LOG_INFO, "Connection now encrypted.");
cupsdLogClient(con, CUPSD_LOG_DEBUG, "Connection now encrypted.");
return (0);
}
#endif /* HAVE_SSL */
@@ -2928,7 +2919,8 @@ get_file(cupsd_client_t *con, /* I - Client connection */
int status; /* Status of filesystem calls */
char *ptr; /* Pointer info filename */
size_t plen; /* Remaining length after pointer */
char language[7]; /* Language subdirectory, if any */
char language[7], /* Language subdirectory, if any */
dest[1024]; /* Destination name */
int perm_check = 1; /* Do permissions check? */
@@ -2940,13 +2932,45 @@ get_file(cupsd_client_t *con, /* I - Client connection */
if (!strncmp(con->uri, "/ppd/", 5) && !strchr(con->uri + 5, '/'))
{
strlcpy(dest, con->uri + 5, sizeof(dest));
ptr = dest + strlen(dest) - 4;
if (ptr <= dest || strcmp(ptr, ".ppd"))
{
cupsdLogClient(con, CUPSD_LOG_INFO, "Disallowed path \"%s\".", con->uri);
return (NULL);
}
*ptr = '\0';
if (!cupsdFindPrinter(dest))
{
cupsdLogClient(con, CUPSD_LOG_INFO, "No printer \"%s\" found.", dest);
return (NULL);
}
snprintf(filename, len, "%s%s", ServerRoot, con->uri);
perm_check = 0;
}
else if (!strncmp(con->uri, "/icons/", 7) && !strchr(con->uri + 7, '/'))
{
snprintf(filename, len, "%s/%s", CacheDir, con->uri + 7);
strlcpy(dest, con->uri + 7, sizeof(dest));
ptr = dest + strlen(dest) - 4;
if (ptr <= dest || strcmp(ptr, ".png"))
{
cupsdLogClient(con, CUPSD_LOG_INFO, "Disallowed path \"%s\".", con->uri);
return (NULL);
}
*ptr = '\0';
if (!cupsdFindDest(dest))
{
cupsdLogClient(con, CUPSD_LOG_INFO, "No printer \"%s\" found.", dest);
return (NULL);
}
snprintf(filename, len, "%s/%s.png", CacheDir, dest);
if (access(filename, F_OK) < 0)
snprintf(filename, len, "%s/images/generic.png", DocumentRoot);
@@ -3152,7 +3176,7 @@ get_file(cupsd_client_t *con, /* I - Client connection */
}
}
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "get_file filestats=%p, filename=%p, len=" CUPS_LLFMT ", returning \"%s\".", filestats, filename, CUPS_LLCAST len, status ? "(null)" : filename);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "get_file: filestats=%p, filename=%p, len=" CUPS_LLFMT ", returning \"%s\".", filestats, filename, CUPS_LLCAST len, status ? "(null)" : filename);
if (status)
return (NULL);
@@ -3183,7 +3207,7 @@ install_cupsd_conf(cupsd_client_t *con) /* I - Connection */
{
cupsdLogClient(con, CUPSD_LOG_ERROR, "Unable to open request file \"%s\": %s",
con->filename, strerror(errno));
return (HTTP_STATUS_SERVER_ERROR);
goto server_error;
}
/*
@@ -3193,7 +3217,7 @@ install_cupsd_conf(cupsd_client_t *con) /* I - Connection */
if ((out = cupsdCreateConfFile(ConfigurationFile, ConfigFilePerm)) == NULL)
{
cupsFileClose(in);
return (HTTP_STATUS_SERVER_ERROR);
goto server_error;
}
cupsdLogClient(con, CUPSD_LOG_INFO, "Installing config file \"%s\"...",
@@ -3216,7 +3240,7 @@ install_cupsd_conf(cupsd_client_t *con) /* I - Connection */
snprintf(filename, sizeof(filename), "%s.N", ConfigurationFile);
cupsdUnlinkOrRemoveFile(filename);
return (HTTP_STATUS_SERVER_ERROR);
goto server_error;
}
/*
@@ -3226,7 +3250,7 @@ install_cupsd_conf(cupsd_client_t *con) /* I - Connection */
cupsFileClose(in);
if (cupsdCloseCreatedConfFile(out, ConfigurationFile))
return (HTTP_STATUS_SERVER_ERROR);
goto server_error;
/*
* Remove the request file...
@@ -3247,6 +3271,17 @@ install_cupsd_conf(cupsd_client_t *con) /* I - Connection */
*/
return (HTTP_STATUS_CREATED);
/*
* Common exit for errors...
*/
server_error:
cupsdUnlinkOrRemoveFile(con->filename);
cupsdClearString(&con->filename);
return (HTTP_STATUS_SERVER_ERROR);
}
@@ -3279,11 +3314,7 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
if (!type || _cups_strcasecmp(type->super, "application"))
{
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 0", filename,
filestats, type ? type->super : "unknown",
type ? type->type : "unknown");
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 0.", filename, filestats, type ? type->super : "unknown", type ? type->type : "unknown");
return (0);
}
@@ -3299,10 +3330,7 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
if (options)
cupsdSetStringf(&con->options, " %s", options);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 1", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 1.", filename, filestats, type->super, type->type);
return (1);
}
#ifdef HAVE_JAVA
@@ -3319,10 +3347,7 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
else
cupsdSetStringf(&con->options, " %s", filename);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 1", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 1.", filename, filestats, type->super, type->type);
return (1);
}
#endif /* HAVE_JAVA */
@@ -3340,10 +3365,7 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
else
cupsdSetStringf(&con->options, " %s", filename);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 1", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 1.", filename, filestats, type->super, type->type);
return (1);
}
#endif /* HAVE_PERL */
@@ -3361,10 +3383,7 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
else
cupsdSetStringf(&con->options, " %s", filename);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 1", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 1.", filename, filestats, type->super, type->type);
return (1);
}
#endif /* HAVE_PHP */
@@ -3382,18 +3401,12 @@ is_cgi(cupsd_client_t *con, /* I - Client connection */
else
cupsdSetStringf(&con->options, " %s", filename);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 1", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 1.", filename, filestats, type->super, type->type);
return (1);
}
#endif /* HAVE_PYTHON */
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"is_cgi filename=\"%s\", filestats=%p, "
"type=%s/%s, returning 0", filename,
filestats, type->super, type->type);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "is_cgi: filename=\"%s\", filestats=%p, type=%s/%s, returning 0.", filename, filestats, type->super, type->type);
return (0);
}
@@ -3500,11 +3513,7 @@ pipe_command(cupsd_client_t *con, /* I - Client connection */
* be consistent with Apache...
*/
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"pipe_command infile=%d, outfile=%p, "
"command=\"%s\", options=\"%s\", root=%d",
infile, outfile, command,
options ? options : "(null)", root);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "pipe_command: infile=%d, outfile=%p, command=\"%s\", options=\"%s\", root=%d", infile, outfile, command, options ? options : "(null)", root);
argv[0] = command;
@@ -4021,10 +4030,7 @@ write_file(cupsd_client_t *con, /* I - Client connection */
{
con->file = open(filename, O_RDONLY);
cupsdLogClient(con, CUPSD_LOG_DEBUG2,
"write_file code=%d, filename=\"%s\" (%d), "
"type=\"%s\", filestats=%p",
code, filename, con->file, type ? type : "(null)", filestats);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "write_file: code=%d, filename=\"%s\" (%d), type=\"%s\", filestats=%p.", code, filename, con->file, type ? type : "(null)", filestats);
if (con->file < 0)
return (0);
@@ -4059,8 +4065,7 @@ write_file(cupsd_client_t *con, /* I - Client connection */
static void
write_pipe(cupsd_client_t *con) /* I - Client connection */
{
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "write_pipe CGI output on fd %d",
con->file);
cupsdLogClient(con, CUPSD_LOG_DEBUG2, "write_pipe: CGI output on fd %d.", con->file);
con->file_ready = 1;
@@ -4072,5 +4077,5 @@ write_pipe(cupsd_client_t *con) /* I - Client connection */
/*
* End of "$Id: client.c 12751 2015-06-24 18:22:32Z msweet $".
* End of "$Id: client.c 13061 2016-01-26 21:31:40Z msweet $".
*/
+25 -37
Ver Arquivo
@@ -1,9 +1,7 @@
/*
* "$Id: cups-lpd.c 12611 2015-05-06 15:30:36Z msweet $"
*
* Line Printer Daemon interface for CUPS.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products, all rights reserved.
*
* These coded instructions, statements, and computer programs are the
@@ -17,6 +15,7 @@
* Include necessary headers...
*/
#define _CUPS_NO_DEPRECATED
#include <cups/cups-private.h>
#include <syslog.h>
#include <unistd.h>
@@ -346,7 +345,7 @@ create_job(http_t *http, /* I - HTTP connection */
* Setup the Create-Job request...
*/
request = ippNewRequest(IPP_CREATE_JOB);
request = ippNewRequest(IPP_OP_CREATE_JOB);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
@@ -361,10 +360,6 @@ create_job(http_t *http, /* I - HTTP connection */
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "job-name",
NULL, title);
if (docname[0])
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_NAME, "document-name",
NULL, docname);
cupsEncodeOptions(request, num_options, options);
/*
@@ -375,7 +370,7 @@ create_job(http_t *http, /* I - HTTP connection */
response = cupsDoRequest(http, request, uri);
if (!response || cupsLastError() > IPP_OK_CONFLICT)
if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to create job - %s", cupsLastErrorString());
@@ -451,7 +446,7 @@ get_printer(http_t *http, /* I - HTTP connection */
if (shared)
*shared = 0;
if (state)
*state = IPP_PRINTER_STOPPED;
*state = IPP_PSTATE_STOPPED;
if (options)
*options = NULL;
@@ -467,7 +462,7 @@ get_printer(http_t *http, /* I - HTTP connection */
* Setup the Get-Printer-Attributes request...
*/
request = ippNewRequest(IPP_GET_PRINTER_ATTRIBUTES);
request = ippNewRequest(IPP_OP_GET_PRINTER_ATTRIBUTES);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
@@ -486,7 +481,7 @@ get_printer(http_t *http, /* I - HTTP connection */
response = cupsDoRequest(http, request, "/");
if (!response || cupsLastError() > IPP_OK_CONFLICT)
if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
/*
* If we can't find the printer by name, look up the printer-name
@@ -506,7 +501,7 @@ get_printer(http_t *http, /* I - HTTP connection */
* Setup the CUPS-Get-Printers request...
*/
request = ippNewRequest(CUPS_GET_PRINTERS);
request = ippNewRequest(IPP_OP_CUPS_GET_PRINTERS);
ippAddStrings(request, IPP_TAG_OPERATION, IPP_TAG_KEYWORD,
"requested-attributes",
@@ -519,7 +514,7 @@ get_printer(http_t *http, /* I - HTTP connection */
response = cupsDoRequest(http, request, "/");
if (!response || cupsLastError() > IPP_OK_CONFLICT)
if (!response || cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to get list of printers - %s",
cupsLastErrorString());
@@ -734,7 +729,7 @@ print_file(http_t *http, /* I - HTTP connection */
* Setup the Send-Document request...
*/
request = ippNewRequest(IPP_SEND_DOCUMENT);
request = ippNewRequest(IPP_OP_SEND_DOCUMENT);
snprintf(uri, sizeof(uri), "ipp://localhost/jobs/%d", id);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "job-uri", NULL, uri);
@@ -760,7 +755,7 @@ print_file(http_t *http, /* I - HTTP connection */
ippDelete(cupsDoFileRequest(http, request, uri, filename));
if (cupsLastError() > IPP_OK_CONFLICT)
if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_ERR, "Unable to send document - %s", cupsLastErrorString());
@@ -815,7 +810,7 @@ recv_print_job(
* Connect to the server...
*/
http = httpConnectEncrypt(cupsServer(), ippPort(), cupsEncryption());
http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL);
if (!http)
{
syslog(LOG_ERR, "Unable to connect to server: %s", strerror(errno));
@@ -1245,8 +1240,7 @@ remove_jobs(const char *dest, /* I - Destination */
* Try connecting to the local server...
*/
if ((http = httpConnectEncrypt(cupsServer(), ippPort(),
cupsEncryption())) == NULL)
if ((http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL)) == NULL)
{
syslog(LOG_ERR, "Unable to connect to server %s: %s", cupsServer(),
strerror(errno));
@@ -1269,7 +1263,7 @@ remove_jobs(const char *dest, /* I - Destination */
list ++;
/*
* Build an IPP_CANCEL_JOB request, which requires the following
* Build an IPP_OP_CANCEL_JOB request, which requires the following
* attributes:
*
* attributes-charset
@@ -1278,7 +1272,7 @@ remove_jobs(const char *dest, /* I - Destination */
* requesting-user-name
*/
request = ippNewRequest(IPP_CANCEL_JOB);
request = ippNewRequest(IPP_OP_CANCEL_JOB);
sprintf(uri, "ipp://localhost/jobs/%d", id);
ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_URI, "job-uri", NULL, uri);
@@ -1292,7 +1286,7 @@ remove_jobs(const char *dest, /* I - Destination */
ippDelete(cupsDoRequest(http, request, "/jobs"));
if (cupsLastError() > IPP_OK_CONFLICT)
if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
syslog(LOG_WARNING, "Cancel of job ID %d failed: %s\n", id,
cupsLastErrorString());
@@ -1366,8 +1360,7 @@ send_state(const char *queue, /* I - Destination */
* Try connecting to the local server...
*/
if ((http = httpConnectEncrypt(cupsServer(), ippPort(),
cupsEncryption())) == NULL)
if ((http = httpConnect2(cupsServer(), ippPort(), NULL, AF_UNSPEC, cupsEncryption(), 1, 30000, NULL)) == NULL)
{
syslog(LOG_ERR, "Unable to connect to server %s: %s", cupsServer(),
strerror(errno));
@@ -1393,19 +1386,19 @@ send_state(const char *queue, /* I - Destination */
switch (state)
{
case IPP_PRINTER_IDLE :
case IPP_PSTATE_IDLE :
printf("%s is ready\n", dest);
break;
case IPP_PRINTER_PROCESSING :
case IPP_PSTATE_PROCESSING :
printf("%s is ready and printing\n", dest);
break;
case IPP_PRINTER_STOPPED :
case IPP_PSTATE_STOPPED :
printf("%s is not ready\n", dest);
break;
}
/*
* Build an IPP_GET_JOBS or IPP_GET_JOB_ATTRIBUTES request, which requires
* Build an IPP_OP_GET_JOBS or IPP_OP_GET_JOB_ATTRIBUTES request, which requires
* the following attributes:
*
* attributes-charset
@@ -1415,7 +1408,7 @@ send_state(const char *queue, /* I - Destination */
id = atoi(list);
request = ippNewRequest(id ? IPP_GET_JOB_ATTRIBUTES : IPP_GET_JOBS);
request = ippNewRequest(id ? IPP_OP_GET_JOB_ATTRIBUTES : IPP_OP_GET_JOBS);
httpAssembleURIf(HTTP_URI_CODING_ALL, uri, sizeof(uri), "ipp", NULL,
"localhost", 0, "/printers/%s", dest);
@@ -1444,7 +1437,7 @@ send_state(const char *queue, /* I - Destination */
jobcount = 0;
response = cupsDoRequest(http, request, "/");
if (cupsLastError() > IPP_OK_CONFLICT)
if (cupsLastError() > IPP_STATUS_OK_CONFLICTING)
{
printf("get-jobs failed: %s\n", cupsLastErrorString());
ippDelete(response);
@@ -1473,7 +1466,7 @@ send_state(const char *queue, /* I - Destination */
jobid = 0;
jobsize = 0;
jobstate = IPP_JOB_PENDING;
jobstate = IPP_JSTATE_PENDING;
jobname = "untitled";
jobuser = NULL;
jobdest = NULL;
@@ -1534,7 +1527,7 @@ send_state(const char *queue, /* I - Destination */
* Display the job...
*/
if (jobstate == IPP_JOB_PROCESSING)
if (jobstate == IPP_JSTATE_PROCESSING)
strlcpy(rankstr, "active", sizeof(rankstr));
else
{
@@ -1626,8 +1619,3 @@ smart_gets(char *s, /* I - Pointer to line buffer */
else
return (s);
}
/*
* End of "$Id: cups-lpd.c 12611 2015-05-06 15:30:36Z msweet $".
*/
+55 -4
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: ipp.c 12851 2015-08-28 13:17:53Z msweet $"
* "$Id: ipp.c 13040 2016-01-11 20:29:13Z msweet $"
*
* IPP routines for the CUPS scheduler.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2007 by Easy Software Products, all rights reserved.
*
* This file contains Kerberos support code, copyright 2006 by
@@ -978,6 +978,16 @@ add_class(cupsd_client_t *con, /* I - Client connection */
if ((attr = ippFindAttribute(con->request, "printer-is-shared",
IPP_TAG_BOOLEAN)) != NULL)
{
if (pclass->type & CUPS_PRINTER_REMOTE)
{
/*
* Cannot re-share remote printers.
*/
send_ipp_status(con, IPP_BAD_REQUEST, _("Cannot change printer-is-shared for remote queues."));
return;
}
if (pclass->shared && !attr->values[0].boolean)
cupsdDeregisterPrinter(pclass, 1);
@@ -1682,7 +1692,24 @@ add_job(cupsd_client_t *con, /* I - Client connection */
attr = ippAddString(job->attrs, IPP_TAG_JOB, IPP_TAG_KEYWORD,
"job-hold-until", NULL, val);
}
if (attr && strcmp(attr->values[0].string.text, "no-hold"))
if (printer->holding_new_jobs)
{
/*
* Hold all new jobs on this printer...
*/
if (attr && strcmp(attr->values[0].string.text, "no-hold"))
cupsdSetJobHoldUntil(job, ippGetString(attr, 0, NULL), 0);
else
cupsdSetJobHoldUntil(job, "indefinite", 0);
job->state->values[0].integer = IPP_JOB_HELD;
job->state_value = IPP_JOB_HELD;
ippSetString(job->attrs, &job->reasons, 0, "job-held-on-create");
}
else if (attr && strcmp(attr->values[0].string.text, "no-hold"))
{
/*
* Hold job until specified time...
@@ -2471,6 +2498,16 @@ add_printer(cupsd_client_t *con, /* I - Client connection */
return;
}
if (printer->type & CUPS_PRINTER_REMOTE)
{
/*
* Cannot re-share remote printers.
*/
send_ipp_status(con, IPP_BAD_REQUEST, _("Cannot change printer-is-shared for remote queues."));
return;
}
if (printer->shared && !attr->values[0].boolean)
cupsdDeregisterPrinter(printer, 1);
@@ -7288,6 +7325,12 @@ get_subscription_attrs(
"get_subscription_attrs(con=%p[%d], sub_id=%d)",
con, con->number, sub_id);
/*
* Expire subscriptions as needed...
*/
cupsdExpireSubscriptions(NULL, NULL);
/*
* Is the subscription ID valid?
*/
@@ -7437,6 +7480,12 @@ get_subscriptions(cupsd_client_t *con, /* I - Client connection */
return;
}
/*
* Expire subscriptions as needed...
*/
cupsdExpireSubscriptions(NULL, NULL);
/*
* Copy the subscription attributes to the response using the
* requested-attributes attribute that may be provided by the client.
@@ -8636,6 +8685,8 @@ release_held_new_jobs(
"Printer \"%s\" now printing pending/new jobs (\"%s\").",
printer->name, get_username(con));
cupsdCheckJobs();
/*
* Everything was ok, so return OK status...
*/
@@ -11149,5 +11200,5 @@ validate_user(cupsd_job_t *job, /* I - Job */
/*
* End of "$Id: ipp.c 12851 2015-08-28 13:17:53Z msweet $".
* End of "$Id: ipp.c 13040 2016-01-11 20:29:13Z msweet $".
*/
+29 -6
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: job.c 12856 2015-08-31 14:27:39Z msweet $"
* "$Id: job.c 13047 2016-01-13 19:16:12Z msweet $"
*
* Job management routines for the CUPS scheduler.
*
@@ -229,6 +229,7 @@ cupsdCheckJobs(void)
*pclass; /* Printer class destination */
ipp_attribute_t *attr; /* Job attribute */
time_t curtime; /* Current time */
const char *reasons; /* job-state-reasons value */
curtime = time(NULL);
@@ -322,6 +323,25 @@ cupsdCheckJobs(void)
((FilterLevel + job->pending_cost) < FilterLimit || FilterLevel == 0))
cupsdContinueJob(job);
/*
* Skip jobs that where held-on-create
*/
reasons = ippGetString(job->reasons, 0, NULL);
if (reasons && !strcmp(reasons, "job-held-on-create"))
{
/*
* Check whether the printer is still holding new jobs...
*/
printer = cupsdFindDest(job->dest);
if (printer->holding_new_jobs)
continue;
ippSetString(job->attrs, &job->reasons, 0, "none");
}
/*
* Start pending jobs if the destination is available...
*/
@@ -359,7 +379,7 @@ cupsdCheckJobs(void)
"Job aborted because the destination printer/class "
"has gone away.");
}
else if (printer && !printer->holding_new_jobs)
else if (printer)
{
/*
* See if the printer is available or remote and not printing a job;
@@ -732,8 +752,8 @@ cupsdContinueJob(cupsd_job_t *job) /* I - Job */
* Add decompression/raw filter as needed...
*/
if (job->compressions[job->current_file] &&
(!job->printer->remote || job->num_files == 1))
if ((job->compressions[job->current_file] && (!job->printer->remote || job->num_files == 1)) ||
(!job->printer->remote && job->printer->raw && job->num_files > 1))
{
/*
* Add gziptoany filter to the front of the list...
@@ -2316,7 +2336,10 @@ cupsdSetJobHoldUntil(cupsd_job_t *job, /* I - Job */
}
ippSetString(job->attrs, &job->reasons, 0, "job-hold-until-specified");
if (strcmp(when, "no-hold"))
ippSetString(job->attrs, &job->reasons, 0, "job-hold-until-specified");
else
ippSetString(job->attrs, &job->reasons, 0, "none");
/*
* Update the hold time...
@@ -5341,5 +5364,5 @@ update_job_attrs(cupsd_job_t *job, /* I - Job to update */
/*
* End of "$Id: job.c 12856 2015-08-31 14:27:39Z msweet $".
* End of "$Id: job.c 13047 2016-01-13 19:16:12Z msweet $".
*/
+3 -4
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: log.c 12857 2015-08-31 15:00:45Z msweet $"
* "$Id: log.c 12928 2015-10-23 21:31:58Z msweet $"
*
* Log file routines for the CUPS scheduler.
*
@@ -1476,7 +1476,7 @@ format_log_line(const char *message, /* I - Printf-style format string */
* Format the log message...
*/
len = vsnprintf(log_line, log_linesize, message, ap);
len = _cups_safe_vsnprintf(log_line, log_linesize, message, ap);
/*
* Resize the buffer as needed...
@@ -1486,7 +1486,6 @@ format_log_line(const char *message, /* I - Printf-style format string */
{
char *temp; /* Temporary string pointer */
len ++;
if (len < 8192)
@@ -1510,5 +1509,5 @@ format_log_line(const char *message, /* I - Printf-style format string */
/*
* End of "$Id: log.c 12857 2015-08-31 15:00:45Z msweet $".
* End of "$Id: log.c 12928 2015-10-23 21:31:58Z msweet $".
*/
+6 -21
Ver Arquivo
@@ -1,9 +1,9 @@
/*
* "$Id: main.c 12700 2015-06-08 18:32:35Z msweet $"
* "$Id: main.c 13087 2016-02-12 18:53:24Z msweet $"
*
* Main loop for the CUPS scheduler.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2007 by Easy Software Products, all rights reserved.
*
* These coded instructions, statements, and computer programs are the
@@ -1573,7 +1573,6 @@ select_timeout(int fds) /* I - Number of descriptors returned */
time_t now; /* Current time */
cupsd_client_t *con; /* Client information */
cupsd_job_t *job; /* Job information */
cupsd_subscription_t *sub; /* Subscription information */
const char *why; /* Debugging aid */
@@ -1710,19 +1709,6 @@ select_timeout(int fds) /* I - Number of descriptors returned */
}
#endif /* HAVE_MALLINFO */
/*
* Expire subscriptions as needed...
*/
for (sub = (cupsd_subscription_t *)cupsArrayFirst(Subscriptions);
sub;
sub = (cupsd_subscription_t *)cupsArrayNext(Subscriptions))
if (!sub->job && sub->expire && sub->expire < timeout)
{
timeout = sub->expire;
why = "expire subscription";
}
/*
* Adjust from absolute to relative time. We add 1 second to the timeout since
* events occur after the timeout expires, and limit the timeout to 86400
@@ -2177,17 +2163,16 @@ usage(int status) /* O - Exit status */
_cupsLangPuts(fp, _("Options:"));
_cupsLangPuts(fp, _(" -c cupsd.conf Set cupsd.conf file to use."));
_cupsLangPuts(fp, _(" -f Run in the foreground."));
_cupsLangPuts(fp, _(" -F Run in the foreground but "
"detach from console."));
_cupsLangPuts(fp, _(" -F Run in the foreground but detach from console."));
_cupsLangPuts(fp, _(" -h Show this usage message."));
_cupsLangPuts(fp, _(" -l Run cupsd on demand."));
_cupsLangPuts(fp, _(" -t Test the configuration "
"file."));
_cupsLangPuts(fp, _(" -s cups-files.conf Set cups-files.conf file to use."));
_cupsLangPuts(fp, _(" -t Test the configuration file."));
exit(status);
}
/*
* End of "$Id: main.c 12700 2015-06-08 18:32:35Z msweet $".
* End of "$Id: main.c 13087 2016-02-12 18:53:24Z msweet $".
*/
+1 -1
Ver Arquivo
@@ -9,7 +9,7 @@
<key>EnableTransactions</key>
<true/>
<key>EnablePressuredExit</key>
<true/>
<false/>
<key>ExitTimeOut</key>
<integer>60</integer>
<key>KeepAlive</key>
+5 -5
Ver Arquivo
@@ -1,5 +1,5 @@
/*
* "$Id: subscriptions.c 11558 2014-02-06 18:33:34Z msweet $"
* "$Id: subscriptions.c 13040 2016-01-11 20:29:13Z msweet $"
*
* Subscription routines for the CUPS scheduler.
*
@@ -105,9 +105,7 @@ cupsdAddEvent(
* Check if this subscription requires this event...
*/
if ((sub->mask & event) != 0 &&
(sub->dest == dest || !sub->dest) &&
(sub->job == job || !sub->job))
if ((sub->mask & event) != 0 && (sub->dest == dest || !sub->dest || sub->job == job))
{
/*
* Need this event, so create a new event record...
@@ -659,6 +657,8 @@ cupsdExpireSubscriptions(
curtime = time(NULL);
update = 0;
cupsdLogMessage(CUPSD_LOG_INFO, "Expiring subscriptions...");
for (sub = (cupsd_subscription_t *)cupsArrayFirst(Subscriptions);
sub;
sub = (cupsd_subscription_t *)cupsArrayNext(Subscriptions))
@@ -1617,5 +1617,5 @@ cupsd_update_notifier(void)
/*
* End of "$Id: subscriptions.c 11558 2014-02-06 18:33:34Z msweet $".
* End of "$Id: subscriptions.c 13040 2016-01-11 20:29:13Z msweet $".
*/
+3 -9
Ver Arquivo
@@ -1,9 +1,7 @@
/*
* "$Id: type.c 12577 2015-03-30 19:07:17Z msweet $"
*
* MIME typing routines for CUPS.
*
* Copyright 2007-2015 by Apple Inc.
* Copyright 2007-2016 by Apple Inc.
* Copyright 1997-2006 by Easy Software Products, all rights reserved.
*
* These coded instructions, statements, and computer programs are the
@@ -65,7 +63,8 @@ static const char * const debug_ops[] =
"INT", /* Integer/32-bit word matches */
"LOCALE", /* Current locale matches string */
"CONTAINS", /* File contains a string */
"ISTRING" /* Case-insensitive string matches */
"ISTRING", /* Case-insensitive string matches */
"REGEX" /* Regular expression matches */
};
#endif /* DEBUG */
@@ -1276,8 +1275,3 @@ mime_patmatch(const char *s, /* I - String to match against */
return (*s == *pat);
}
/*
* End of "$Id: type.c 12577 2015-03-30 19:07:17Z msweet $".
*/
+1 -1
Ver Arquivo
@@ -2,4 +2,4 @@
{?which_jobs=completed?:<FORM ACTION="{?printer_name=?/jobs:{printer_uri_supported}}" METHOD="GET"><INPUT TYPE="HIDDEN" NAME="which_jobs" VALUE="completed"><INPUT TYPE="SUBMIT" VALUE="Fertige Aufträge anzeigen"></FORM>}
{?which_jobs=all?:<FORM ACTION="{?printer_name=?/jobs:{printer_uri_supported}}" METHOD="GET"><INPUT TYPE="HIDDEN" NAME="which_jobs" VALUE="all"><INPUT TYPE="SUBMIT" VALUE="Alle Aufträge anzeigen"></FORM>}
<P ALIGN="CENTER">{total=0?Keine Aufträge:Zeige {#job_id} von {total} {?which_jobs=?aktiven:{which_jobs=all?:beendeten}} {total=1?:s}Auftrag:Aufträgen}.</P>
<P ALIGN="CENTER">{total=0?Keine Aufträge:Zeige {#job_id} von {total} {?which_jobs=?aktiven:{which_jobs=all?:beendeten}} {total=1?Auftrag:Aufträgen}}.</P>
+9
Ver Arquivo
@@ -0,0 +1,9 @@
<DIV CLASS="indent">
<H2 CLASS="title">Aufträge für {is_class?die Klasse:den Drucker} {printer_name} verwerfen</H2>
<P>Aufträge für {is_class?die Klasse:den Drucker} <A
HREF="/{is_class?classes:printers}/{printer_name}">{printer_name}</A>
wurden verworfen.</P>
</DIV>
+40
Ver Arquivo
@@ -0,0 +1,40 @@
<DIV CLASS="indent">
<H2 CLASS="title">Ersetze {printer_name} PPD Datei</H2>
<FORM METHOD="POST" ENCTYPE="multipart/form-data" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="PRINTER_IS_SHARED" VALUE="{?printer_is_shared}">
<INPUT TYPE="HIDDEN" NAME="BAUDRATE" VALUE="{?baudrate}">
<INPUT TYPE="HIDDEN" NAME="BITS" VALUE="{?bits}">
<INPUT TYPE="HIDDEN" NAME="PARITY" VALUE="{?parity}">
<INPUT TYPE="HIDDEN" NAME="FLOW" VALUE="{?flow}">
<INPUT TYPE="HIDDEN" NAME="DEVICE_URI" VALUE="{device_uri}">
<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{?printer_name}">
<INPUT TYPE="HIDDEN" NAME="PER_QUEUE" VALUE="1">
<INPUT TYPE="HIDDEN" NAME="PRINTER_INFO" VALUE="{printer_info}">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
<INPUT TYPE="HIDDEN" NAME="PRINTER_IS_COLORMANAGED" VALUE="{?printer_is_colormanaged}">
<INPUT TYPE="HIDDEN" NAME="PRINTER_LOCATION" VALUE="{printer_location}">
<table>
<tr>
<TR>
<TH CLASS="label">Stelle PPD Datei bereit:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="MAX_FILE_SIZE" VALUE="262144"><INPUT
TYPE="FILE" NAME="PPD_FILE">
</TR>
<TR>
<TD>
<Input TYPE=SUBMIT VALUE=Upload>
</TD>
</TR>
</table>
</form>
</DIV>
+40
Ver Arquivo
@@ -0,0 +1,40 @@
<DIV CLASS="indent">
<H2 CLASS="title">Adicionar classe</H2>
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
<TABLE>
<TR>
<TH CLASS="label">Nome:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_NAME" SIZE="40" MAXLENGTH="127"><BR>
<SMALL>(Pode conter qualquer caracter imprim&iacute;vel, exceto "/", "#", e espa&ccedil;o em branco)</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Descri&ccedil;&atilde;o:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_INFO" SIZE="40" MAXLENGTH="127"><BR>
<SMALL>(Descri&ccedil;&atilde;o leg&iacute;vel para humanos, tal como "HP LaserJet com Duplexador")</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Localiza&ccedil;&atilde;o:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_LOCATION" SIZE="40" MAXLENGTH="127"><BR>
<SMALL>(Localiza&ccedil;&atilde;o leg&iacute;vel para humanos, tal como "Laborat&oacute;rio 1")</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Membros:</TH>
<TD>
<SELECT NAME="MEMBER_URIS" SIZE="10" MULTIPLE>
{[member_uris]<OPTION VALUE="{member_uris}" {?member_selected}>{member_names}}
</SELECT>
</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Adicionar Classe"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+47
Ver Arquivo
@@ -0,0 +1,47 @@
<DIV CLASS="indent">
<H2 CLASS="title">Adicionar impressora</H2>
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
<INPUT TYPE="HIDDEN" NAME="BAUDRATE" VALUE="{?baudrate}">
<INPUT TYPE="HIDDEN" NAME="BITS" VALUE="{?bits}">
<INPUT TYPE="HIDDEN" NAME="PARITY" VALUE="{?parity}">
<INPUT TYPE="HIDDEN" NAME="FLOW" VALUE="{?flow}">
{?current_make!?<INPUT TYPE="HIDDEN" NAME="CURRENT_MAKE" VALUE="{current_make}">:}
{?current_make_and_model!?<INPUT TYPE="HIDDEN" NAME="CURRENT_MAKE_AND_MODEL" VALUE="{current_make_and_model}">:}
<TABLE>
<TR>
<TH CLASS="label">Nome:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_NAME" SIZE="40" MAXLENGTH="127" VALUE="{?template_name}"><BR>
<SMALL>(Pode conter qualquer caracter imprimível, exceto "/", "#" e espaço em branco)</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Descrição:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_INFO" SIZE="40" MAXLENGTH="127" VALUE="{?PRINTER_INFO}"><BR>
<SMALL>(Descrição legível para humanos, tal como "HP LaserJet com Duplexador")</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Localização:</TH>
<TD><INPUT TYPE="TEXT" NAME="PRINTER_LOCATION" SIZE="40" MAXLENGTH="127" VALUE="{?PRINTER_LOCATION}"><BR>
<SMALL>(Localização legível para humanos, tal como "Laboratório 1")</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Conexão:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="DEVICE_URI" VALUE="{device_uri}">{device_uri}</TD>
</TR>
<TR>
<TH CLASS="label">Compartilhamento:</TH>
<TD><INPUT TYPE="CHECKBOX" NAME="PRINTER_IS_SHARED" {PRINTER_IS_SHARED=1?CHECKED:}>
Compartilhar essa Impressora</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Continue"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+44
Ver Arquivo
@@ -0,0 +1,44 @@
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="add-rss-subscription">
<H2 CLASS="title">Adicionar inscrição RSS</H2>
<TABLE SUMMARY="Formulário para adicionar inscrição RSS">
<TR>
<TH CLASS="label">Nome:</TH>
<TD COLSPAN="5"><INPUT TYPE="TEXT" NAME="SUBSCRIPTION_NAME" SIZE="40" MAXLENGTH="127" VALUE="{?SUBSCRIPTION_NAME}"><BR>
<SMALL>(Pode conter qualquer caracter imprimível, exceto espaço em branco, "/", "?", e "#")</SMALL></TD>
</TR>
<TR>
<TH CLASS="label">Fila:</TH>
<TD COLSPAN="5"><SELECT NAME="PRINTER_URI" SIZE="10"><OPTION VALUE="#ALL#"{?PRINTER_URI=#ALL#? SELECTED:}>All Queues</OPTION>{[printer_name]<OPTION VALUE="{printer_uri_supported}"{?PRINTER_URI={printer_uri_supported}? SELECTED:}>{printer_name}</OPTION>}</SELECT></TD>
</TR>
<TR VALIGN="TOP">
<TH CLASS="label">Eventos:</TH>
<TD><INPUT TYPE="CHECKBOX" NAME="EVENT_JOB_CREATED" {?EVENT_JOB_CREATED}>Trabalho criado<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_JOB_COMPLETED" {?EVENT_JOB_COMPLETED}>Trabalho concluído<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_JOB_STOPPED" {?EVENT_JOB_STOPPED}>Trabalho parado<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_JOB_CONFIG_CHANGED" {?EVENT_JOB_CONFIG_CHANGED}>Opções do Trabalho alteradas</TD>
<TD>&nbsp;&nbsp;&nbsp;&nbsp;</TD>
<TD><INPUT TYPE="CHECKBOX" NAME="EVENT_PRINTER_STOPPED" {?EVENT_PRINTER_STOPPED}>Fila parada<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_PRINTER_ADDED" {?EVENT_PRINTER_ADDED}>Fila adicionada<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_PRINTER_MODIFIED" {?EVENT_PRINTER_MODIFIED}>Fila modificada<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_PRINTER_DELETED" {?EVENT_PRINTER_DELETED}>Fila apagada</TD>
<TD>&nbsp;&nbsp;&nbsp;&nbsp;</TD>
<TD><INPUT TYPE="CHECKBOX" NAME="EVENT_SERVER_STARTED" {?EVENT_SERVER_STARTED}>Servidor iniciado<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_SERVER_STOPPED" {?EVENT_SERVER_STOPPED}>Servidor parado<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_SERVER_RESTARTED" {?EVENT_SERVER_RESTARTED}>Servidor reiniciado<BR>
<INPUT TYPE="CHECKBOX" NAME="EVENT_SERVER_AUDIT" {?EVENT_SERVER_AUDIT}>Auditoria de segurança do servidor</TD>
</TR>
<TR>
<TH CLASS="label">Máximo de eventos no Feed:</TH>
<TD COLSPAN="5"><INPUT TYPE="NUMBER" NAME="MAX_EVENTS" SIZE="4" MAXLENGTH="4" VALUE="{MAX_EVENTS?{MAX_EVENTS}:20}"></TD>
</TR>
<TR>
<TD></TD>
<TD COLSPAN="5"><INPUT TYPE="SUBMIT" VALUE="Adicionar inscrição RSS"></TD>
</TR>
</TABLE>
</FORM>
+102
Ver Arquivo
@@ -0,0 +1,102 @@
<TABLE CLASS="indent" SUMMARY="Tarefas Administrativas">
<TR><TD VALIGN="TOP">
<H2 CLASS="title">Impressoras</H2>
<P>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="add-printer"><INPUT TYPE="SUBMIT" VALUE="Adicionar impressora"></FORM>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="find-new-printers"><INPUT TYPE="SUBMIT" VALUE="Encontrar novas impressoras"></FORM>
<FORM ACTION="/printers/" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Gerenciar impressoras"></FORM>
{have_samba?<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="export-samba"><INPUT TYPE="SUBMIT" VALUE="Exportar impressoras ao Samba"></FORM>:}
</P>
<H2 CLASS="title">Classes</H2>
<P>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="add-class"><INPUT TYPE="SUBMIT" VALUE="Adicionar classe"></FORM>
<FORM ACTION="/classes/" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Gerenciar classes"></FORM>
</P>
<H2 CLASS="title">Trabalhos</H2>
<P>
<FORM ACTION="/jobs/" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Gerenciar trabalhos"></FORM>
</P>
</TD><TD>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</TD><TD VALIGN="TOP">
<H2 CLASS="title">Servidor</H2>
<P>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="config-server"><INPUT TYPE="SUBMIT" VALUE="Editar arquivo de configuração"></FORM>
<FORM ACTION="/admin/log/access_log" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Ver log de acessos"></FORM>
<FORM ACTION="/admin/log/error_log" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Ver log de erros"></FORM>
<FORM ACTION="/admin/log/page_log" METHOD="GET"><INPUT TYPE="SUBMIT" VALUE="Ver log de páginas"></FORM>
</P>
{SETTINGS_ERROR?<P>{SETTINGS_MESSAGE}</P>
<BLOCKQUOTE>{SETTINGS_ERROR}</BLOCKQUOTE>:
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
{ADVANCEDSETTINGS?<P><B>Configurações do servidor\:</B></P>
<P><A HREF="/admin/">Avançadas <SMALL>&#x25bc;</SMALL></A><BR>
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="config-server">
<INPUT TYPE="HIDDEN" NAME="ADVANCEDSETTINGS" VALUE="YES">
<INPUT TYPE="CHECKBOX" NAME="SHARE_PRINTERS" {?share_printers}> Compartilhar impressoras conectadas a este sistema<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Máximo de clientes\:
<INPUT TYPE="TEXT" NAME="MAX_CLIENTS" VALUE="{?max_clients}" SIZE="6"><BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<INPUT TYPE="CHECKBOX" NAME="REMOTE_ANY" {?remote_any}> Permitir impressão a partir da Internet<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<INPUT TYPE="CHECKBOX" NAME="BROWSE_WEB_IF" {?browse_web_if}> Anunciar interface web<BR>
<INPUT TYPE="CHECKBOX" NAME="REMOTE_ADMIN" {?remote_admin}> Permitir administração remota<BR>
{have_gssapi?<INPUT TYPE="CHECKBOX" NAME="KERBEROS" {?kerberos}> Usar autenticação via Kerberos (<A HREF="/help/kerberos.html?TOPIC=Getting+Started">FAQ</A>)<BR>:}
<INPUT TYPE="CHECKBOX" NAME="USER_CANCEL_ANY" {?user_cancel_any}> Permitir aos usuários cancelar qualquer trabalho (não apenas os seus próprios)<BR>
<INPUT TYPE="CHECKBOX" NAME="PRESERVE_JOBS" {?preserve_jobs}> Preservar o histórico de trabalhos<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Máximo de trabalhos (0 para sem limite)\:
<INPUT TYPE="TEXT" NAME="MAX_JOBS" VALUE="{?max_jobs}" SIZE="6"><BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reter metadados\:
<INPUT TYPE="TEXT" NAME="PRESERVE_JOB_HISTORY" VALUE="{?preserve_job_history}" SIZE="6"><BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Reter documentos\:
<INPUT TYPE="TEXT" NAME="PRESERVE_JOB_FILES" VALUE="{?preserve_job_files}" SIZE="6"><BR>
<INPUT TYPE="CHECKBOX" NAME="DEBUG_LOGGING" {?debug_logging}> Salvar informação de depuração para solução de problemas<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Tamanho máximo do arquivo de log\:
<INPUT TYPE="TEXT" NAME="MAX_LOG_SIZE" VALUE="{?max_log_size}" SIZE="6"></P>
:<P><B>Configurações do servidor:</B></P>
<P><A HREF="/admin/?ADVANCEDSETTINGS=YES">Avançadas <SMALL>&#x25b6;</SMALL></A><BR>
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="config-server">
<INPUT TYPE="CHECKBOX" NAME="SHARE_PRINTERS" {?share_printers}> Compartilhar impressoras conectadas a este sistema<BR>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<INPUT TYPE="CHECKBOX" NAME="REMOTE_ANY" {?remote_any}> Permitir impressão a partir da Internet<BR>
<INPUT TYPE="CHECKBOX" NAME="REMOTE_ADMIN" {?remote_admin}> Permitir administração remota<BR>
{have_gssapi?<INPUT TYPE="CHECKBOX" NAME="KERBEROS" {?kerberos}> Usar autenticação via Kerberos (<A HREF="/help/kerberos.html?TOPIC=Getting+Started">FAQ</A>)<BR>:}
<INPUT TYPE="CHECKBOX" NAME="USER_CANCEL_ANY" {?user_cancel_any}> Permitir aos usuários cancelar qualquer trabalho (não apenas seus próprios)<BR>
<INPUT TYPE="CHECKBOX" NAME="DEBUG_LOGGING" {?debug_logging}> Salvar informações de depuração para solução de problemas</P>
}
<P><INPUT TYPE="SUBMIT" NAME="CHANGESETTINGS" VALUE="Alterar configurações"></P>
</FORM>}
</TD></TR>
</TABLE>
<DIV CLASS="indent">
<H2 CLASS="title">Inscrições RSS</H2>
<P>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="add-rss-subscription"><INPUT TYPE="SUBMIT" VALUE="Adicionar inscrição RSS"></FORM>
</P>
</DIV>
{notify_subscription_id?<TABLE CLASS="list" SUMMARY="Inscrições RSS">
<THEAD><TR><TH>Nome</TH><TH>Eventos</TH><TH>Nome da fila</TH></TR></THEAD>
<TBODY>{[notify_subscription_id]
<TR><TD><A HREF="{notify_recipient_uri}">{notify_recipient_name}</A><BR>
<FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="OP" VALUE="cancel-subscription"><INPUT TYPE="HIDDEN" NAME="notify_subscription_id" VALUE="{notify_subscription_id}"><INPUT TYPE="SUBMIT" VALUE="Cancelar Assinatura"></FORM>&nbsp;</TD><TD>{notify_events}</TD><TD NOWRAP>&nbsp;{notify_printer_name?{notify_printer_name}:Todas as filas}</TD></TR>}
</TBODY>
</TABLE>:}
+53
Ver Arquivo
@@ -0,0 +1,53 @@
<DIV CLASS="indent">
<H2 CLASS="title">{op=modify-printer?Modificar {printer_name}:Adicionar impressora}</H2>
{CUPS_GET_DEVICES_DONE?<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{printer_name?<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">:}
<TABLE>
{op=add-printer?:<TR>
<TH CLASS="label">Conexão atual\:</TH>
<TD><INPUT TYPE="RADIO" NAME="DEVICE_URI" VALUE="{current_device_uri}" CHECKED>
{current_device_uri}</TD>
</TR>}
<TR>
<TH CLASS="label">Impressoras locais\:</TH>
<TD>
{[device_uri]{device_class!network?<INPUT TYPE="RADIO" NAME="DEVICE_URI"
VALUE="{device_uri}{?device_make_and_model!Unknown?|{device_make_and_model}:}">
{device_info} {?device_make_and_model!Unknown?({device_make_and_model}):}<BR>
:}}
</TD>
</TR>
<TR>
<TH CLASS="label">Impressoras de rede descobertas\:</TH>
<TD>
{[device_uri]{device_class=network?{device_uri~[a-z]+://?<INPUT TYPE="RADIO" NAME="DEVICE_URI"
VALUE="{device_uri}{?device_make_and_model!Unknown?|{device_make_and_model}:}">
{device_info} {?device_make_and_model!Unknown?({device_make_and_model}):}<BR>
:}:}}
</TD>
</TR>
<TR>
<TR>
<TH CLASS="label">Outras impressoras de rede\:</TH>
<TD>
{[device_uri]{device_class=network?{device_uri~[a-z]+://?:<INPUT TYPE="RADIO" NAME="DEVICE_URI"
VALUE="{device_uri}{?device_make_and_model!Unknown?|{device_make_and_model}:}">
{device_info} {?device_make_and_model!Unknown?({device_make_and_model}):}<BR>
}:}}
</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Continar"></TD>
</TR>
</TABLE>
</FORM>:<P><IMG SRC="/images/wait.gif" WIDTH="16" HEIGHT="16" ALIGN="ABSMIDDLE"
ALT="Ocupado"> Procurando impressoras...</P>}
</DIV>
+64
Ver Arquivo
@@ -0,0 +1,64 @@
<DIV CLASS="indent">
<H2 CLASS="title">{op=modify-printer?Modificar {printer_name}:Adicionar impressora}</H2>
<FORM METHOD="POST" ACTION="/admin" ENCTYPE="multipart/form-data">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{printer_name?<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">:}
<INPUT TYPE="HIDDEN" NAME="BAUDRATE" VALUE="{?baudrate}">
<INPUT TYPE="HIDDEN" NAME="BITS" VALUE="{?bits}">
<INPUT TYPE="HIDDEN" NAME="PARITY" VALUE="{?parity}">
<INPUT TYPE="HIDDEN" NAME="FLOW" VALUE="{?flow}">
<TABLE>
{op=modify-printer?:<TR>
<TH CLASS="label">Nome:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_NAME" VALUE="{printer_name}">{printer_name}</TD>
</TR>}
<TR>
<TH CLASS="label">Descrição:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_INFO" VALUE="{printer_info}">{printer_info}</TD>
</TR>
<TR>
<TH CLASS="label">Localização:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_LOCATION" VALUE="{printer_location}">{printer_location}</TD>
</TR>
<TR>
<TH CLASS="label">Conexão:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="DEVICE_URI" VALUE="{device_uri}">{device_uri}</TD>
</TR>
<TR>
<TH CLASS="label">Compartilhamento:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_IS_SHARED" VALUE="{?printer_is_shared}">
{?printer_is_shared=?Não compartilhar:{?printer_is_shared=0?Não compartilhar:Compartilhar}} esta impressora</TD>
</TR>
<TR>
<TH CLASS="label">Fabricante:</TH>
<TD>
<SELECT NAME="PPD_MAKE" SIZE="10">
{[ppd_make]<OPTION VALUE="{ppd_make}" {?current_make={ppd_make}?SELECTED:}>{ppd_make}}
</SELECT>
</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Continar"></TD>
</TR>
<TR>
<TD></TD>
<TD>&nbsp;</TD>
</TR>
<TR>
<TH CLASS="label">Ou forneça um arquivo PPD:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="MAX_FILE_SIZE" VALUE="262144"><INPUT
TYPE="FILE" NAME="PPD_FILE"></TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="{op=add-printer?Adicionar impressora:Modificar impressora}"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+60
Ver Arquivo
@@ -0,0 +1,60 @@
<DIV CLASS="indent">
<H2 CLASS="title">{op=modify-printer?Modificar {printer_name}:Adicionar impressora}</H2>
<FORM METHOD="POST" ACTION="/admin" ENCTYPE="multipart/form-data">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{printer_name?<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">:}
<INPUT TYPE="HIDDEN" NAME="BAUDRATE" VALUE="{?baudrate}">
<INPUT TYPE="HIDDEN" NAME="BITS" VALUE="{?bits}">
<INPUT TYPE="HIDDEN" NAME="PARITY" VALUE="{?parity}">
<INPUT TYPE="HIDDEN" NAME="FLOW" VALUE="{?flow}">
<TABLE>
{op=modify-printer?:<TR>
<TH CLASS="label">Nome:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_NAME" VALUE="{printer_name}">{printer_name}</TD>
</TR>}
<TR>
<TH CLASS="label">Descrição:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_INFO" VALUE="{printer_info}">{printer_info}</TD>
</TR>
<TR>
<TH CLASS="label">Localização:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_LOCATION" VALUE="{printer_location}">{printer_location}</TD>
</TR>
<TR>
<TH CLASS="label">Conexão:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="DEVICE_URI" VALUE="{device_uri}">{device_uri}</TD>
</TR>
<TR>
<TH CLASS="label">Compartilhamento:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="PRINTER_IS_SHARED" VALUE="{?printer_is_shared}">
{?printer_is_shared=?Não compartilhar:{?printer_is_shared=0?Não compartilhar:Compartilhar}} esta impressora</TD>
</TR>
<TR>
<TH CLASS="label">Fabricante:</TH>
<TD>{PPD_MAKE} <INPUT TYPE="SUBMIT" NAME="SELECT_MAKE" VALUE="Selecione outro fabricante"></TD>
</TR>
<TR>
<TH CLASS="label">Modelo:</TH>
<TD>
<SELECT NAME="PPD_NAME" SIZE="10">
{op=add-printer?:<OPTION VALUE="__no_change__" SELECTED>Driver atual - {current_make_and_model}</OPTION>:}
{[ppd_name]<OPTION VALUE="{ppd_name}" {op=modify-printer?:{?current_make_and_model={ppd_make_and_model}?SELECTED:}}>{ppd_make_and_model} ({ppd_natural_language})
}</SELECT>
</TD>
</TR>
<TR>
<TH CLASS="label">Ou forneça um arquivo PPD:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="MAX_FILE_SIZE" VALUE="262144"><INPUT
TYPE="FILE" NAME="PPD_FILE"></TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="{op=add-printer?Adicionar impressora:Modificar impressora}"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+52
Ver Arquivo
@@ -0,0 +1,52 @@
<DIV CLASS="indent">
<H2 CLASS="title">{op=modify-printer?Modificar {printer_name}:Adicionar impressora}</H2>
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{printer_name?<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">:}
<TABLE>
<TR>
<TH CLASS="label">Conexão:</TH>
<TD><INPUT TYPE="HIDDEN" NAME="DEVICE_URI" VALUE="{device_uri}">{device_uri}</TD>
</TR>
<TR>
<TH CLASS="label">Taxa de dados (Baud Rate):</TH>
<TD><SELECT NAME="BAUDRATE">
{[baudrates]<OPTION {?baudrate={baudrates}?SELECTED:}>{baudrates}}
</SELECT></TD>
</TR>
<TR>
<TH CLASS="label">Paridade:</TH>
<TD><SELECT NAME="PARITY">
<OPTION VALUE="none" {?parity=none?SELECTED:}>Nenhum
<OPTION VALUE="even" {?parity=even?SELECTED:}>Par
<OPTION VALUE="odd" {?parity=odd?SELECTED:}>Ímpar
</SELECT></TD>
</TR>
<TR>
<TH CLASS="label">Bits de Dados:</TH>
<TD><SELECT NAME="BITS">
<OPTION {?bits=8?SELECTED:}>8
<OPTION {?bits=7?SELECTED:}>7
</SELECT></TD>
</TR>
<TR>
<TH CLASS="label">Controle de Fluxo:</TH>
<TD><SELECT NAME="FLOW">
<OPTION VALUE="none" {?flow=none?SELECTED:}>Nenhum
<OPTION VALUE="soft" {?flow=soft?SELECTED:}>XON/XOFF (Software)
<OPTION VALUE="hard" {?flow=hard?SELECTED:}>RTS/CTS (Hardware)
<OPTION VALUE="dtrdsr" {?flow=dtrdsr?SELECTED:}>DTR/DSR (Hardware)
</SELECT></TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Continar"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+44
Ver Arquivo
@@ -0,0 +1,44 @@
<DIV CLASS="indent">
<H2 CLASS="title">{op=modify-printer?Modify {printer_name}:Add Printer}</H2>
<FORM METHOD="POST" ACTION="/admin">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{printer_name?<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">:}
<INPUT TYPE="HIDDEN" NAME="CURRENT_MAKE_AND_MODEL" VALUE="{?current_make_and_model}">
<TABLE>
<TR>
<TH CLASS="label">Conexão:</TH>
<TD><INPUT TYPE="URL" SIZE="60" MAXLENGTH="1023" NAME="DEVICE_URI" VALUE="{current_device_uri?{current_device_uri}:{device_uri}}"></TD>
</TR>
<TR>
<TD></TD>
<TD>Exemplos:
<PRE>
http://hostname:631/ipp/
http://hostname:631/ipp/port1
ipp://hostname/ipp/
ipp://hostname/ipp/port1
lpd://hostname/queue
socket://hostname
socket://hostname:9100
</PRE>
<P>Veja <A HREF="/help/network.html" TARGET="_blank">"Network
Printers"</A> para a URI correta a ser usada para sua impressora.</P>
</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="Continuar"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Adicionar classe</H2>
<P>Classe <A HREF="/classes/{printer_name}">{printer_name}</A> foi adicionada com sucesso.
</DIV>
+9
Ver Arquivo
@@ -0,0 +1,9 @@
<DIV CLASS="indent">
<H2 CLASS="title">Excluir classe {printer_name}</H2>
<P><B>Aviso:</B> Você tem certeza que quer excluir a classe {printer_name}?</P>
<P ALIGN="CENTER"><FORM ACTION="/admin/" METHOD="POST"><INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}"><INPUT TYPE="HIDDEN" NAME="op" VALUE="delete-class"><INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}"><INPUT TYPE="SUBMIT" NAME="confirm" VALUE="Excluir classe"></FORM></P>
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Excluir classe {printer_name}</H2>
<P>A classe {printer_name} foi excluída com sucesso.
</DIV>
+3
Ver Arquivo
@@ -0,0 +1,3 @@
<DIV CLASS="indent">
<H3 CLASS="title">Trabalhos</H3>
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Modificar classe {printer_name}</H2>
<P>A classe <A HREF="/classes/{printer_name}">{printer_name}</A> foi modificada com sucesso.
</DIV>
+44
Ver Arquivo
@@ -0,0 +1,44 @@
<DIV CLASS="indent">
<H2 CLASS="title"><A HREF="{printer_uri_supported}">{printer_name}</A>
({printer_state=3?Inativa:{printer_state=4?Processando:Pausada}},
{printer_is_accepting_jobs=0?Rejeitando trabalhos:Aceitando trabalhos},
{server_is_sharing_printers=0?Não compartilhada:{printer_is_shared=0?Não compartilhada:Compartilhada}} {default_name={printer_name}?, Padrão do servidor:})</H2>
<FORM METHOD="POST" ACTION="{printer_uri_supported}" NAME="maintenance">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<SELECT NAME="OP" ONCHANGE="document.maintenance.submit();">
<OPTION VALUE="">Manutenção</OPTION>
<OPTION VALUE="print-test-page">Imprimir página de teste</OPTION>
{printer_state=5?<OPTION VALUE="start-class">Resumir classe</OPTION>:<OPTION VALUE="stop-class">Pausar classe</OPTION>}
{printer_is_accepting_jobs=0?<OPTION VALUE="accept-jobs">Aceitar trabalhos</OPTION>:<OPTION VALUE="reject-jobs">Rejeitar trabalhos</OPTION>}
<OPTION VALUE="move-jobs">Mover todos trabalhos/OPTION>
<OPTION VALUE="purge-jobs">Cancelar todos trabalhos</OPTION>
</SELECT>
<INPUT TYPE="SUBMIT" VALUE="Ir" STYLE="display: none;">
</FORM>
<FORM METHOD="POST" ACTION="{admin_uri}" NAME="administration">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="printer_name" VALUE="{printer_name}">
<INPUT TYPE="HIDDEN" NAME="IS_CLASS" VALUE="1">
<SELECT NAME="OP" ONCHANGE="document.administration.submit();">
<OPTION VALUE="">Administração</OPTION>
<OPTION VALUE="modify-class">Modificar classe</OPTION>
<OPTION VALUE="delete-class">Excluir classe</OPTION>
<OPTION VALUE="set-class-options">Definir opções padrão</OPTION>
<OPTION VALUE="set-as-default">Definir como servidor padrão</OPTION>
<OPTION VALUE="set-allowed-users">Definir usuários permitidos</OPTION>
</SELECT>
<INPUT TYPE="SUBMIT" VALUE="Ir" STYLE="display: none;">
</FORM>
<TABLE SUMMARY="{printer_name}">
<TR><TH ALIGN="RIGHT" VALIGN="TOP">Descrição:</TH><TD>{printer_info}</TD></TR>
<TR><TH ALIGN="RIGHT" VALIGN="TOP">Localização:</TH><TD>{printer_location}</TD></TR>
<TR><TH ALIGN="RIGHT" VALIGN="TOP">Membros:</TH><TD>{?member_uris=?None:{member_uris}}</TD></TR>
<TR><TH ALIGN="RIGHT" VALIGN="TOP">Padrões:</TH><TD>job-sheets={job_sheets_default}
media={media_default?{media_default}:desconhecido}
{sides_default?sides={sides_default}:}</TD></TR>
</TABLE>
</DIV>
+1
Ver Arquivo
@@ -0,0 +1 @@
<P ALIGN="CENTER">{total=0?Nenhuma classe:Mostrando {#printer_name} de {total} classe{total=1?:s}}.</P>
+11
Ver Arquivo
@@ -0,0 +1,11 @@
{#printer_name=0?:
<TABLE CLASS="list" SUMMARY="Class List">
<THEAD>
<TR><TH><A HREF="{THISURL}?QUERY={?QUERY}&amp;WHICH_JOBS={?WHICH_JOBS}&amp;FIRST={FIRST}&amp;ORDER={ORDER=dec?asc:dec}">{ORDER=dec?<SMALL>&#x25b2;</SMALL> Nome da fila <SMALL>&#x25b2;</SMALL>:<SMALL>&#x25bc;</SMALL> Nome da fila <SMALL>&#x25bc;</SMALL>}</A></TH><TH>Descrição</TH><TH>Localização</TH><TH>Membros</TH><TH>Estado</TH></TR>
</THEAD>
<TBODY>
{[printer_name]
<TR><TD><A HREF="{printer_uri_supported}">{printer_name}</A></TD><TD>{printer_info}</TD><TD>{printer_location}</TD><TD>{?member_uris=?Nenhum:{member_uris}}</TD><TD>{printer_state=3?Inativa:{printer_state=4?Processando:Pausada}}{printer_state_message? - "{printer_state_message}":}</TD></TR>
}
</TBODY>
</TABLE></DIV>}
+12
Ver Arquivo
@@ -0,0 +1,12 @@
<DIV CLASS="indent">
<H2 CLASS="title">{title} em {printer_name}</H2>
<P>{job_state>5?:<IMG SRC="/images/wait.gif" WIDTH="16" HEIGHT="16"
ALIGN="ABSMIDDLE" ALT="Busy Indicator"> }Trabalho de comando de impressora
{job_state=3?pendente:{job_state=4?retido:
{job_state=5?processando:{job_state=6?parada:
{job_state=7?cancelado:{job_state=8?abortado:completo}}}}}}{job_state=9?:{job_printer_state_message?,
<EM>"{job_printer_state_message}"</EM>:}}</P>
</DIV>
+24
Ver Arquivo
@@ -0,0 +1,24 @@
<SCRIPT TYPE="text/javascript">
function reset_config()
{
document.cups.CUPSDCONF.value = "{?cupsdconf_default}";
}
</SCRIPT>
<DIV CLASS="indent">
<H2 CLASS="title">Editar arquivo de configuração</H2>
<FORM NAME="cups" METHOD="POST" ACTION="/admin/">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="config-server">
<TEXTAREA NAME="CUPSDCONF" COLS="80" ROWS="25">{CUPSDCONF}</TEXTAREA>
<P><INPUT TYPE="SUBMIT" NAME="SAVECHANGES" VALUE="Salvar alterações">
<INPUT TYPE="BUTTON" VALUE="Usar arquivo de configuração padrão"
onClick="reset_config();"></P>
</FORM>
</DIV>
+9
Ver Arquivo
@@ -0,0 +1,9 @@
<DIV CLASS="indent">
<H2 CLASS="title">Erro {?title} {?printer_name}</H2>
<P>Erro:</P>
<BLOCKQUOTE>Operação desconhecida "{op}"!</BLOCKQUOTE>
</DIV>
+9
Ver Arquivo
@@ -0,0 +1,9 @@
<DIV CLASS="indent">
<H2 CLASS="title">Erro {?title} {?printer_name}</H2>
<P>{?message?{message}:Erro}:</P>
<BLOCKQUOTE>{error}</BLOCKQUOTE>
</DIV>
+38
Ver Arquivo
@@ -0,0 +1,38 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=utf-8">
<TITLE>{title} - CUPS @CUPS_VERSION@@CUPS_REVISION@</TITLE>
<LINK REL="STYLESHEET" TYPE="text/css" HREF="/cups.css">
<LINK REL="SHORTCUT ICON" HREF="/images/cups-icon.png" TYPE="image/png">
{refresh_page?<META HTTP-EQUIV="Refresh" CONTENT="{refresh_page}">:}
<SCRIPT TYPE="text/javascript"><!--
/* Show an error if cookies are disabled */
function check_cookies() {
if (!navigator.cookieEnabled) {
document.getElementById('body').innerHTML = 'This page uses cookies to prevent common cross-site attacks. Please enable cookies in your browser.';
}
}
--></SCRIPT>
</HEAD>
<BODY ONLOAD="check_cookies();">
<TABLE CLASS="page" SUMMARY="{title}">
<TR><TD CLASS="body">
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="0" SUMMARY="">
<TR HEIGHT="36">
<TD><A HREF="http://www.cups.org/" TARGET="_blank"><IMG
SRC="/images/left.gif" WIDTH="64" HEIGHT="36" BORDER="0" ALT=""></A></TD>
<TD CLASS="unsel"><A HREF="/">&nbsp;&nbsp;In&iacute;cio&nbsp;&nbsp;</A></TD>
<TD CLASS="{SECTION=admin?:un}sel"><A HREF="/admin">&nbsp;&nbsp;Administra&ccedil;&atilde;o&nbsp;&nbsp;</A></TD>
<TD CLASS="{SECTION=classes?:un}sel"><A HREF="/classes/">&nbsp;&nbsp;Classes&nbsp;&nbsp;</A></TD>
<TD CLASS="{SECTION=help?:un}sel"><A HREF="/help/">&nbsp;&nbsp;Ajuda&nbsp;online&nbsp;&nbsp;</A></TD>
<TD CLASS="{SECTION=jobs?:un}sel"><A HREF="/jobs/">&nbsp;&nbsp;Trabalhos&nbsp;&nbsp;</A></TD>
<TD CLASS="{SECTION=printers?:un}sel"><A HREF="/printers/">&nbsp;&nbsp;Impressoras&nbsp;&nbsp;</A></TD>
<TD CLASS="unsel" WIDTH="100%"><FORM ACTION="/help/" METHOD="GET"><INPUT
TYPE="SEARCH" NAME="QUERY" SIZE="20" PLACEHOLDER="Procurar ajuda"
VALUE="{SECTION=help?{?QUERY}:}" AUTOSAVE="org.cups.help" RESULTS="20"></FORM></TD>
<TD><IMG SRC="/images/right.gif" WIDTH="4" HEIGHT="36" ALT=""></TD>
</TR>
</TABLE>
<DIV ID="body">
+51
Ver Arquivo
@@ -0,0 +1,51 @@
<DIV CLASS="indent">
<FORM ACTION="/help/{?HELPFILE}" METHOD="GET">
{TOPIC?<INPUT TYPE="HIDDEN" NAME="TOPIC" VALUE="{TOPIC}">:}
<P ALIGN="CENTER"><B>Pesquisar em
{HELPTITLE?{HELPTITLE}:{TOPIC?{TOPIC}:todos os documentos}}:</B> <INPUT
TYPE="SEARCH" NAME="QUERY" VALUE="{?QUERY}" SIZE="40" PLACEHOLDER=""
AUTOSAVE="org.cups.help" RESULTS="20">
<INPUT TYPE="SUBMIT" NAME="SEARCH" VALUE="Pesquisar">
<INPUT TYPE="SUBMIT" NAME="CLEAR" VALUE="Limpar"></P>
</FORM>
<!-- Bookmarks -->
<DIV CLASS="sidebar"><TABLE CLASS="inset" SUMMARY="Conteúdo">
<TR><TD>
<H3 CLASS="title">Documentos de ajuda online</H3>
<P CLASS="l0"><A HREF="/help/{QUERY??QUERY={QUERY}:}">Todos os Documentos</A></P>
<HR>
{[BMTEXT]<P CLASS="l{BMINDENT}"><A HREF="{BMLINK}">{BMTEXT}</A></P>
}
</TD></TR>
</TABLE></DIV>
{QUERY?<P>Pesquisar resultados em {HELPFILE?{HELPTITLE}:{TOPIC?{TOPIC}:Todos os documentos}}\:</P>
{QTEXT?<UL>
{[QTEXT]<LI><A HREF="{QLINK}">{QTEXT}</A>{QPTEXT? (em <I><A HREF="{QPLINK}">{QPTEXT}</A></I>):}</LI>}
{QTEXT?</UL>:}
:<P>Nenhum resultado encontrado.</P>}
<HR NOSHADE>:}
{HELPTITLE?<H1>{HELPTITLE}</H1>
<FORM ACTION="/help/{?HELPFILE}" METHOD="GET"><INPUT TYPE="HIDDEN" NAME="PRINTABLE" VALUE="YES"><INPUT TYPE="SUBMIT" VALUE="Ver versão imprimível"></FORM>:
<H1>Ajuda online</H1>
<P>Essa é a interface de ajuda online do CUPS. Forneça expressões de pesquisa
acima ou clique em qualquer um dos links de documentação para mostrar
a informação de ajuda online.</P>
<P>Se você é novo no CUPS, leia a página "<a
href="/help/overview.html">Visão geral do CUPS</a>". Usuários veteranos
devem ler a página "<a href="/help/whatsnew.html">O que Há de Novo no CUPS
1.6</a>".</P>
<P>A <A HREF="http://www.cups.org/">Página inicial do CUPS</A> também
fornece muitos recursos incluindo fórums de discussão de usuários, respostas
a perguntas frequentes e um formulário para enviar registros de erros e
pedidos de melhorias.</P>}
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Cancelar trabalho {job_id}</H2>
<P><A HREF="{job_printer_uri}">Trabalho {job_id}</A> foi cancelado.
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Reter trabalho {job_id}</H2>
<P><A HREF="{job_printer_uri}">Trabalho {job_id}</A> foi retido para não ser impresso.
</DIV>
+27
Ver Arquivo
@@ -0,0 +1,27 @@
<DIV CLASS="indent">
<FORM METHOD="POST" ACTION="/{SECTION}/{job_id?:{printer_name}}">
<INPUT TYPE="HIDDEN" NAME="org.cups.sid" VALUE="{$org.cups.sid}">
<INPUT TYPE="HIDDEN" NAME="OP" VALUE="{op}">
{job_id?<INPUT TYPE="HIDDEN" NAME="JOB_ID" VALUE="{job_id}">:}
<H2 CLASS="title">{job_id?Mover trabalho {job_id}:Mover todos trabalhos}</H2>
<TABLE>
<TR>
<TH CLASS="label">Novo destino:</TH>
<TD>
<SELECT NAME="JOB_PRINTER_URI" SIZE="10">
{[job_printer_uri]<OPTION VALUE="{job_printer_uri}">{job_printer_name}}
</SELECT>
</TD>
</TR>
<TR>
<TD></TD>
<TD><INPUT TYPE="SUBMIT" VALUE="{job_id?Mover trabalho:Mover trabalhos}"></TD>
</TR>
</TABLE>
</FORM>
</DIV>
+8
Ver Arquivo
@@ -0,0 +1,8 @@
<DIV CLASS="indent">
<H2 CLASS="title">{job_id?Mover trabalho {job_id}:Mover trabalhos}</H2>
<P>{job_id?<A HREF="/jobs/{job_id}">Trabalho {job_id} for movido</A>:Todos trabalhos foram movidos} para
<A HREF="/{is_class?classes:printers}/{job_printer_name}">{job_printer_name}</A>.</P>
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Liberar trabalho {job_id}</H2>
<P><A HREF="{job_printer_uri}">Trabalho {job_id}</A> foi liberado para impressão.
</DIV>
+7
Ver Arquivo
@@ -0,0 +1,7 @@
<DIV CLASS="indent">
<H2 CLASS="title">Reimprimir trabalho {job_id}</H2>
<P><A HREF="{job_printer_uri}">Trabalho {job_id}</A> foi reiniciado.
</DIV>

Alguns arquivos não foram exibidos porque demasiados arquivos foram alterados neste diff Mostrar Mais